[Nut-upsuser] Data Stale at random intervals
Charles Lepple
clepple at gmail.com
Tue Oct 25 03:52:47 UTC 2016
On Oct 24, 2016, at 9:56 PM, Daniel Shields wrote:
>
> Hi Charles,
>
> Tried it with -p but couldn't get it to run, I'll have to dig further into the man pages. I ran without -p though and got an interesting timeout error. Attached is the log. I'll look further into the -p option as well. Tried sending the full zipped log but it was too big. Attaching the part where the error occurred. It seems like it was able to recover a couple of times, but the last time it got stuck. Thanks!
======================
select(5, NULL, [4], NULL, {0, 1000}) = 0 (Timeout)
ioctl(4, USBDEVFS_REAPURBNDELAY, 0x7ffe72cb0678) = -1 EAGAIN (Resource temporarily unavailable)
select(5, NULL, [4], NULL, {0, 1000}) = 1 (out [4], left {0, 253})
ioctl(4, USBDEVFS_REAPURBNDELAY, 0x7ffe72cb0678) = 0
ioctl(4, USBDEVFS_DISCARDURB, 0x7ffe72cb06b0) = -1 EINVAL (Invalid argument)
ioctl(4, USBDEVFS_REAPURB
======================
I think it's the error from second-to-last ioctl (USBDEVFS_DISCARDURB) which is throwing off libusb-0.1. Earlier in the log, it always gets 0 instead of -1 for the return code, and the USBDEVFS_REAPURB doesn't block.
If you're up for installing the dependencies needed to rebuild with the libusb-1.0 branch, I can walk you through that. The short version is: run "apt-get build-dep nut" (needs the "deb-src" lines uncommented in /etc/apt/sources.list, and another round of "apt-get update"), then install libusb-1.0-0-dev. Here is the link to the latest Git snapshot:
http://buildbot.networkupstools.org/~buildbot/docker-debian-jessie/snapshot/libusb-1.0/nut-latest.tar.gz
The configure line in the Debian build log[1] is pretty epic, but let's try this (assuming amd64 vs i386):
./configure --includedir=/usr/include --mandir=/usr/share/man \
--infodir=/usr/share/info --sysconfdir=/etc/nut --localstatedir=/var \
--libexecdir=/usr/lib/nut --srcdir=. --disable-maintainer-mode \
--disable-dependency-tracking --disable-silent-rules --libdir=/usr/lib/x86_64-linux-gnu \
--with-ssl --with-nss --with-cgi --with-dev --enable-static \
--with-statepath=/var/run/nut --with-altpidpath=/var/run/nut \
--with-drvpath=/lib/nut --with-cgipath=/usr/lib/cgi-bin/nut \
--with-htmlpath=/usr/share/nut/www --with-pidpath=/var/run/nut \
--datadir=/usr/share/nut --with-pkgconfig-dir=/usr/lib/aarch64-linux-gnu/pkgconfig \
--with-user=nut --with-group=nut --with-udev-dir=/lib/udev \
--with-systemdsystemunitdir=/lib/systemd/system
[1] https://buildd.debian.org/status/fetch.php?pkg=nut&arch=i386&ver=2.7.4-4&stamp=1475017236
That should configure things to install over the .deb with a "make install". You can reinstall the .deb to get the original files back.
More information about the Nut-upsuser
mailing list