Announcement

Collapse
No announcement yet.

Best way to handle power outages?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Best way to handle power outages?

    OK, I think it's time to draw on the knowledge of the collective...

    I have the following setup:

    HS server, physically connected to an APC UPS via USB, with the APCUPSD script configured and running.

    Apart from the HS server, the following other servers and devices are powered by the UPS: Mainlobby Server, Windows Home Server, and a network switch.

    So far, all servers are configured via BIOS to start automatically when power is available again. The following happens:

    1. The HS server, where APCUPSD is running is shutdown "nicely" when the UPS is about to die (though HS itself is not), and because of this, it does not restart when power is available again
    2. The other servers and devices shut down "abruptly" but do come back on when the power is available again

    How do you manage this? I would like all to be shutdown graciously and also to be able to restart by themselves when power is available again... are these two requirements incompatible?

    Also, in a separate location, I have a router with DSL connection, and am thinking of adding a second UPS to power that, so I can be notified when power is out via email... any thoughts on how to manage all the above and two separate UPS's, one of which where a USB cable will not reach?

    Lastly, can "serious" network switches like a Catalyst, be sent a command to shut down, or is simply removing power not a problem? This morning mine took three attempts to start properly when power was back...

    I realise most of this is not strictly HS, just wondering with so many of you out there, how you are managing this kind of scenario.

    Thanks a lot!!

    Sandro

    #2
    I went so far as to put in a "return" power route back to the garage on my dedicated HS circuits, so that the equipment cans in the garage also keep power during an outage as long as the UPS stays up. I used a power inlet near my UPS for this.

    Power Inlet:
    http://www.amazon.com/gp/product/B002XDQAA6

    This keeps the various devices in sync (no disconnect/reconnect issues with devices or how HS is or is not seeing them during momentary outages). This is just for general HS stability.

    Then I use various software/hardware combinations to manage the power up/down sequences. I have an APC PDU that I can program the various outlet power up times for. HS itself is virtualized, and vSphere handles the power up sequence of my various virtualized servers/machines.

    I utilize multiple UPS units also, and I mainly have them set up by area/function. As such, the one running lower level functions like basic router and switch are able to stay up the longest. This sort of logical setup, together with controlled power on sequencing I mentioned above handles it all for me. You just have to piece it together as you see fit according to your own requirements/priorities.

    Comment


      #3
      I send Wake-On-LAN (WOL) packets from several PC's to wake the HS PC...just in case this type of thing happens.
      Jon

      Comment


        #4
        HS shuts down very slowly, so it needs a head start. I use an AutoIT executable that runs when the UPS is likely to run out of juice. It shuts down all running programs on the HS PC, then shuts down the computer. I have another AutoIT executable in my startup folder that restarts the applications in a controlled manner. In particular, I have it wait for a couple of minutes to restart HS. Among other things, that allows other devices - like the network - to be up and running before HS starts looking for them.
        Mike____________________________________________________________ __________________
        HS3 Pro Edition 3.0.0.548, NUC i3

        HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti

        Comment


          #5
          Thanks for all the input, gets me thinking of options which is good. However, unless I am being particularly thick, I am missing one specific point: the unattended restart of at least one pc/server (for example, to send WOL magic packets to others) after a gracious UPS shutdown... as far as I understand, if the PC is shut down abruptly then the BIOS will restart it when power is applied again, otherwise, not...

          I am lucky in that my HS server only really runs HS + some plugins, nothing else at all, so once HS exits it can be safely shut down.

          Cheers

          Comment


            #6
            Think I may be on to something here: http://www.apcupsd.com/manual/manual...-under-windows

            Will look into it and report back.

            Cheers

            Comment


              #7
              To answer your 'serious switch' question earlier, most Cisco devices do not have the concept of 'shutdown' from an OS perspective. Many do not even have a power switch.

              They can occasionally have issues recovering from a power outage but it is rare.

              Comment


                #8
                Originally posted by pyspilf View Post
                1. The HS server, where APCUPSD is running is shutdown "nicely" when the UPS is about to die (though HS itself is not), and because of this, it does not restart when power is available again
                2. The other servers and devices shut down "abruptly" but do come back on when the power is available again
                1) On your HS PC, what bios settings do you have for PWRON after power fail? I have on,off or former state. I assume you have your bios set to former state hence the reason why it does not restart.

                2) You can shutdown all your other PC's gracefully if you install my remote computer control package. Thinking about it, you state that HS is not shutdown gracefully so you do not have a trigger when power is lost. Perhaps it's time to use one of the many Homeseer UPS plugins available rather than APCUPSD. This will give you the necessary trigger to get HS to fire the events for remote shutdown commands, email notifications etc.
                Jon

                Comment


                  #9
                  My HS setup is not that big (and don't get many power cuts) but I seperated the power to essential and non essential stuff, the essential being the HS PC, cable modem, router and my serial ip server (the ups is plugged into this).

                  I wrote a plugin that talks to the windows ups service and then once it gets a line failure I then wait until the device value for the battery capicity is between 10 and 0%. Then I begin to shutdown HS (using the script commands) and backup the database. There is of course the power could come back on somewhere between 0-10% battery capacity and the system shutdown but I think the chances are if its been off that long (prob about 30mins for 90% battery in my case) its going to be off for an hour or so.

                  The bios is then configured to power on the PC when the power is applied and a shortcut to HS in the startup directory.

                  I don't think there is any way of handling multiple UPS's (except I think the APC business edition does) on windows natively (and the service may have been taken out post-XP?)

                  Comment


                    #10
                    Are all of you using hs as service? If so any issues with plugins.

                    Comment


                      #11
                      Originally posted by mterry63 View Post
                      To answer your 'serious switch' question earlier, most Cisco devices do not have the concept of 'shutdown' from an OS perspective. Many do not even have a power switch.

                      They can occasionally have issues recovering from a power outage but it is rare.
                      OK, thanks. This means one less thing to be concerned about

                      Comment


                        #12
                        Originally posted by jon00 View Post
                        1) On your HS PC, what bios settings do you have for PWRON after power fail? I have on,off or former state. I assume you have your bios set to former state hence the reason why it does not restart.

                        2) You can shutdown all your other PC's gracefully if you install my remote computer control package. Thinking about it, you state that HS is not shutdown gracefully so you do not have a trigger when power is lost. Perhaps it's time to use one of the many Homeseer UPS plugins available rather than APCUPSD. This will give you the necessary trigger to get HS to fire the events for remote shutdown commands, email notifications etc.

                        Jon, I believe I have former state. That's why, I guess, if the shutdown is not graceful the PC will restart, otherwise not. I know I can trigger events even with APCUPSD to shutdown HS, just didn't get round to it yet. Anywhow, I am interested. Any specific UPS plugin you'd suggest?

                        Cheers

                        Comment


                          #13
                          Originally posted by mrhappy View Post
                          My HS setup is not that big (and don't get many power cuts) but I seperated the power to essential and non essential stuff, the essential being the HS PC, cable modem, router and my serial ip server (the ups is plugged into this).

                          I wrote a plugin that talks to the windows ups service and then once it gets a line failure I then wait until the device value for the battery capicity is between 10 and 0%. Then I begin to shutdown HS (using the script commands) and backup the database. There is of course the power could come back on somewhere between 0-10% battery capacity and the system shutdown but I think the chances are if its been off that long (prob about 30mins for 90% battery in my case) its going to be off for an hour or so.

                          The bios is then configured to power on the PC when the power is applied and a shortcut to HS in the startup directory.

                          I don't think there is any way of handling multiple UPS's (except I think the APC business edition does) on windows natively (and the service may have been taken out post-XP?)
                          I have most services connected to the UPS, but all non-essential stuff will be handled by invoking a controlled shutdown soon after a power failure, so as to prolong the time on battery for HS and network. The only thing I need to understand is if the UPS stops providing any voltage at all to the PC once it has been shut down... otherwise, how will the PC know when voltage is restored? Would it not try to restart immediately after shutdown if there is still some residual power in the UPS? Or does the UPS go to sleep?

                          Comment


                            #14
                            Not sure, I might try it but it could also be different for different UPS's. I'd hope there was some sort of no-load shutdown so when the PC shutdown (and there was no load on the UPS) then the UPS did but not sure. There is an option in the windows power management to 'Finally turn off the UPS' so it looks like commands can be sent to the UPS to shutdown from windows. If this helps?

                            Comment


                              #15
                              Well my power outage "plan" was just tested. We just got power back after a 7 day outage and when the power returned HomeSeer was up and running within a couple of minutes. My UPS is so old that it only lasts about 10 minutes now but the hard shut down of HomeSeer doesn't seem to hurt.
                              -Rupp
                              sigpic

                              Comment

                              Working...
                              X