[Nut-upsuser] NUT - Driver looks well, but connection from from client is lost or unavailable

Charles Lepple clepple at gmail.com
Tue Dec 23 22:58:12 UTC 2014

>> I setup apcsmart driver on port /dev/ttyUSB0 in ups.conf and check that runing user=root.
> user=root is only for testing- this may cause other permissions problems later. 

It looks like the simplest way to handle this on Debian is to add the system 'nut' user to the 'dialout' group:

$ sudo adduser nut dialout

> I have been meaning to collect some information on using serial UPSes with NUT via USB-to-serial converters, but you can adapt the udev rules to match your converter, and even create a symlink so that it will not change names. (If a process has /dev/ttyUSB0 open, and the USB cable is unplugged, udev will create /dev/ttyUSB1 when it is next plugged in, which will not match the configuration file)

Just confirmed that the default udev rules for Raspbian wheezy will create some symlinks in /dev/serial/by-path and /dev/serial/by-id which should be useful.

I have an inexpensive USB-to-serial cable which does not have a unique serial number, so I can only use one of that model at a time, and still uniquely identify it. But this is what it produces:

$ ls -l /dev/serial/by-id/
total 0
lrwxrwxrwx 1 root root 13 Dec 31  1969 usb-Prolific_Technology_Inc._USB-Serial_Controller-if00-port0 -> ../../ttyUSB0

Although it is unwieldy, the pathnames under /dev/serial/by-id should always point to the correct /dev/ttyUSB? node.

Charles Lepple
clepple at gmail

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20141223/c1846b79/attachment.html>

More information about the Nut-upsuser mailing list