Stephen Walker-Weinshenker
2020-Jun-21  21:07 UTC
[Nut-upsuser] USBHID-UPS not detecting USB UPS even though options match
Hello:
I have a Cyberpower OL1500RTXL2U ups connected to a raspberry pi running
void linux via USB.
After configuring the UPS and attempting to start the usbhid-ups driver, it
fails to detect it, even when running with the -u root option. Based on the
debug logs, it checks the correct USB device but doesn't detect it for some
reason.
Below are terminal extracts of nut-scanner and attempting to start the
usbhid-ups driver manually, as well as version numbers and OS info.
Also below are my config files with passwords and serial numbers censored.
Thank you for any assistance you can provide.
If you need any more information, I will attempt to provide it.
[toxicsauce at rack-monitor ~]$ upsd -V
Network UPS Tools upsd 2.7.4
[toxicsauce at rack-monitor ~]$
[toxicsauce at rack-monitor ~]$ uname -a
Linux rack-monitor 4.19.120_1 #1 SMP Mon May 11 19:27:08 UTC 2020 armv7l
GNU/Linux
[toxicsauce at rack-monitor ~]$
Statepath is /run/ups:
   0 drwxrwx---  2 nut  nut    40 Dec 31 17:16 ups
[toxicsauce at rack-monitor run]$ ls -lash /etc/ups/
total 52K
4.0K drwxr-xr-x  2 root root 4.0K May 17  2020 .
4.0K drwxr-xr-x 31 root root 4.0K May 17  2020 ..
4.0K -rw-r-----  1 root nut  1.6K May 17  2020 nut.conf
8.0K -rw-r-----  1 root nut  4.8K Dec 31 17:11 ups.conf
8.0K -rw-r-----  1 root nut  4.5K Jun 18  2020 upsd.conf
4.0K -rw-r-----  1 root nut  2.3K Jun 18  2020 upsd.users
 16K -rw-r-----  1 root nut   15K Jun 13  2019 upsmon.conf
4.0K -rw-r-----  1 root nut  3.8K Jun 13  2019 upssched.conf
[toxicsauce at rack-monitor run]$ sudo nut-scanner
Password:
AVAHI client library not found. AVAHI search disabled.
Scanning USB bus.
No start IP, skipping SNMP
Scanning XML/HTTP bus.
No start IP, skipping NUT bus (old connect method)
[nutdev1]
        driver = "usbhid-ups"
        port = "auto"
        vendorid = "0764"
        productid = "0601"
        product = "OL1500RTXL2U"
        serial = "XXXXXXXXXXXX"
        vendor = "CyberPower Systems"
        bus = "001"
[toxicsauce at rack-monitor run]$ sudo /var/lib/nut/usbhid-ups -a cyberpower
-DDDDDDDDDDDD -u root
Password:
Network UPS Tools - Generic HID driver 0.41 (2.7.4)
USB communication driver 0.33
   0.000000     debug level is '12'
   0.000597     upsdrv_initups...
   0.012367     Checking device (0764/0601) (001/004)
   0.038119     - VendorID: 0764
   0.038191     - ProductID: 0601
   0.038249     - Manufacturer: CyberPower Systems
   0.038308     - Product: OL1500RTXL2U
   0.038365     - Serial Number: XXXXXXXXXXX
   0.038423     - Bus: 001
   0.038480     - Device release number: 0200
   0.038534     Trying to match device
   0.038687     Device does not match - skipping
   0.038810     Checking device (0424/EC00) (001/003)
   0.038971     - VendorID: 0424
   0.039031     - ProductID: ec00
   0.039074     - Manufacturer: unknown
   0.039115     - Product: unknown
   0.039160     - Serial Number: unknown
   0.039202     - Bus: 001
   0.039243     - Device release number: 0200
   0.039286     Trying to match device
   0.039338     Device does not match - skipping
   0.039418     Checking device (0424/9514) (001/002)
   0.039534     - VendorID: 0424
   0.039582     - ProductID: 9514
   0.039624     - Manufacturer: unknown
   0.039666     - Product: unknown
   0.039708     - Serial Number: unknown
   0.039753     - Bus: 001
   0.039799     - Device release number: 0200
   0.039842     Trying to match device
   0.039895     Device does not match - skipping
   0.039979     Checking device (1D6B/0002) (001/001)
   0.040917     - VendorID: 1d6b
   0.040977     - ProductID: 0002
   0.041044     - Manufacturer: Linux 4.19.120_1 dwc_otg_hcd
   0.041094     - Product: DWC OTG Controller
   0.041141     - Serial Number: XXXXXXXX
   0.041182     - Bus: 001
   0.041223     - Device release number: 0419
   0.041264     Trying to match device
   0.041312     Device does not match - skipping
   0.041396     No appropriate HID device found
   0.041447     No matching HID UPS found
