networkupstools / nut

The Network UPS Tools repository. UPS management protocol Informational RFC 9271 published by IETF at https://www.rfc-editor.org/info/rfc9271 Please star NUT on GitHub, this helps with sponsorships!
https://networkupstools.org/
Other
1.73k stars 335 forks source link

Cyberpower PR2200LCDSL: frequent usbfs errors #2469

Open eamathw opened 3 weeks ago

eamathw commented 3 weeks ago

We have a new server that is connected to two Cyberpower PR2200LCDSL UPSs for monitoring only.

Ubuntu 22.04 NUT version 2.7.4-14ubuntu2

The server logs a lot of usbfs errors like this for both UPSs:

Jun 11 11:08:14 login kernel: [682799.473179] usb 1-4: usbfs: USBDEVFS_CONTROL failed cmd usbhid-ups rqt 161 rq 1 len 2 ret -71
Jun 11 11:09:14 login kernel: [682859.321923] usb 1-2: usbfs: USBDEVFS_CONTROL failed cmd usbhid-ups rqt 161 rq 1 len 3 ret -71

usbhid-ups with debugging enabled reports:

3300.281817 Can't retrieve Report 0a: Protocol error
3300.282717 Can't retrieve Report 0f: Protocol error

nut-scanner finds the UPSs and prints:

[nutdev1]
    driver = "usbhid-ups"
    port = "auto"
    vendorid = "0764"
    productid = "0601"
    product = "PR2200LCDSL"
    serial = "PXRHX2000XXX"
    vendor = "CPS"
    bus = "001"
[nutdev2]
    driver = "usbhid-ups"
    port = "auto"
    vendorid = "0764"
    productid = "0601"
    product = "PR2200LCDSL"
    serial = "PXRHX2000YYY"
    vendor = "CPS"
    bus = "001"

Current ups.conf:

maxretry = 5
pollinterval=60

[upsr5n1]
    desc="upsr5n1"
    driver = "usbhid-ups"
    port = "auto"
    serial = "PXRHX2000XXX"
    vendor = "CPS"

[upsr5n2]
    desc="upsr5n2"
    driver = "usbhid-ups"
    port = "auto"
    serial = "PXRHX2000YYY"

I've tried various values for pollinterval and pollfreq. Increasing them to 120 and 60 respectively slows the rate of error logging but does not stop it. I even tried pollonly to no effect.

I tried having only one UPS enabled. No change.

jimklimov commented 3 weeks ago

Would this help?

Notably, with CPS you may need shorter polling cycles, probably to prevent their chip from going to sleep mode.