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

5 hours ago, cassiusdrow said:

I use some commands in my go script that alter dmacias's plugin scripts to use NUT 2.8 and net-snmp 5.9.3 as explained in this post:

Thanks I will review, I am guessing the stock APCUPSD doesn't support what you need hence unsing NUT?

 

net-snmp  is loaded if you install the snmp plugin.

Edited by SimonF

  • Replies 2.1k
  • Views 457.6k
  • 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

6 hours ago, SimonF said:

I am guessing the stock APCUPSD doesn't support what you need hence unsing NUT?

 

I didn't look at using APCUPSD at all.  I have a lot of time invested in the NUT configuration and I run it in netserver mode for other computers.  Originally, I was using a Cyberpower CST135XLU and switched to the APC SMT1000RM2U after moving the Unraid server to a rack in my basement.  The Cyberpower CST135XLU is now used with a different Unraid server and I prefer the simplicity of using similar UPS control configurations for both servers.  I also monitor both UPSs with telegraf/grafana/influxdb.

 

Replacing the NUT and net-snmp packages while still using dmacias's plugin was the easiest solution.  I think there was a feature in NUT 2.8 that I wanted but I don't remember what it was.  However, the NUT 2.8 package I found is compiled with different locations for the configuration files and process ID file, so I modified the plugin scripts from the go script since it looked unlikely that dmacias would update the plugin.

 

I looked at the changes in your plugin vs dmacias's plugin, and I think my solution will continue to work with your plugin, although I haven't tested it.  I'll switch to your plugin on one of my servers and test it.

27 minutes ago, cassiusdrow said:

 

I didn't look at using APCUPSD at all.  I have a lot of time invested in the NUT configuration and I run it in netserver mode for other computers.  Originally, I was using a Cyberpower CST135XLU and switched to the APC SMT1000RM2U after moving the Unraid server to a rack in my basement.  The Cyberpower CST135XLU is now used with a different Unraid server and I prefer the simplicity of using similar UPS control configurations for both servers.  I also monitor both UPSs with telegraf/grafana/influxdb.

 

Replacing the NUT and net-snmp packages while still using dmacias's plugin was the easiest solution.  I think there was a feature in NUT 2.8 that I wanted but I don't remember what it was.  However, the NUT 2.8 package I found is compiled with different locations for the configuration files and process ID file, so I modified the plugin scripts from the go script since it looked unlikely that dmacias would update the plugin.

 

I looked at the changes in your plugin vs dmacias's plugin, and I think my solution will continue to work with your plugin, although I haven't tested it.  I'll switch to your plugin on one of my servers and test it.

My plugin is a fork, main changes are to add a 6.12 dashboard & php 8 fixes. Will look to update over the next few weeks.

 

Edited by SimonF

1 hour ago, SimonF said:

Will look to update over the next few weeks.

 

Thank you. I appreciate it.

 

I've started using your plugin on both of my servers.  I am using my go script commands to modify it to work with NUT 2.8 and everything runs ok for plugin version 2023.02.14.

I have a UPS that I've been using for 6 years, it was handling Unraid machine, Windows PC and a Mac. I've upgraded GPU on my PC machine and the UPS is no longer sufficient, so I bought a bigger one. Now having 2 I'd like first one to handle Unraid and the second one to handle the other 2 computers. Both UPSes and Unraid machine are in one room and the PC and Mac are in the office. I have a power line running from one room to another (I've had it installed while renovating so that I don't have to have annoying UPS sound in the office). Now the question is how to get my main PC shut down in case of power failure.

 

So far I was using the Unraid builtin capabilities to communicate with UPS, but now having 2 I thought that the 2nd one can be connected to the NUT plugin, but when I start NUT it always connects to the first one.

 

How can I select which UPS NUT will connect to?

 

Here is output after clicking "Autodetect":

 

