[Nut-upsuser] Issue with two UPS APC managed from a single PC.
Laurent Taieb
laurenttaieb at free.fr
Fri Feb 24 22:32:16 GMT 2023
To complement
I’ve tried to launch the driver directly and got this error mesg
$ sudo /lib/nut/usbhid-ups -a myups1 -DDD
0.000000 [D1] debug level is '3'
0.001656 [D2] Initializing an USB-connected UPS with library libusb-1.0.26 (API: 0x1000109) (NUT subdriver name='USB communication driver (libusb 1.0)' ver='0.43')
0.001680 [D1] upsdrv_initups (non-SHUT)...
0.009987 [D2] Checking device 1 of 7 (051D/0003)
0.026102 [D2] - VendorID: 051d
0.026123 [D2] - ProductID: 0003
0.026140 [D2] - Manufacturer: American Power Conversion
0.026156 [D2] - Product: Smart-UPS_1500 FW:UPS 04.6 / ID=1018
0.026169 [D2] - Serial Number: AS2212262511
0.026186 [D2] - Bus: 002
0.026221 [D2] - Device: unknown
0.026235 [D2] - Device release number: 0001
0.026269 [D2] Trying to match device
0.026282 [D2] match_function_subdriver (non-SHUT mode): matching a device...
0.026323 interrupt pipe disabled (add 'pollonly' flag to 'ups.conf' to get rid of this message)
0.026348 [D3] match_function_regex: matching a device...
0.026455 [D2] match_function_regex: failed match of Device: (null)
0.026475 [D2] Device does not match - skipping
0.026668 [D2] Checking device 2 of 7 (051D/0002)
0.036755 [D2] - VendorID: 051d
0.036775 [D2] - ProductID: 0002
0.036784 [D2] - Manufacturer: American Power Conversion
0.036792 [D2] - Product: Back-UPS XS 1400U FW:926.T2 .I USB FW:T2
0.036800 [D2] - Serial Number: 4B1835P44428
0.036808 [D2] - Bus: 002
0.036817 [D2] - Device: unknown
0.036827 [D2] - Device release number: 0106
0.036841 [D2] Trying to match device
0.036858 [D2] match_function_subdriver (non-SHUT mode): matching a device...
0.036889 [D3] match_function_regex: matching a device...
0.036922 [D2] match_function_regex: failed match of Device: (null)
0.036938 [D2] Device does not match - skipping
0.036965 [D2] Checking device 3 of 7 (8087/0024)
0.037000 [D1] Failed to open device (8087/0024), skipping: Access denied (insufficient permissions)
0.037016 [D2] Checking device 4 of 7 (1D6B/0002)
0.037055 [D1] Failed to open device (1D6B/0002), skipping: Access denied (insufficient permissions)
0.037071 [D2] Checking device 5 of 7 (1BCF/2C18)
0.037097 [D1] Failed to open device (1BCF/2C18), skipping: Access denied (insufficient permissions)
0.037124 [D2] Checking device 6 of 7 (8087/0024)
0.037157 [D1] Failed to open device (8087/0024), skipping: Access denied (insufficient permissions)
0.037171 [D2] Checking device 7 of 7 (1D6B/0002)
0.037199 [D1] Failed to open device (1D6B/0002), skipping: Access denied (insufficient permissions)
0.037215 [D2] libusb1: No appropriate HID device found
0.037337 libusb1: Could not open any HID devices: insufficient permissions on everything
0.037374 No matching HID UPS found
Definitions in ups.conf. I’m unsure whether I shall define port or other items.
[myups1]
driver = usbhid-ups
port = auto
# port = /dev/usb/hiddev0
# cable = usb
desc = "Smart-UPS_1500 FW:UPS 04.6 / ID=1018"
bus = 002
device = 003
pollonly
# To find out if your driver supports any extra settings, start it with
# the -h option and/or read the driver's documentation.
[myups2]
driver = usbhid-ups
port = auto
desc = "*500*"
bus = 002
device = 005
pollony
Thanks
Laurent
De : Nut-upsuser <nut-upsuser-bounces+laurenttaieb=free.fr at alioth-lists.debian.net> au nom de Laurent Taieb via Nut-upsuser <nut-upsuser at alioth-lists.debian.net>
Répondre à : "laurenttaieb at free.fr" <laurenttaieb at free.fr>
Date : vendredi 24 février 2023 à 23:17
À : Jim Klimov <jimklimov+nut at gmail.com>, nut-upsuser Mailing List <nut-upsuser at lists.alioth.debian.org>
Objet : Re: [Nut-upsuser] Issue with two UPS APC managed from a single PC.
Hi Jim,
Yes both UPS are on the same machine.
I moved away from Ubuntu and tried with Kali and got a slightly different issue as the driver even doesn’t start properly.
I used the standard apt-get command to download nut and added libusb-dev which wasn’t by default on kali.
I went to Kali nut web page and downloaded all packages 😊
hiddev0 and hiddev1 have been created in /dev/usb and changed the group to nut as they’ve been created with root group.
I have attached the lsusb traces for the 2 UPS
When starting the driver I got this message
$ sudo upsdrvctl start
Network UPS Tools - UPS driver controller 2.8.0
Network UPS Tools - Generic HID driver 0.47 (2.8.0)
USB communication driver (libusb 1.0) 0.43
interrupt pipe disabled (add 'pollonly' flag to 'ups.conf' to get rid of this message)
libusb1: Could not open any HID devices: insufficient permissions on everything
No matching HID UPS found
Driver failed to start (exit status=1)
Thanks for your help and guidance.
Laurent
De : Jim Klimov <jimklimov+nut at gmail.com>
Date : lundi 20 février 2023 à 13:43
À : nut-upsuser Mailing List <nut-upsuser at lists.alioth.debian.org>
Cc : "laurenttaieb at free.fr" <laurenttaieb at free.fr>
Objet : Re: [Nut-upsuser] Issue with two UPS APC managed from a single PC.
Is that with both UPSes on same machine?
A quick guess would be that insufficient data points to identify the device are configured (vendorid, productid, serial...) in ups.conf, so both drivers connect to the first match. I'd expect them to conflict and one would die or both loop reconnecting, if both are running at once, though.
Also, which NUT version? Custom build from GitHub or an (older?) distro package?
Jim
On Mon, Feb 20, 2023, 12:28 Manuel Wolfshant via Nut-upsuser <nut-upsuser at alioth-lists.debian.net> wrote:
On February 20, 2023 12:01:46 PM GMT+02:00, Laurent Taieb via Nut-upsuser <nut-upsuser at alioth-lists.debian.net> wrote:
>Hi mailing list,
>I looked at all FAQ and docs and can’t find a solution.
>I installed but on both Kali Linux and Ubuntu.
>(For comparison purposes)
>I’m trying to connect and monitor two UPS APC via usb.
>One is a back-ups bx1400 which I can see via via upsc.
>The second one is a more recent one smc 1500ic which when I poke it via upsc returns the data of the bx1400 one.
>I tried by changing port and other tricks but no success.
>Would anyone have a clue of what the issue could be ?
Hello
Can you please share the configuration you have used, as well as the output of lsusb ?
wolfy
>Thanks
>
>Laurent
>_______________________________________________
>Nut-upsuser mailing list
>Nut-upsuser at alioth-lists.debian.net
>https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
_______________________________________________
Nut-upsuser mailing list
Nut-upsuser at alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
_______________________________________________ Nut-upsuser mailing list Nut-upsuser at alioth-lists.debian.net https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20230224/80d575b0/attachment-0001.htm>
More information about the Nut-upsuser
mailing list