NUT package (2.8.0 and below)
-
@stompro "ondelay=-1" sets the UPS to never restart after the power returns, "ondelay=0" seems to say return once power has returned.
I thought there may be a power race condition, but with "ondelay=0" it seems to work. If the power returns right after the system starts shutting down, the UPS will still turn off after the offdelay period, and then it will power back on shortly afterwards(10 seconds) so everything comes back up correctly.
Josh
-
Glad you got it to work. Interesting info on shutdown delay for the cyberpower. I didn’t know that. Thanks.
-
@dennypage It looks like there is movement to fix the defaults for cyberpower systems in the future, If the default values were 60 for offdelay and 0 for ondelay then the UPS would just work for most purposes. https://github.com/networkupstools/nut/issues/432 I added my 2 cents to that issue. If you own any other Cyberpower models I would be very curious of the ondelay issue is only with the OR models, or if that is the way they all work?
-
Do you fully recommend using the nut package instead of apcupsd for an APC BR1500GI UPS? If so, why?
Also, how do I reset the battery.date variable in nut to the correct date? Mine is set to 2001 which is obviously wrong. I guess I forgot to do a reset in PowerChute when I replaced my batteries 1.5 years ago.
-
If you are using an locally attached APC ups, I would say that the choice of NUT vs apcupsd is a matter of personal preference. Both packages are maintained. The apcupsd package offers a more "native" APC feel. The NUT package offers a dashboard widget. Either should work fine.
upsrw is used to set information in a UPS. See the man upsrw man page here.
-
@dennypage said in NUT package:
If you are using an locally attached APC ups, I would say that the choice of NUT vs apcupsd is a matter of personal preference. Both packages are maintained. The apcupsd package offers a more "native" APC feel. The NUT package offers a dashboard widget. Either should work fine.
upsrw is used to set information in a UPS. See the man upsrw man page here.
I see. What is your personal preference between the two? Are both updated in the pfsense package manager section? When I go to apcupsd's website, I see that the latest changelog there was from 2016, I believe. So I was under the assumption that it wasn't maintained. Can apcupsd also act a server to slave servers in the network?
-
When I referred to packages being maintained, I was referring to the pfSense packages. You can see the changelog for the apcupsd package here, and the changelog for the NUT package here.
apcupsd does offer some form of remote protocol support. I'm not overly familiar with it's capabilities other than knowing that NUT has a client for it (described here).
My personal preference? I'm the author/maintainer of the NUT package.
-
I use both, acpupsd to connect to the UPS, act as the NIS and shutdown pfSense when the batts are low. NUT is setup with "Remote apcupsd", simply to have the widget on the dashboard. Best of both worlds IMHO.
-
@dennypage said in NUT package:
When I referred to packages being maintained, I was referring to the pfSense packages. You can see the changelog for the apcupsd package here, and the changelog for the NUT package here.
apcupsd does offer some form of remote protocol support. I'm not overly familiar with it's capabilities other than knowing that NUT has a client for it (described here).
My personal preference? I'm the author/maintainer of the NUT package.
I see. I knew you were going to say that :)
@grimson said in NUT package:
I use both, acpupsd to connect to the UPS, act as the NIS and shutdown pfSense when the batts are low. NUT is setup with "Remote apcupsd", simply to have the widget on the dashboard. Best of both worlds IMHO.
Sorry, I'm new to including the UPS in the network so I'd have to ask some questions about this. So you're using apcupsd to actually interface with the UPS locally and it controls only pfsense? And then NUT does the signalling to remote clients?
What does "remote apcupsd" mean?
-
@grimson said in NUT package:
I use both, acpupsd to connect to the UPS, act as the NIS and shutdown pfSense when the batts are low. NUT is setup with "Remote apcupsd", simply to have the widget on the dashboard. Best of both worlds IMHO.
I understand that this works... but if you are going to use NUT anyway I think using apcupsd to manage the UPS is a little excessive...
-
@kevindd992002 said in NUT package:
Sorry, I'm new to including the UPS in the network so I'd have to ask some questions about this. So you're using apcupsd to actually interface with the UPS locally and it controls only pfsense? And then NUT does the signalling to remote clients?
No, apcupsd acts as the NIS and remote apcupsd installations control the remote clients. NUT is only used for the dashboard widget. I first tried NUT alone, but it had trouble connecting and reading data from my Back-UPS Pro 1500, the windows client was pretty unstable and it had a much larger ressource footprint compared to apcupsd. If the apcupsd package would feature a dashboard widget I wouldn't need NUT at all.
What does "remote apcupsd" mean?
It's the connection method used in NUT to gather the UPS information from acpupsd.
-
-
I installed apcupsd and noticed some discrepancy with NUT. I'm not sure if this is a bug regarding the BATTDATE (apcupsd) and battery.date (NUT) but BATTDATE shows the correct date of 2016/05/11. While NUT shows the battery.date as 2001/09/25 which doesn't make sense. Any ideas?
-
Also, is the APCUPSD-UPS drive client of NUT the "remote apcupsd" connection method that @Grimson is referring to?
-
Is there a guide for NUT that I can read?
-
With NUT, can you set pfsense and other servers in the network to turn off when the battery charge hits 70%?
-
-
@kevindd992002 said in NUT package:
-
I installed apcupsd and noticed some discrepancy with NUT. I'm not sure if this is a bug regarding the BATTDATE (apcupsd) and battery.date (NUT) but BATTDATE shows the correct date of 2016/05/11. While NUT shows the battery.date as 2001/09/25 which doesn't make sense. Any ideas?
-
Also, is the APCUPSD-UPS drive client of NUT the "remote apcupsd" connection method that @Grimson is referring to?
-
Is there a guide for NUT that I can read?
-
With NUT, can you set pfsense and other servers in the network to turn off when the battery charge hits 70%?
-
The pfSense NUT package reports what the NUT upsc command returns (without interpretation). Either the NUT driver that supports the UPS doesn't handle the string correctly, or apcupsd caches the battery change date in the local file system. I would consider the caching to be highly unlikely, but it's possible. Either way, the best place to enquire would be the NUT mailing lists. You can find information here.
-
Yes.
-
Yes, the NUT support site has a user guide and manuals.
-
Yes, local and remote shutdown is what NUT does for a living. Information on remote access in the second post of this thread. Plenty of discussion about controlling shutdown percentages earlier in this thread. Look for things like this:
ignorelb override.battery.charge.low = 50 override.battery.runtime.low = 60
See the 'ignorelb' section in the ups.conf manual for details on this.
-
-
Do you have a solution to the Synology slave to pfsense NUT master issue described here?
https://forum.netgate.com/topic/115387/pfsense-2-3-3-cannot-be-a-ups-nut-master-to-synology-dsm-6-1-1-nas/4
-
@kevindd992002 said in NUT package:
Do you have a solution to the Synology slave to pfsense NUT master issue described here?
https://forum.netgate.com/topic/115387/pfsense-2-3-3-cannot-be-a-ups-nut-master-to-synology-dsm-6-1-1-nas/4
Post #2 of this thread has the information on how to set up the pfSense side.
The thread you linked to has the information for the Synology side. The short version is that you have to hand edit the password in the Synology configuration after you set it up. You can google "synology remote nut" for more full examples.
-
Yes, I'm done with the pfsense side configuration. And that thread I linked looks like the OP was saying that the upsd.users gets edited to the original monuser user everytime Synology gets an update and that you were going to verify. Were you able to verify that already?
-
@kevindd992002 said in NUT package:
And that thread I linked looks like the OP was saying that the upsd.users gets edited to the original monuser user everytime Synology gets an update and that you were going to verify. Were you able to verify that already?
upsd.users is used on the server side rather than the client side, so if the UPS is attached to the pfSense host, then it is the pfSense upsd.users that must be modified.
As of DSM 6, the Synology rewrites all the ups files at startup, and is hard-coded around the default user/password, so you have to use the NUT default. Kind of stupid on Synology's part, but it is what it is.
As discussed in post #2 in this thread, you need to add config to the upsd.users on the pfSense side to support remote access. The Synology is hardcoded to these values:
[monuser] password = secret upsmon slave
FWIW, I haven't tested Synology remote access in a couple of years. Hopefully this should still work.
-
@dennypage said in NUT package:
@kevindd992002 said in NUT package:
And that thread I linked looks like the OP was saying that the upsd.users gets edited to the original monuser user everytime Synology gets an update and that you were going to verify. Were you able to verify that already?
upsd.users is used on the server side rather than the client side, so if the UPS is attached to the pfSense host, then it is the pfSense upsd.users that must be modified.
As of DSM 6, the Synology rewrites all the ups files at startup, and is hard-coded around the default user/password, so you have to use the NUT default. Kind of stupid on Synology's part, but it is what it is.
As discussed in post #2 in this thread, you need to add config to the upsd.users on the pfSense side to support remote access. The Synology is hardcoded to these values:
[monuser] password = secret upsmon slave
FWIW, I haven't tested Synology remote access in a couple of years. Hopefully this should still work.
Ahh, I see. But then you also said in one of your posts there that it is not recommended to modify the monuser credentials in the upsd.users advanced settings in pfsense as that will mess up the local monitoring, correct?
So for clients (slaves) in general, where do you specify the user credentials they use to connect to the master?
-
Also, I did already try putting the monuser/secret credentials in pfsense and add LISTEN <pfsense LAN IP> but when I configured my Synology to connect to pfsense it says cannot connect to the network UPS or something along those lines.
-
@kevindd992002 said in NUT package:
Ahh, I see. But then you also said in one of your posts there that it is not recommended to modify the monuser credentials in the upsd.users advanced settings in pfsense as that will mess up the local monitoring, correct?
So for clients (slaves) in general, where do you specify the user credentials they use to connect to the master?
You are adding to upsd.users rather than changing the content already there.
Client side credentials are in upsmon.conf. Server side are in upsd.users.