Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[Plugin] NUT v2 - Network UPS Tools

Featured Replies

21 minutes ago, aquariuz23 said:

HAH! How did I completely miss that line? LOL. Thank you so much, and yes it is now working perfectly fine like before :D

 

image.thumb.png.7eb0ccd515f53df2e78848115789b1ed.png

You can run this on the command line also.

/etc/rc.d/rc.nut restart or /etc/rc.d/rc.nut start

  • Replies 2.1k
  • Views 457.5k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • I am stopping updates for my version of the plugin. Update to the latest version 2023.09.17 and then you can remove my version and install Rysz's from CA and it will retain your configs.   T

  • Released 2023.07.26, @ich777 is creating a new package for me to use, and I want to look to move to 2.8 as the default version but will need to check upgrade path works ok.

  • That APC BX series is known to suffer from this (what we believe to be) firmware issue and we've put patches in place to suppress this unwanted behaviour on the UPS side. Here's how you can set it up:

Posted Images

First off, thank you for this awesome plugin! I initially attempted to set up set up my NUT server on pfsense, but I struggled with a bunch of connection issues right from the start so this was my next best alternative.

 

For some background I have a pretty old UPS that I purchased in 2014, specifically the CyberPower CP1500AVRLCD. It doesn't look anything like the current model that is shown on their website - its has a blue display and rubberized power button that lights up blue, if anyone is familiar.

 

