[Nut-upsuser] right problem with ups belkin (model who work with

Peter Selinger selinger at mathstat.dal.ca
Wed Dec 27 06:29:38 CET 2006


Hi Marc,

the answer to your question is contained in the file INSTALL,
distributed with NUT, section 6 "Set ownership data and permissions on
your serial or USB ports that go to your UPS hardware."

Quote:

    "The setup for USB ports is slightly more complicated. Device
    files for USB devices, such as /proc/bus/usb/002/001, are usually
    created "on the fly" when a device is plugged in, and disappear
    when the device is disconnected.  Moreover, the names of these
    device files can change randomly. To set up the correct
    permissions for the USB device, you may need to set up (operating
    system dependent) hotplugging scripts.  Sample scripts and
    information are provided in the scripts/hotplug and
    scripts/hotplug-ng directories. (If you want to try if a driver
    works without setting up hotplugging, you can add the "-u root"
    option to upsd, upsmon, and drivers; this should allow you to
    follow the below instructions. However, don't forget to set up the
    correct permissions later!)."

Note that /dev/hiddev0 is not mentioned anywhere in these instructions
- for good reason, because NUT does not use this device to access the
USB port.

Since you are apparently on Linux, you may also find the instructions
at http://www.mathstat.dal.ca/~selinger/ups/backups.html helpful; they
are for an APC but should work analogously for Belkin. 

-- Peter

Marc Collin wrote:
> 
> hi 
> 
> i have a belkin ups
> here some setting
> 
> chmod 0600 /dev/hiddev0
> chown nut:root /dev/hiddev0
> 
> linux:/home/sonia # /usr/lib/ups/driver/upsdrvctl start
> Network UPS Tools - UPS driver controller 2.0.4
> Network UPS Tools: New USB/HID UPS driver 0.28 (2.0.4)
> 
> No matching USB/HID UPS found
> Driver failed to start (exit status=1)
> 
> 
> 
> 
> linux:/home/sonia # /usr/lib/ups/driver/upsdrvctl -u root start
> Network UPS Tools - UPS driver controller 2.0.4
> Network UPS Tools: New USB/HID UPS driver 0.28 (2.0.4)
> 
> Detected a UPS: Belkin /Belkin UPS
> Using subdriver: Belkin HID 0.1
> 
> 
> 
> linux:/home/sonia # /usr/sbin/upsd
> Network UPS Tools upsd 2.0.4
> Can't open /etc/ups/upsd.conf: Permission denied
> linux:/home/sonia # /usr/sbin/upsd -u root
> Network UPS Tools upsd 2.0.4
> 
> 
> linux:/home/sonia # /usr/sbin/upsd -u root
> Network UPS Tools upsd 2.0.4
> Connected to UPS [myups]: newhidups-hiddev0
> Synchronizing...done
> linux:/home/sonia #
> 
> 
> /etc/ups/hosts.conf
> MONITOR myups at localhost "Local UPS"
> 
> [myups]
>         driver = newhidups
>         port = /dev/hiddev0
>         desc = "Local UPS"
> 
> /etc/ups/upsd.conf
> ACL all 0.0.0.0/0
> ACL localhost 127.0.0.1/32
> 
> ACCEPT localhost
> REJECT all
> 
> 
> 
> 
> /etc/ups/upsd.users
> [monuser]
>         password=mypass
>         allowfrom=localhost
>         upsmon master
> 
> /etc/ups/upsmon.conf
> MONITOR myups at localhost 1 monuser monpass master
> 
> 
> without to use -u with root value
> /usr/lib/ups/driver/upsdrvctl -u root start
> /usr/sbin/upsd -u root
> 
> i can't use nut
> 
> any idea?
> 
> 
> also in /etc/init.d/upsd don't know if it's ok
> # Preconfigured user ID of UPS devices.
> UPSD_USER="nut"
> 
> # Owner of UPS port devices (empty to skip device check):
> UPS_OWNER="$UPSD_USER:root"
> 
> 
> Can't open /etc/ups/upsd.conf: Permission denied
> 
> _______________________________________________
> Nut-upsuser mailing list
> Nut-upsuser at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser
> 




More information about the Nut-upsuser mailing list