[Nut-upsuser] still no nut at reboot

Charles Lepple clepple at gmail.com
Mon Nov 15 02:52:17 UTC 2010

On Nov 14, 2010, at 8:36 PM, Gene Heskett wrote:

> ok, back after the reboot to get everything on the same page again,  
> or so I
> thought.  Silly me.
> now, I have a ups.conf containing this:
> [root at coyote etc]# cat ups.conf
> [coyotes-ups]
>                driver = usbhid-ups
>                port = auto
>                desc = "Belkin ups usb interface"

Looks good.

> So, first checking to see if the /etc/init.d/upsd script left  
> anything I
> needed to kill behind, but it didn't, then check the perms on the / 
> dev/hid*
> stuffs and find:
> [root at coyote etc]# ls -l /dev/hid*
> crw------- 1 root root 250, 0 2010-11-14 20:00 /dev/hidraw0
> crw------- 1 root root 250, 1 2010-11-14 20:00 /dev/hidraw1

These don't matter for NUT.

> So I am at step 8 of the INSTALL printout.
> ------------------------------------------------------
> [root at coyote ~]# /usr/local/ups/bin/upsdrvctl start
> Network UPS Tools - UPS driver controller 2.4.3-2672M
> Network UPS Tools - Generic HID driver 0.35 (2.4.3-2672M)
> USB communication driver 0.31
> Using subdriver: Belkin HID 0.12
> Fatal error: unable to create listener socket
> bind /var/state/ups/usbhid-ups-coyotes-ups failed: Permission denied

The upsdrvctl program will drop privileges to the user name that you  
specified when running ./configure. You can temporarily bypass this by  
adding "-u root" to the command line, but afterwards, you will want to  
check step 5 (a "chmod" on the state path, a.k.a. listener socket  

> Exiting.
> Driver failed to start (exit status=1)
> -------then--------
> [root at coyote ~]# lsusb |grep elkin
> Bus 002 Device 008: ID 050d:0751 Belkin Components

This corresponds to either /proc/bus/usb/002/008 or /dev/usb/002/008.  
*That* is the USB node which the udev rules should be changing the  
permissions on.

> So lets stop right here and fix this.  First:
> [root at coyote etc]# grep ups /etc/passwd
> ups:x:502:504::/home/ups:/bin/bash
> There is no 'nut' in /etc/passwd now.
> and:
> [root at coyote etc]# grep nut /etc/group
> nut:x:503:ups
> The whole thing has been rebuilt and reinstalled, but the .conf  
> and .user
> files are still there.
> And I see the hacked mdv script to start it doesn't have a link in
> /etc/rc5.d, so it did not attempt to run at bootup.
> Whats next coach?  I'm going blind staring at this, and probably  
> missing
> something obvious, like hacking on the 52-* udev script some more to  
> change
> some perms?  FWIW, changing all the 'ATTR' to 'ATTRS' shut it up
> completely.  This was udev complaining about a deprecated format.   
> Other
> than the spelling, I didn't change anything else.

Sigh. Good to know that we will need to update that at some point. (I  
wonder how many older udev installations we will break if we change  
that now? Guess we could ship two copies.)

What does "udevadm --version" say? (My second attempt at the pclos VM  
is still booting - I gave it more RAM this time, but it's still making  
molasses look like a speed demon.)

More information about the Nut-upsuser mailing list