[toxicsauce at rack-monitor ups]$sudo cat nut.conf
Password:
MODE=netserver
[toxicsauce at rack-monitor ups]$ sudo cat ups.conf
Password:
# Network UPS Tools: example ups.conf
[cyberpower]
        driver=usbhid-ups
        port=auto
        vendorid="0764"
        productid="0601"
        product="OL1500RTXL2U"
        serial="XXXXXXXXX"
        vendor="Cyber Power Systems"
        bus="001"
        desc="Main 1500VA ups"
        pollinterval=15
[toxicsauce at rack-monitor ups]$ sudo less upsd.conf
Password:
# Network UPS Tools: example upsd configuration file
#
# This file contains access control data, you should keep it secure.
#
# It should only be readable by the user that upsd becomes.  See the FAQ.
#
# Each entry below provides usage and default value.
# ======================================================================# MAXAGE
<seconds>
# MAXAGE 15
#
# This defaults to 15 seconds.  After a UPS driver has stopped updating
# the data for this many seconds, upsd marks it stale and stops making
# that information available to clients.  After all, the only thing worse
# than no data is bad data.
#
# You should only use this if your driver has difficulties keeping
# the data fresh within the normal 15 second interval.  Watch the syslog
# for notifications from upsd about staleness.
# ======================================================================#
STATEPATH <path>
# STATEPATH /var/run/nut
#
# Tell upsd to look for the driver state sockets in 'path' rather
# than the default that was compiled into the program.
# ======================================================================# LISTEN
<address> [<port>]
LISTEN 127.0.0.1 3493
LISTEN ::1 3493
LISTEN 10.0.1.12 3493
all other config files are default, as I was testing things first before
configuring the autoshutdown scripts.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20200621/a85780ec/attachment-0001.html>
Charles Lepple
2020-Jun-22  12:02 UTC
[Nut-upsuser] USBHID-UPS not detecting USB UPS even though options match
> On Jun 21, 2020, at 5:34 PM, Stephen Walker-Weinshenker wrote: > > product = "OL1500RTXL2U" > serial = "XXXXXXXXXXXX" > vendor = "CyberPower Systems" > bus = "001"Generally we only recommend including these extra parameters if there are multiple UPSes on one host, and you need to distinguish between them. Is it possible that there are extra spaces around some of the strings (that aren’t shown by nut-scanner)? Quick fix would be to remove all of the options I quoted, but I would be curious as to which one is causing the problem. If it does turn out to be some weird characters, and you need to add another UPS later, it should be possible to use regular expressions to match the well-formed parts of the strings.
Stephen Walker-Weinshenker
2020-Jun-22  22:23 UTC
[Nut-upsuser] USBHID-UPS not detecting USB UPS even though options match
Hello: It turned out that it didn't like the Vendor line. Bus, Serial and Product all worked in ups.conf. Thanks for all the help. It is working now. On Mon, Jun 22, 2020 at 6:02 AM Charles Lepple <clepple at gmail.com> wrote:> > On Jun 21, 2020, at 5:34 PM, Stephen Walker-Weinshenker wrote: > > > > product = "OL1500RTXL2U" > > serial = "XXXXXXXXXXXX" > > vendor = "CyberPower Systems" > > bus = "001" > > Generally we only recommend including these extra parameters if there are > multiple UPSes on one host, and you need to distinguish between them. Is it > possible that there are extra spaces around some of the strings (that > aren’t shown by nut-scanner)? > > Quick fix would be to remove all of the options I quoted, but I would be > curious as to which one is causing the problem. > > If it does turn out to be some weird characters, and you need to add > another UPS later, it should be possible to use regular expressions to > match the well-formed parts of the strings.-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20200622/dd39f83c/attachment-0001.html>
Maybe Matching Threads
- USBHID-UPS not detecting USB UPS even though options match
- Keep on losing communication: Raspberry Pi, CyberPower PR1500LCD
- [HCL] CyberPower Systems PR6000LCDRTXL5U supported by usbhid-ups
- Cyberpower OR500 on usbhid-ups
- [HCL] CyberPower OR700 supported by usbhid-ups