[nutdev1]
driver = "usbhid-ups"
port = "auto"
vendorid = "051D"
productid = "0002"
product = "Back-UPS XS 1400U FW:926.T1 .I USB FW:T1"
serial = "3B1451X16024"
vendor = "American Power Conversion"
bus = "005"
[nutdev2]
driver = "usbhid-ups"
port = "auto"
vendorid = "051D"
productid = "0002"
product = "Back-UPS BX2200MI FW:378700G -302202G"
serial = "9B2221A44604"
vendor = "American Power Conversion"
bus = "005"

 

8 minutes ago, Trylo said:

I have a UPS that I've been using for 6 years, it was handling Unraid machine, Windows PC and a Mac. I've upgraded GPU on my PC machine and the UPS is no longer sufficient, so I bought a bigger one. Now having 2 I'd like first one to handle Unraid and the second one to handle the other 2 computers. Both UPSes and Unraid machine are in one room and the PC and Mac are in the office. I have a power line running from one room to another (I've had it installed while renovating so that I don't have to have annoying UPS sound in the office). Now the question is how to get my main PC shut down in case of power failure.

 

So far I was using the Unraid builtin capabilities to communicate with UPS, but now having 2 I thought that the 2nd one can be connected to the NUT plugin, but when I start NUT it always connects to the first one.

 

How can I select which UPS NUT will connect to?

 

Here is output after clicking "Autodetect":

 

[nutdev1]
driver = "usbhid-ups"
port = "auto"
vendorid = "051D"
productid = "0002"
product = "Back-UPS XS 1400U FW:926.T1 .I USB FW:T1"
serial = "3B1451X16024"
vendor = "American Power Conversion"
bus = "005"
[nutdev2]
driver = "usbhid-ups"
port = "auto"
vendorid = "051D"
productid = "0002"
product = "Back-UPS BX2200MI FW:378700G -302202G"
serial = "9B2221A44604"
vendor = "American Power Conversion"
bus = "005"

 

Maybe have a small system like a pi to connect to the ups and use nut on it to make available on network. Use slave on the pc to connect to pi?

1 minute ago, SimonF said:

Maybe have a small system like a pi to connect to the ups and use nut on it to make available on network. Use slave on the pc to connect to pi?

It's a good idea, but wouldn't a lightweight Linux VM make more sense and pass through the USB with the 2nd UPS?
I guess this can be my plan B, I'd rather use the NUT plugin.

1 minute ago, Trylo said:

It's a good idea, but wouldn't a lightweight Linux VM make more sense and pass through the USB with the 2nd UPS?
I guess this can be my plan B, I'd rather use the NUT plugin.

Yes could be an option. Would Unraid shutdown and the vm before the pc needs to?

5 minutes ago, SimonF said:

Yes could be an option. Would Unraid shutdown and the vm before the pc needs to?

Good thinking. I'd say it's unlikely. If the PC or Mac is underload for sure not, but if both are ideal it may be close... In this case a RaspberryPi would be safer...

@SimonF so are you saying there is no way to set it up using the plugin?

1 minute ago, Trylo said:

@SimonF so are you saying there is no way to set it up using the plugin?

Not sure I would need to look into it. It looks like it is using the USB IDs for Vendor:Product which the same based on config. 

 

I only have a single ups.

 

My ups config is

 

[ups]
driver = nutdrv_qx
port = auto
 

maybe port can be set to a specific usb devices.

