UPS w/ FreeNAS & Router

rmccullough

Patron
Joined
May 17, 2018
Messages
269
I am running a pfSense firewall/router in the same crawlspace next to my FreeNAS server. I am purchasing a UPS that I plan to use as a backup for the firewall/router and FreeNAS server. I know that FreeNAS can be configured as the master or slave (and I assume pfSense can as well). Is there a recommended approach here? I know that one system will be directly connected to the UPS via a USB cable, however, I would prefer FreeNAS to power down immediately but the pfSense server to keep running until the UPS drops to a threshold where pfSense can shutdown gracefully.

The reason I would like to keep the pfSense server running as long as possible is that when it is powered off/on, it will usually have trouble acquiring an IP address from my WAN. Additionally, I am using a fan-less mini-pc that I suspect is not drawing much power so the UPS may be able to power it for a reasonable amount of time in case the power comes within 15-30min. Granted, the time it takes to power down my FreeNAS may drain a substantial portion of the capacity, but at least it is something. The alternative would be separate UPS for each, but for now I would like to use 1 if possible.

Am I a fool for trying to use 1 UPS? Or is the right solution here to connect it to the pfSense server and use pfSense to shut down the FreeNAS server?
 

rmccullough

Patron
Joined
May 17, 2018
Messages
269
Is this in the wrong forum?

I got my UPS and connected it to my pfSense device. Load looks good, ~26%. However, it doesn’t look like it is accessible. I am working on that from the pfSense side.
 

Heracles

Wizard
Joined
Feb 2, 2018
Messages
1,401
Hi McCullough,

Both FreeNAS and pfSense use the same software for interacting with UPS : NUT. As you said, either can be the master / the slave.

The problem with your setup is that you wish to have 2 completely different policies for your servers. With NUT, the master is the one who call others to power down before powering down itself. The easy way to enforce two different policies would be to have to UPS, one for each.

For the pfSense to last longer than FreeNAS, definitely it will need to be the master.

On how to configure NUT to do what you need, you are better to search for a forum or support group about it, more than about FreeNAS or pfSense.

Good luck with your setup,
 

rmccullough

Patron
Joined
May 17, 2018
Messages
269
I think I figured this out. Now how can I test that FreeNAS sees the UPS and that FreeNAS will act as the slave and shutdown when power is lost?
 

Heracles

Wizard
Joined
Feb 2, 2018
Messages
1,401
you do it from the CLI with NUT client : upsc upsname@NUTMasterServer
 

rmccullough

Patron
Joined
May 17, 2018
Messages
269
@Heracles yeah, I did that. Finally got it configured correctly on pfSense to act as the Master. And I hear what you are saying about referring to the NUT documentation. However, I am trying to figure out if I configured the service in the UI correctly to do what I want to do. It has options for shutting down 30 seconds after the UPS goes on battery power.
UPS Service Config.png
 
Top