Selfhosted
A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.
Rules:
-
Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.
-
No spam posting.
-
Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.
-
Don't duplicate the full text of your blog or github here. Just post the link for folks to click.
-
Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).
-
No trolling.
Resources:
- selfh.st Newsletter and index of selfhosted software and apps
- awesome-selfhosted software
- awesome-sysadmin resources
- Self-Hosted Podcast from Jupiter Broadcasting
Any issues on the community? Report it using the report flag.
Questions? DM the mods!
view the rest of the comments
Is this doable with one UPS? I'm thinking of the signal wire so the device knows it's running on battery and has to shut itself down sooner or later. We have 2 (who need shutdown, +1 can just lose power I guess) different devices mentioned here.
I have one older APC UPS on the PC and one newer Eaton UPS on the NAS. Each UPS has a signal port with a cable connected to the main device that runs some software to notice when it's on battery and supposed to shut itself down after X minutes battery time.
The NAS UPS also has the router, phone and zigbee hub connected, but only the NAS will shut itself down, the rest will just lose power at some point, but those don't matter.
How do you get the server and NAS to both get the signal and both shut down after X minutes? Is there a specific UPS features required?
Look into NUT, Network UPS Tools. It runs in a server/client type of set up. You'd install the server onto the device that has the UPS data connected to it. It then monitors the UPS status and can tell all the clients to shutdown when the UPS is running low.
Thanks for the suggestion, I'll definitely look into this more.
Hm but that adds a lot more complexity, as then every single network item has to have an UPS as well, right? Certainly not a problem for a company with server room and racks. But at home in a house, the hardware might be spread out across rooms and floors. If there is a switch somewhere without UPS, it will cut off certain clients from receiving the signal via network upon power outage.
Typically you'd have a server running on a device on each UPS, and the clients would be the other devices also plugged into that UPS, so when that UPS is low, everything plugged into it will turn off. If you have another UPS elsewhere in the house, you would have another server installed on a device there so it can monitor that UPS that it is plugged into, and tell the other devices also plugged into that other UPS to shut down. Without knowing the layout you are running though, there's no way to know if NUT is what you need or want.
So in your case it would likely be to plug your server and nas both into the same UPS, and when the server detects the UPS is low battery, it will tell the NAS to shut down. This would also require the switches/router/whatever to also be on a UPS to hold power of course. So then it basically becomes each little cluster of devices that need UPS would also have a switch nearby that is also on the UPS
I don't think an additional UPS is really necessary here. I do have switches to other parts of my network, but they're just for TVs and game consoles, so I don't really think a UPS is needed there.
It's mostly a failsafe so I can poweroff my NAS properly rather than corrupting data. Since my server and router are on the same power strip, it makes sense that they're all on the UPS since they're the 3 main items interacting with each other.
Something with NUT as [email protected] mentioned might be a good option so it can send alerts when it's activated. I'll have to research that more.
Edit: figured out how to mention other users.
True, but wouldn't those scattered devices already be down because of the power outage? If they are in a different room they would probably need to be on a different UPS anyway.