[Nut-upsuser] Data Stale at random intervals

Daniel Shields grungelizard9 at hotmail.com
Fri Oct 28 15:38:54 UTC 2016


Hi Charles,


     I've been monitoring for the past few days and NUT has been running solid.  Tested and everything's working as it should.  Thanks for all of your help on this, great to have it running well again and learned lot.


________________________________
From: Daniel Shields <grungelizard9 at hotmail.com>
Sent: Tuesday, October 25, 2016 8:01 PM
To: Charles Lepple
Subject: Re: [Nut-upsuser] Data Stale at random intervals


Hi Charles,


     Pardon my ignorance [😊]  I figured it out.  Didn't realize the \ was a separator.  It's installed so I'll see how it goes.  Thanks!


________________________________
From: Daniel Shields <grungelizard9 at hotmail.com>
Sent: Tuesday, October 25, 2016 7:42 PM
To: Charles Lepple
Subject: Re: [Nut-upsuser] Data Stale at random intervals


Hi Charles,

     I'm working on the build, however, I'm getting an error for the "--infodir" variable.  I checked and that directory exists.  Not sure if I should try dropping it or what I'd need to change it to for it to work.  I'll keep Googling but figured I'd reach out as well.  Thanks!

nano /etc/apt/sources.list.d/security.sources.list
  deb-src http://security.debian.org/ jessie/updates main contrib non-free

nano /etc/apt/sources.list.d/sources.list
  deb-src http://http.debian.net/debian jessie main contrib non-free
  deb-src http://http.debian.net/debian jessie-updates main contrib non-free

apt-get update

apt-get build-dep nut

apt-get install libusb-1.0-0-dev

cd

wget http://buildbot.networkupstools.org/~buildbot/docker-debian-jessie/snapshot/libusb-1.0/nut-latest.tar.gz

cp nut-latest.tar.gz /usr/src

cd /usr/src

tar xvfz nut-latest.tar.gz

cd nut-v2.7.4-99-gdb20c07

./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

configure: error: invalid variable name: ` --infodir'



________________________________
From: Charles Lepple <clepple at gmail.com>
Sent: Monday, October 24, 2016 11:52 PM
To: Daniel Shields
Cc: nut-upsuser at lists. alioth. debian. org
Subject: Re: [Nut-upsuser] Data Stale at random intervals

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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20161028/6d2acad6/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OutlookEmoji-?.png
Type: image/png
Size: 488 bytes
Desc: OutlookEmoji-?.png
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20161028/6d2acad6/attachment-0001.png>


More information about the Nut-upsuser mailing list