Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    UPS PfSense Shutdown

    General pfSense Questions
    5
    8
    13.5k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      Peter847
      last edited by

      I run a small small office LAN through PfSense and am looking for advice on how I manage my UPS.

      The UPS supplies PfSense and a couple of Windows machines.  Its main purpose is to ride through the relatively frequent power drop outs that last a few seconds, real outages (greater than a minute) are rare.  It does not look easy to get one UPS management suite that will gracefully shutdown all the machines so I am thinking about letting PfSense just run out of power.

      PfSense runs on a passively cooled Atom system with an SSD, will I damage anything if I just let the power on the UPS run out and restart PfSense when the power returns?

      1 Reply Last reply Reply Quote 0
      • GertjanG
        Gertjan
        last edited by

        @Peter847:

        .. will I damage anything if I just let the power on the UPS run out and restart PfSense when the power returns?

        This situation will happen every time the power gets lost.
        If power outages rarely last for more then a minute or so, it will not happen anymore, as your UPS will take over over this "minute or so"'.
        When the UPS is connected to pfSense with an USB or serial cable, the UPS can even start a clean shut down sequence.

        "If damage occurs" can't be answered. You should avoid these situations as much as possible.

        No "help me" PM's please. Use the forum, the community will thank you.
        Edit : and where are the logs ??

        1 Reply Last reply Reply Quote 0
        • M
          mer
          last edited by

          You should be able to use apcupsd or NUT package on the pfSense box and have it gracefully shutdown.
          If you want the single UPS to gracefully shutdown all the machines, you'll need to pick something that runs everywhere and has the ability to talk across the network. 
          NUT (networkupstools.org) has this feature, I believe there is a pfSense package for it, it looks like it may run on Windows.

          I'd set up pfSense to be the master of the UPS and the other machines as slaves to that.  When it's time to shutdown, master tells the slaves to shutdown then shuts itself down.

          Just my opinion and you may need to play around with whatever solution (timing between slaves shutting down and the master shutting down)

          1 Reply Last reply Reply Quote 0
          • P
            Peter847
            last edited by

            Many thanks for the replies.  I think I need to give you a few more details.

            I currently have NUT installed on my PfSense machine and can see the status of the UPS, I do not think it is compatible with apcupsd.  No doubt I can configure NUT to shutdown this machine but the UPS also powers two Windows machines and it does not look like the Windows port of NUT is actively supported.  I was considering using the UPS manufacturer's Windows software to shutdown the critical Windows machine and just let PfSense and the other Windows machine die when the power runs out.  But that looks like a bad idea?

            So it looks like my only solution is to buy another APC compatible UPS?

            1 Reply Last reply Reply Quote 0
            • dennypageD
              dennypage
              last edited by

              I suggest scanning the NUT package info thread. It's a long thread (20 pages), but there is a lot of good information in there. The 1st reply discusses remote access.

              There are several NUT client variants for Windows. You can find information here and here. I can't recommend any particular one because I haven't used Windows for a while.

              If you have an APC UPS, there is a apcupsd package available for pfSense. It doesn't have an official package info thread, but you can search the package forum for "apcupsd". Make sure that posts you are looking at correspond to the current generation of the package (pfSense 2.3/2.4) rather than the prior generation (pfSense 2.2 and below). It begins around here. I don't know how/if apcupsd interacts with Windows remote access, but I'm sure that someone in the package forum could provide some information.

              1 Reply Last reply Reply Quote 0
              • M
                mer
                last edited by

                Second what dennypage is saying.

                If you already have NUT on the pfSense system, you don't need/want apcupsd on it, just make it shutdown the pfSense system.  That way pfSense is the master.
                The Windows machines then run NUT as a client, over a network connection to the pfSense system.  That way the one master instance controls the other machines and should be able to shut them all down.

                It's a fairly common configuration;  moreso as machines evolved so they draw less power so a single UPS handles more than one.

                1 Reply Last reply Reply Quote 0
                • P
                  Peter847
                  last edited by

                  Many thanks for all the replies, very helpful.  I did some more digging on the NUT website, the first Windows client I found was unsupported but it appears there are others.  I'll shutdown down the Windows machine using one of these NUT clients and then bring down PfSense.

                  Thanks again.

                  1 Reply Last reply Reply Quote 0
                  • R
                    Ryu945
                    last edited by

                    @Peter847:

                    I run a small small office LAN through PfSense and am looking for advice on how I manage my UPS.

                    The UPS supplies PfSense and a couple of Windows machines.  Its main purpose is to ride through the relatively frequent power drop outs that last a few seconds, real outages (greater than a minute) are rare.  It does not look easy to get one UPS management suite that will gracefully shutdown all the machines so I am thinking about letting PfSense just run out of power.

                    PfSense runs on a passively cooled Atom system with an SSD, will I damage anything if I just let the power on the UPS run out and restart PfSense when the power returns?

                    I have commonly dropped the power on a Pfsense router I have (Basically whenever I had a need to turn it off/restart it).  Only once in a few years of doing this have I had a problem.  I somehow managed to line up one of my power drops with a process you can't drop the power on and I had to run some program to fix it so that the router would operate again.  Consdering how many times I have dropped the power and yet I had this happen only once, it is quite rare.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post
                    Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.