I found this in the documentation (https://networkupstools.org/docs/man/usbhid-ups.html😞

"

device = regex

Select a UPS on a specific USB device or group of devices. The argument is a regular expression that must match the device name where the UPS is connected (e.g. device="001" or device="00[1-2]") as seen in /proc/bus/usb/devices or lsusb(8); including leading zeroes. Note that device numbers are not guaranteed by the OS to be stable across re-boots or device re-plugging.

"

My device is:

Bus 005 Device 038 Port 5-1 ID 051d:0002 American Power Conversion Uninterruptible Power Supply

 

So I added device="038" to /etc/nut/ups.conf in Config Editor

 

But upon reloading I got this:

"Duplicate driver instance detected (PID file /var/run/nut/usbhid-ups-ups.pid exists)! Terminating other driver!"

 

 And NUT then reverts back ups.conf to the previous state.

@SimonF Thanks for the work on this plugin

 

After the last update I am getting the following error:

 

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
/usr/libexec/nut/snmp-ups: error while loading shared libraries: libnetsnmp.so.35: cannot open shared object file: No such file or directory
Driver failed to start (exit status=127)


I found the following

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.30
/usr/lib64/libnetsnmp.so.30.0.3

I then installed:

image.png.e01120cbbcc10a1b269e5a829617648e.png

and now I see the following:

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so.40
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.40.2.0

 

I created a symlink for the library: `ls -s /usr/lib64/libnetsnmp.so.40 /usr/lib64/libnetsnmp.so.35`

 

and now am getting the following:

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
Network UPS Tools - Generic SNMP UPS driver 1.07 (2.7.4.1)
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No supported device detected
Driver failed to start (exit status=1)

 

The plugins:

image.png.bcfc752f869578e6716b07700bfbd71d.png

 

On 3/29/2023 at 9:13 AM, Clifford W. Hansen said:

@SimonF Thanks for the work on this plugin

 

After the last update I am getting the following error:

 

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
/usr/libexec/nut/snmp-ups: error while loading shared libraries: libnetsnmp.so.35: cannot open shared object file: No such file or directory
Driver failed to start (exit status=127)


I found the following

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.30
/usr/lib64/libnetsnmp.so.30.0.3

I then installed:

image.png.e01120cbbcc10a1b269e5a829617648e.png

and now I see the following:

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so.40
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.40.2.0

 

I created a symlink for the library: `ls -s /usr/lib64/libnetsnmp.so.40 /usr/lib64/libnetsnmp.so.35`

 

and now am getting the following:

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
Network UPS Tools - Generic SNMP UPS driver 1.07 (2.7.4.1)
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No supported device detected
Driver failed to start (exit status=1)

 

The plugins:

image.png.bcfc752f869578e6716b07700bfbd71d.png

 

I dont use SNMP, but @cassiusdrowdoes, I am looking to build a test 2.8 + updated SNMP over the weekend which may help.

On 3/26/2023 at 6:56 PM, cassiusdrow said:

 

Thank you. I appreciate it.

 

I've started using your plugin on both of my servers.  I am using my go script commands to modify it to work with NUT 2.8 and everything runs ok for plugin version 2023.02.14.

Do you run on a single server? or are you using slaves also?

On 3/29/2023 at 9:13 AM, Clifford W. Hansen said:

@SimonF Thanks for the work on this plugin

 

After the last update I am getting the following error:

 

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
/usr/libexec/nut/snmp-ups: error while loading shared libraries: libnetsnmp.so.35: cannot open shared object file: No such file or directory
Driver failed to start (exit status=127)


I found the following

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.30
/usr/lib64/libnetsnmp.so.30.0.3

I then installed:

image.png.e01120cbbcc10a1b269e5a829617648e.png

and now I see the following:

root@medusa:~# find / -iname "libnetsnmp.so*"
/usr/lib64/libnetsnmp.so.40
/usr/lib64/libnetsnmp.so
/usr/lib64/libnetsnmp.so.40.2.0

 

I created a symlink for the library: `ls -s /usr/lib64/libnetsnmp.so.40 /usr/lib64/libnetsnmp.so.35`

 

and now am getting the following:

root@medusa:~# /usr/local/emhttp/plugins/nut/scripts/start
Writing nut config
Updating permissions...
Network UPS Tools - UPS driver controller 2.7.4.1
Network UPS Tools - Generic SNMP UPS driver 1.07 (2.7.4.1)
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No matching MIB found for sysOID '.1.3.6.1.4.1.8072.3.2.10'!
Please report it to NUT developers, with an 'upsc' output for your device.
Going back to the classic MIB detection method.
No supported device detected
Driver failed to start (exit status=1)

 

The plugins:

image.png.bcfc752f869578e6716b07700bfbd71d.png

 

@cassiusdrow

 

I have created a test 2.8 version  https://raw.githubusercontent.com/SimonFair/NUT-unRAID/master/plugin/nut-2.8.0.plg

 

Only tested on a slave node so far not the netserver one. You will need to remove the orignal plugin to install this version.

 

Error message in logs. Apr  1 12:10:23 GUITest upsmon[11117]: Login on UPS [[email protected]] failed - got [ERR ACCESS-DENIED] but does connect.

 

 

4 hours ago, SimonF said:

@cassiusdrow

 

I have created a test 2.8 version  https://raw.githubusercontent.com/SimonFair/NUT-unRAID/master/plugin/nut-2.8.0.plg

 

Only tested on a slave node so far not the netserver one. You will need to remove the orignal plugin to install this version.

 

Error message in logs. Apr  1 12:10:23 GUITest upsmon[11117]: Login on UPS [[email protected]] failed - got [ERR ACCESS-DENIED] but does connect.

 

 

Thanks @SimonF it's working again 🙂

1 minute ago, Clifford W. Hansen said:

Thanks @SimonF it's working again 🙂

Good to hear. I may have to make to tweaks, which Unraid Version are you running. As need to check backwards compatability before updating main plugin.

23 hours ago, SimonF said:

Do you run on a single server? or are you using slaves also?

 

I have two unraid servers, each has its own UPS, and each runs the NUT plugin in netserver mode.  Each unraid server has other computers (not running unraid OS) on the same UPSs, running NUT in netclient (slave) mode and communicating with the unraid servers.

 

 

7 hours ago, SimonF said:

I have created a test 2.8 version  https://raw.githubusercontent.com/SimonFair/NUT-unRAID/master/plugin/nut-2.8.0.plg

 

Only tested on a slave node so far not the netserver one. You will need to remove the orignal plugin to install this version.

 

Thank you.  I'll check it out as soon as I can.  It may be a few days.

Is it possible to check UPS firmware a bit more in depth with usbhid-ups? Mine says "ups.firmware = 264" and that doesn't really tell me anything heh. UPS is HP T1000 G3. It has a reccomended firmware upgrade to bypass false fan fault that randomly can occur and enable faster switching on undervoltage. 

20 minutes ago, Arandomdood said:

Is it possible to check UPS firmware a bit more in depth with usbhid-ups? Mine says "ups.firmware = 264" and that doesn't really tell me anything heh. UPS is HP T1000 G3. It has a reccomended firmware upgrade to bypass false fan fault that randomly can occur and enable faster switching on undervoltage. 

Nut will just report values passed via usb from the device. There may be HP software that may provide more info have you looked at firmware downloads on hp site for update info?

5 minutes ago, SimonF said:

Nut will just report values passed via usb from the device. There may be HP software that may provide more info have you looked at firmware downloads on hp site for update info?

I have indeed. I guess I could shut down NUT and hook up the UPS to a windows laptop real quick to avoid passthru VM within unraid since I'm lazy, but I didn't want to break the NUT connection if not needed yet as I'm not sure if it will be successfully reestablished without a machine restart heh. Never tried it before

Hi,
I'm trying to figure out how to put the right numbers in the driver.parameter.runtimecal: = AAA,100,BBB,50

I have PowerWalker UPS VFI1500 CGPF1

https://powerwalker.com/product/10122109/

 

What is the right value for me, on AAA and BBB ?

 

image.png

11 hours ago, CiscoCoreX said:

Hi,
I'm trying to figure out how to put the right numbers in the driver.parameter.runtimecal: = AAA,100,BBB,50

I have PowerWalker UPS VFI1500 CGPF1

https://powerwalker.com/product/10122109/

 

What is the right value for me, on AAA and BBB ?

 

image.png

 

 

driver.parameter.runtimecal = 180,100,618,50

 

"Full load backup time [min]" = 3.0 * 60 = 180 seconds

"Half load backup time [min]" = 10.3 * 60 = 618 seconds

 

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.