[Nut-upsdev] NUT UPS monitor & APC Back UPS CS-350 (nut-2.2.2p1) on OpenBSD

Charles Lepple clepple at gmail.com
Tue Oct 6 23:53:17 UTC 2009


[Let's move this over to the NUT-upsuser list, since we are not  
discussing source code. (The post you quoted was from a time when  
usbhid-ups was still under heavy development.) Thanks!]
Info: http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser

On Oct 6, 2009, at 9:22 AM, Zbigniew wrote:

> Hallo,
>
> Following the tips found at https://calomel.org/nut_ups.html I was  
> trying to
> make NUT operate "APC Back UPS CS-350". The device introduces itself  
> as:
>
> #v+
>  ugen0 at uhub0 port 1 "American Power Conversion Back-UPS CS 350 FW: 
> 807.q7.I
>  USB FW:q7" rev 1.10/0.06 addr 2
> #v-

So far, so good - the kernel sees it as a ugen device (versus uhid),  
which allows libusb to talk to it.

> My config:
>
> #v+
> [apc]
>        driver = usbhid-ups
>        port = /dev/ugen0.00
>        pollfreq = 60
>        desc = "Back UPS CS-350"
> #v-
>
>
> Unfortunately, when I'm trying to start UPS driver, it's complaining:
>
> #v+
>  # usbhid-ups -a apc
>  Network UPS Tools: 0.29 USB communication driver - core 0.33 (2.2.2)
>
>  No matching HID UPS found
> #v-

By default, running a driver as root will drop privileges to whatever  
user you set in the ./configure script (default: nobody).

This post reports success on FreeBSD by adding "-u root" to the  
command line:

http://www.mail-archive.com/nut-upsuser@lists.alioth.debian.org/msg04850.html

Not a good strategy for the long run, but it will let you see if  
things work.

This email talks about using devd on FreeBSD to change permission on  
all of /dev/ugen[0-9]*:

http://lists.alioth.debian.org/pipermail/nut-upsuser/2008-August/004345.html

I don't know if OpenBSD has something similar to devd, but the same  
principles should apply - libusb probably needs permission to the  
base /dev node for scanning the bus.



More information about the Nut-upsdev mailing list