1
General Discussion / [FIXED] os-nut plugin permissions issue
« on: November 25, 2020, 03:36:26 pm »
I have NUT usb permissions issue
It doesn't work, always UPS APC is unavailable end errors like
Command:
In logs I see errors like
restarting nut
returned exit status 1
Command:
Config file
I've set /etc/devfs.conf to
Reloaded rules with
If I run from console
If I run without root parameter
So it seams to NUT USB permissions issue, I can't reboot right now after I edited /etc/devfs.conf but I reloaded devfs service
Please help!
It doesn't work, always UPS APC is unavailable end errors like
Command:
Code: [Select]
/usr/local/etc/rc.d/nut restart
Output:Code: [Select]
nut not running? (check /var/db/nut/upsd.pid).
Network UPS Tools - UPS driver controller 2.7.4
Network UPS Tools - Generic HID driver 0.41 (2.7.4)
USB communication driver 0.33
No matching HID UPS found
Driver failed to start (exit status=1)
/usr/local/etc/rc.d/nut: WARNING: failed precmd routine for nut
In logs I see errors like
restarting nut
returned exit status 1
Command:
Code: [Select]
usbconfig
Output:Code: [Select]
ugen0.1: <Intel EHCI root HUB> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen0.2: <vendor 0x8087 product 0x07db> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen0.3: <American Power Conversion Back-UPS XS 700U FW:924.Z3 .I USB FW:Z3> at usbus0, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (24mA)
ugen0.4: <Generic Ultra Fast Media> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (96mA)
Config file
Code: [Select]
/usr/local/etc/nut/ups.conf
Code: [Select]
[APC]
driver=usbhid-ups
port=ugen0.3
I've set /etc/devfs.conf to
Code: [Select]
perm usb0 0770
own usb0 root:uucp
perm uhid0 0770
own uhid0 root:uucp
[nut_usb=10]
add path 'ugen0.3' group wheel user uucp mode 0770
add path 'usb/0.3.0' group wheel user uucp mode 0770
Reloaded rules with
Code: [Select]
/etc/rc.d/devfs restart
If I run from console
Code: [Select]
/usr/local/libexec/nut/usbhid-ups -u root -D -a APC
it worksCode: [Select]
Network UPS Tools - Generic HID driver 0.41 (2.7.4)
USB communication driver 0.33
0.000000 debug level is '1'
0.000802 upsdrv_initups...
0.066616 Using subdriver: APC HID 0.96
0.066641 104 HID objects found
0.068696 Path: UPS.PowerSummary.iProduct, Type: Feature, ReportID: 0x01, Offset: 0, Size: 8, Value: 1
....
If I run without root parameter
Code: [Select]
/usr/local/libexec/nut/usbhid-ups -D -a APC
I get Code: [Select]
Network UPS Tools - Generic HID driver 0.41 (2.7.4)
USB communication driver 0.33
0.000000 debug level is '1'
0.000828 upsdrv_initups...
0.001004 No matching HID UPS found
So it seams to NUT USB permissions issue, I can't reboot right now after I edited /etc/devfs.conf but I reloaded devfs service
Please help!