driver unable to connect to CyberPower UPS using usbhid-ups driver
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
nut (Debian) |
Fix Released
|
Unknown
|
|||
nut (Fedora) |
Fix Released
|
Medium
|
|||
nut (Ubuntu) |
Fix Released
|
High
|
Unassigned | ||
Trusty |
Invalid
|
Undecided
|
Unassigned | ||
Xenial |
Invalid
|
Undecided
|
Unassigned |
Bug Description
[Impact]
* Plugging in a USB controlled UPS solution does fail to execute the udev
rules; Due to that the permissions are not set correctly
* Fix is a backport from upstream which only changes the numbering on the
rule to execute at the right time.
[Test Case]
* Install nut-server
* Plug in a usb controlled UPS of your choice
* The device node created should be mode 664 and group "nut", but it is
not.
* Install the proposed package
* (It also fixes but 1540008, so no need to replug anymore to test if
successful)
* it should now be created with proper permissions.
[Regression Potential]
* If people with the old set up have created something that would not be
able to access anymore that could cuase issues, but before it was
root:root and now nut:root; the group permission didn't change (was 6
before) - so anything before could only access with root and they still
can - therefore I consider this of low/no risk, yet in some obscure
setups it might be one.
[Other Info]
* n/a
---
I hooked my new CyberPower UPS: CP685AVR-G on my Lucid server and got this error:
Jan 15 12:06:33 xeon upsd[5441]: Can't connect to UPS [cyberpower] (usbhid-
Jan 15 12:06:38 xeon upsmon[5445]: Poll UPS [cyberpower@
After trying many things, I found https:/
mv /lib/udev/
Now, everything works well, without requiring "user = root" in /etc/nut/ups.conf because the udev rule now ensures the device file is owned by the group "nut":
# find /dev/bus/usb/ -ls
1536 0 drwxr-xr-x 10 root root 200 Jan 15 12:40 /dev/bus/usb/
1579 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/008
1580 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1573 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/007
1574 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1567 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/006
1568 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1561 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/005
1562 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1555 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/004
1556 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1549 0 drwxr-xr-x 2 root root 80 Jan 15 12:40 /dev/bus/usb/003
2163 0 crw-rw-r-- 1 root nut Jan 15 12:49 /dev/bus/
1550 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1543 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/002
1544 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
1537 0 drwxr-xr-x 2 root root 60 Jan 15 12:40 /dev/bus/usb/001
1538 0 crw-rw-r-- 1 root root Jan 15 12:41 /dev/bus/
Generic information:
# lsb_release -rd
Description: Ubuntu 10.04.4 LTS
Release: 10.04
# apt-cache policy nut
nut:
Installed: 2.4.3-1ubuntu3.2
Candidate: 2.4.3-1ubuntu3.2
Version table:
*** 2.4.3-1ubuntu3.2 0
500 http://
500 http://
100 /var/lib/
2.4.3-1ubuntu3 0
500 http://
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: nut 2.4.3-1ubuntu3.2
ProcVersionSign
Uname: Linux 2.6.32-45-server x86_64
Architecture: amd64
Date: Tue Jan 15 12:43:46 2013
ProcEnviron:
PATH=(custom, no user)
LANG=en_CA.UTF-8
SHELL=/bin/bash
SourcePackage: nut
Changed in nut (Debian): | |
status: | Unknown → New |
Changed in nut (Debian): | |
status: | New → Fix Released |
description: | updated |
Changed in nut (Fedora): | |
importance: | Unknown → Medium |
status: | Unknown → Fix Released |
Description of problem:
I have an MGE Ellipse Pulsar 500 UPS (USB ID 0463:ffff), connected via USB, and since upgrading to F10 from F8, usbhid-ups will not start.
Version-Release number of selected component (if applicable): 2.2.2-4. fc10.x86_ 64 2-4.fc10. x86_64 15-170. 2.24.fc10. x86_64
[root@detritus ~]# rpm -qa | grep ^nut
nut-client-
nut-2.2.
[root@detritus ~]# uname -r
2.6.27.
How reproducible: Every time
Steps to Reproduce:
1. Configure a UPS with driver = usbhid-ups
2. Attempt to start ups service
Actual results:
[root@detritus ~]# service ups start
Starting UPS driver controller: [FAILED]
Starting upsd: [ OK ]
Starting UPS monitor (master): [ OK ]
Expected results:
Service should start successfully
Additional info:
[root@detritus ~]# lsusb -d 0463:ffff
Bus 003 Device 002: ID 0463:ffff MGE UPS Systems UPS
[root@detritus ~]# usbhid-ups -DDDDD -a mge -x vendorid=0463 -x productid=ffff
Network UPS Tools: 0.29 USB communication driver - core 0.33 (2.2.2)
debug level is '5'
upsdrv_initups...
[snipped checking other USB devices here]
Checking device (0463/FFFF) (003/002)
- VendorID: 0463
- ProductID: ffff
- Manufacturer: unknown
- Product: unknown
- Serial Number: unknown
- Bus: 003
Trying to match device
Device matches
failed to claim USB device, trying 2 more time(s)...
detaching kernel driver from USB device...
failed to detach kernel driver from USB device...
trying again to claim USB device...
failed to claim USB device, trying 1 more time(s)...
detaching kernel driver from USB device...
failed to detach kernel driver from USB device...
trying again to claim USB device...
failed to claim USB device, trying 0 more time(s)...
detaching kernel driver from USB device...
failed to detach kernel driver from USB device...
trying again to claim USB device...
Unable to get HID descriptor (error sending control message: Operation not permitted)
i=0, extra[i]=09, extra[i+1]=21
HID descriptor, method 2: (9 bytes) => 09 21 00 01 21 01 22 14 02
HID descriptor length 532
Unable to get Report descriptor: Operation not permitted
[snipped checking other USB devices here]
No appropriate HID device found
No matching HID UPS found
This looks very similar to bug 461374, but that was apparently fixed. The documentation tells me that this is definitely the correct driver to use (I think I could use mge-shut if I used a serial cable instead, but my serial port is in use for something else).