In terms of autodetection with the NUT plugin, everything seems to be fine in terms of detecting the correct model (https://networkupstools.org/ddl/Cyber_Power_Systems/CP1500AVRLCD.html) However, I think some of the parameters that have been predefined are causing the power draw to be reported incorrectly. Specifically, it only reports about 50% of what is shown on the UPS display and the apcupsd plugin (I'm not using this plugin simultaneously btw). My assumption is that since battery.voltage.nominal is set to 12 and I have two 12 volt batteries wired in series in this UPS, it is incorrectly reporting the power draw. The confusing part is that battery.voltage reports around 13.8-13.9, so that somewhat invalidates my theory. Any thoughts on how I might go about addressing this issue? Can I just make some ups.conf adjustments myself, or are these fields not user definable? I'm attaching my current configuration for reference, I'd appreciate any help you can provide!

 

EDIT: I just noticed ups.realpower.nominal is reported as 388 - I assume this should state 900 for my UPS

 

172079762_Screenshotfrom2024-02-0117-06-36.thumb.png.59bea2d9d4ddecd4de8e0196e2ae91e3.png391911804_Screenshotfrom2024-02-0117-07-18.thumb.png.c6f2b6744a2d8b20503b03f8b25e06ea.png

Edited by cinsun42
additional information

3 hours ago, cinsun42 said:

First off, thank you for this awesome plugin! I initially attempted to set up set up my NUT server on pfsense, but I struggled with a bunch of connection issues right from the start so this was my next best alternative.

 

For some background I have a pretty old UPS that I purchased in 2014, specifically the CyberPower CP1500AVRLCD. It doesn't look anything like the current model that is shown on their website - its has a blue display and rubberized power button that lights up blue, if anyone is familiar.

 

In terms of autodetection with the NUT plugin, everything seems to be fine in terms of detecting the correct model (https://networkupstools.org/ddl/Cyber_Power_Systems/CP1500AVRLCD.html) However, I think some of the parameters that have been predefined are causing the power draw to be reported incorrectly. Specifically, it only reports about 50% of what is shown on the UPS display and the apcupsd plugin (I'm not using this plugin simultaneously btw). My assumption is that since battery.voltage.nominal is set to 12 and I have two 12 volt batteries wired in series in this UPS, it is incorrectly reporting the power draw. The confusing part is that battery.voltage reports around 13.8-13.9, so that somewhat invalidates my theory. Any thoughts on how I might go about addressing this issue? Can I just make some ups.conf adjustments myself, or are these fields not user definable? I'm attaching my current configuration for reference, I'd appreciate any help you can provide!

 

EDIT: I just noticed ups.realpower.nominal is reported as 388 - I assume this should state 900 for my UPS

 

172079762_Screenshotfrom2024-02-0117-06-36.thumb.png.59bea2d9d4ddecd4de8e0196e2ae91e3.png391911804_Screenshotfrom2024-02-0117-07-18.thumb.png.c6f2b6744a2d8b20503b03f8b25e06ea.png

 

Since your UPS doesn't provide the actual power draw it's calculated from the load and nominal power (wrongly 388W). There's a setting in the GUI: "UPS Power and Load Display Settings" where you can override the wrongly reported nominal power values ("Manual"). You should put your actual values 1500VA/900W there and it'll then show the correct power draw in the GUI.

 

Please let me know if that worked for you!

 

Edited by Rysz

13 minutes ago, Rysz said:

 

Since your UPS doesn't provide the actual power draw it's calculated from the load and nominal power (wrongly 388W). There's a setting in the GUI: "UPS Power and Load Display Settings" where you can override the reported nominal power settings ("Manual"), you should put your actual values there and it'll then show the correct power draw in the GUI.

 

Please let me know if that worked for you!

 

 

So simple, that works perfectly. Thank you!

Found i have ups.beeper.status=muted , and cant enable by pressing on button also by command :

 

upscmd -u admin -p adminpass Eaton9E2000i beeper.enable

 

 

 image.png.02c995383d41b5c398a734f720d8bdca.png

 

using NUT for 9E 2000i 

Edited by Masterwishx

2 minutes ago, Masterwishx said:

Found i have ups.beeper.status=muted , and cant enable by pressing on button also by command :

 

upscmd -u admin -p adminpass Eaton9E2000i beeper.enable

 

 

 image.png.02c995383d41b5c398a734f720d8bdca.png

 

using NUT for 9E 2000i 

 

Can you try beeper.on instead of beeper.enable? 

14 minutes ago, Rysz said:

Can you try beeper.on instead of beeper.enable? 

 

Yes i tryed also not working

only beeper.disable working , when beeper.enable after its goes to mute

i mean its stacked in mute, i tryed power off the wall switch , then UPS goes to battery and beeper is working every 4sec but status is still mute ...

Just now, Masterwishx said:

i mean its stacked in mute, i tryed power off the wall switch , then UPS goes to battery and beeper is working every 4sec but status is still mute ...

 

Then it's probably just reported wrongly by the driver, if the beeper is otherwise working that's the most important thing.

OK, strange i think it was OK befor . also i see OK after every sended commands ...

  • 2 weeks later...

Hello Guys,

 

I was able to make my APC Back-Ups BZ1200-BR be detected by NUT Plugin using the "solis" driver, but for some reason the status and data from the UPS is not updated in real time. I only get the new data/status when I click "Restart Nut" buttom. I know this driver is not perfect but I only need to turn off my server when status is changed to battery. Anybody else already experienced it or can give me some tips where to look at?

 

Thanks in advance! 😃

 

img2.png

 

 

img1.png

17 hours ago, njpj said:

Hello Guys,

 

I was able to make my APC Back-Ups BZ1200-BR be detected by NUT Plugin using the "solis" driver, but for some reason the status and data from the UPS is not updated in real time. I only get the new data/status when I click "Restart Nut" buttom. I know this driver is not perfect but I only need to turn off my server when status is changed to battery. Anybody else already experienced it or can give me some tips where to look at?

 

Thanks in advance! 😃

 

img2.png

 

 

img1.png

 

Can you try changing the NUT backend to "release (2.8.0 stable)" and see if that works?

In NUT Settings using the "Network UPS Tools Backend Switch" (need to reboot after switching).

 

If that doesn't work you can also try the oldest backend "legacy (2.7.4. stable)".

Please let me know if any of those suggestions worked for you!

 

Edited by Rysz

On 2/17/2024 at 1:06 PM, Rysz said:

 

Can you try changing the NUT backend to "release (2.8.0 stable)" and see if that works?

In NUT Settings using the "Network UPS Tools Backend Switch" (need to reboot after switching).

 

If that doesn't work you can also try the oldest backend "legacy (2.7.4. stable)".

Please let me know if any of those suggestions worked for you!

 

 

Hello Rysz,

 

First of all, really thank You for your repply.

 

I tried all backends available, unfortunately with no luck.

 

What I noticed is that the data gets refreshed, but only 1-2 times / hour. I was not able to catch exactly the period it's refreshing.

 

Do you know if maybe there's some place where I can change this refresh frequency?

 

Thank You 😉

 

 

Has this plugin been deprecated?  It's no longer showing in Community Apps.

14 minutes ago, Jacon said:

Has this plugin been deprecated?  It's no longer showing in Community Apps.

 

No, shows just fine here - perhaps you were looking for an older and deprecated version? The only currently and actively maintained one is by me (Rysz).

2 hours ago, Jacon said:

Has this plugin been deprecated?  It's no longer showing in Community Apps.

CA was broken for a moment.

Is it possible to use upssched with this plugin?

 

NOTIFYCMD "/usr/sbin/nut-notify"

 

I believe no, as the notifycmd has to be upssched-cmd - or is there an alternative way to run a custom script *after* the server has been forced to shutdown? (I want to run a script to shutdown my esxi server, but want to ensure this Unraid VM has all but finished before doing so).

 

At the moment, I am using UserScripts to do it on Array Shutdown, but upssched would be cleaner.

 

21 minutes ago, fezster said:

Is it possible to use upssched with this plugin?

 

NOTIFYCMD "/usr/sbin/nut-notify"

 

I believe no, as the notifycmd has to be upssched-cmd - or is there an alternative way to run a custom script *after* the server has been forced to shutdown? (I want to run a script to shutdown my esxi server, but want to ensure this Unraid VM has all but finished before doing so).

 

At the moment, I am using UserScripts to do it on Array Shutdown, but upssched would be cleaner.

 

 

Sure - set everything up in GUI first - then switch "Enable Manual Configuration:" to "Yes".

 

Afterwards you can modify upsmon.conf inside the GUI editor:

  • NOTIFYCMD "/usr/sbin/upssched"
  • NOTIFYFLAG as needed (see manual)

Rest of the configuration is done in upssched.conf also inside GUI editor.

 

Manual mode ensures the changes won't get overwritten; manuals for configuration are here:

Make sure to keep "Enable Manual Configuration:" on "Yes" otherwise the changes are overwritten.

 

Note that using upssched you'll only have the default NUT functionality (which is initiating shutdown on UPS low battery event) and no additional triggers as with the GUI (such as battery level, runtime remaining, time on battery) so you'll have to set those up yourself within upssched if you need them. Manual configuration mode only uses what's set up inside the configuration files, hence most GUI settings are not shown in this mode.

 

Edited by Rysz

3 hours ago, Rysz said:

 

Sure - set everything up in GUI first - then switch "Enable Manual Configuration:" to "Yes".

 

Afterwards you can modify upsmon.conf inside the GUI editor:

  • NOTIFYCMD "/usr/sbin/upssched"
  • NOTIFYFLAG as needed (see manual)

Rest of the configuration is done in upssched.conf also inside GUI editor.

 

Manual mode ensures the changes won't get overwritten; manuals for configuration are here:

Make sure to keep "Enable Manual Configuration:" on "Yes" otherwise the changes are overwritten.

 

Note that using upssched you'll only have the default NUT functionality (which is initiating shutdown on UPS low battery event) and no additional triggers as with the GUI (such as battery level, runtime remaining, time on battery) so you'll have to set those up yourself within upssched if you need them. Manual configuration mode only uses what's set up inside the configuration files, hence most GUI settings are not shown in this mode.

 

 

Thank you - I expected as much. I have everything working as required with the GUI settings, so was only looking for an easy way to add an additional script to run as part of the shutdown sequence. It's not easy to modify rc.nut / rc.0 / rc.6 - maybe as a future enhancement a GUI option could be added for an additional script to run just before shutdown?

 

Thanks for this plugin btw!

37 minutes ago, fezster said:

 

Thank you - I expected as much. I have everything working as required with the GUI settings, so was only looking for an easy way to add an additional script to run as part of the shutdown sequence. It's not easy to modify rc.nut / rc.0 / rc.6 - maybe as a future enhancement a GUI option could be added for an additional script to run just before shutdown?

 

Thanks for this plugin btw!

 

You can't really edit those files as they are only present in RAM and any changes will be lost after a reboot. The problem with  allowing additional user-scripting within NUT's shutdown routine is users could in theory torpedo Unraid's graceful shutdown process if they're not careful about what they are doing and solving this with inbuilt timeouts and whatnot would be a bit out of NUT's scope. In general the NUT server should be the machine that shuts down last, in your case it's a bit of an exotic situation compared to most user's setups but I understand what you're trying to achieve.

 

So in your case I'd advise to stick with the User Scripts solution because that way you'll still get the graceful shutdown if your script should fail for any reason because the Unraid shutdown time-out (configurable under "Disk Settings") will kick in and proceed with the graceful shutdown regardless of a hanging User Script. Worst case it won't be able to shutdown the ESXI hypervisor but your Unraid VM will be safely shutdown anyhow. Sorry I can't be of more help there!

2 hours ago, Rysz said:

So in your case I'd advise to stick with the User Scripts solution because that way you'll still get the graceful shutdown if your script should fail for any reason because the Unraid shutdown time-out (configurable under "Disk Settings") will kick in and proceed with the graceful shutdown regardless of a hanging User Script. Worst case it won't be able to shutdown the ESXI hypervisor but your Unraid VM will be safely shutdown anyhow. Sorry I can't be of more help there!

 

Agreed, appreciate the input.

 

On a slightly different topic - I see increased CPU utilization with NUT running. I'm using a Cyberpower BR700ELCD with the usbhid-ups driver.

 

I've changed the pollinterval to 15 which has helped, but I see consistent spikes (which arent there if I shut down NUT). Is this normal?

 

[ups]
driver = usbhid-ups
port = auto

# If not in manual mode, put any additional settings below this line
desc = "BR700ELCD"
offdelay = 180
ondelay = 0
ignorelb
override.battery.charge.low = 20
override.battery.charge.warning = 40
pollinterval = 15

 

Edited by fezster

14 minutes ago, fezster said:

 

Agreed, appreciate the input.

 

On a slightly different topic - I see increased CPU utilization with NUT running. I'm using a Cyberpower BR700ELCD with the usbhid-ups driver.

 

I've changed the pollinterval to 15 which has helped, but I see consistent spikes (which arent there if I shut down NUT). Is this normal?

 

[ups]
driver = usbhid-ups
port = auto

# If not in manual mode, put any additional settings below this line
desc = "BR700ELCD"
offdelay = 180
ondelay = 0
ignorelb
override.battery.charge.low = 20
override.battery.charge.warning = 40
pollinterval = 15

 

 

It shouldn't really cause very noticeable CPU utilization but depends on the UPS driver and your system too (CPU/RAM). Then again NUT does have 3 different services running (driver, upsd and upsmon) so it's not extremely lightweight. Could also be the USB bus or CyberPower subdriver needing to do more heavy lifting to speak the UPS required protocol and communication language.

 

Bottom line it's hard to say, if you're on an old system with a weaker processor or few RAM reserves it might be more noticeable. But there's not really much we can do, if it persists you could attempt to restart the server at some point. A restart of the system will always freshly install NUT onto the RAM disk, so you'll start with a fresh package just to rule out any brokenness causing this. Another USB port is also worth attempting.

 

Also check out the "pollfreq" option, may or may not be worth playing around with:

https://networkupstools.org/docs/man/usbhid-ups.html

 

Edited by Rysz

On 2/18/2024 at 8:10 PM, njpj said:

 

Hello Rysz,

 

First of all, really thank You for your repply.

 

I tried all backends available, unfortunately with no luck.

 

What I noticed is that the data gets refreshed, but only 1-2 times / hour. I was not able to catch exactly the period it's refreshing.

 

Do you know if maybe there's some place where I can change this refresh frequency?

 

Thank You 😉

 

 

 

I can't really help more there, unfortunately, it's most probably a driver issue.

The default refresh is 5 seconds for the status, so I'm guessing the connection is going stale.

You could open an issue on NUT GitHub about it: https://github.com/networkupstools/nut/issues

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.