[Nut-upsuser] USB problems

James bjlockie at lockie.ca
Tue May 11 04:53:42 UTC 2010


  On 05/10/10 23:25, Charles Lepple wrote:
> On Mon, May 10, 2010 at 11:02 PM, James<bjlockie at lockie.ca>  wrote:
>>   On 05/10/10 22:09, Charles Lepple wrote:
>>> On Mon, May 10, 2010 at 8:35 PM, James<bjlockie at lockie.ca>    wrote:
> [...]
>>>>    0.000663     failed to claim USB device: could not claim interface 0:
>>>> Operation not permitted
>>>>    0.000671     failed to detach kernel driver from USB device: could not
>>>> detach kernel driver from interface 0: Operation not permitted
>>> This error is different ("operation not permitted" versus "Device or
>>> resource busy"). Is your source build using a different user than the
>>> Gentoo build? (Some distributions have a specific NUT userid instead
>>> of using "nobody" - not sure how they do it in Gentoo).
>>>
>> I'm compiling it with root but I followed the instructions (I think):
>> ./configure --with-user=ups --with-group=nut
>>
>> What user should perform the #8 step, /usr/local/ups/bin/upsdrvctl start
> You can run upsdrvctl as root, and the driver will change to the user
> you listed above. If you change the parameters to ./configure, you
> will need to run "make clean" before "make all" and/or "make install"
>
> The key is to make sure that the installed udev files match that
> username as well. (At the beginning of this thread, you quoted a udev
> rule which set the USB device node to user "nobody", which probably
> isn't in group "nut".)
>
I changed that.

Is there any way to see what these two devices are?
May the UPS one should be root:nut

$ ls -l /dev/usb
total 0
crw-rw---- 1 root root 180, 96 May 11 00:40 hiddev0
crw-rw---- 1 root root 180, 97 May 11 00:40 hiddev1


PS!
I changed code in drivers/libusb.c
It doesn't fix my problems but I think is nicer code.




More information about the Nut-upsuser mailing list