El 15/07/15 a les 15:19, Charles Lepple ha escrit:> On Jul 15, 2015, at 8:46 AM, dmanye <dmanye at urv.cat> wrote:
>
>> El 15/07/15 a les 14:18, Charles Lepple ha escrit:
>>> On Jul 15, 2015, at 7:17 AM, dmanye <dmanye at urv.cat>
wrote:
>>>
>>>> i have a computer (with debian 8 jessie installed) that i want
to plug to an ups (apc smt 750i) to act in netserver mode. i've installed
nut packages and configured it and all seems to work ok except that when the
server shutdown itself it ups doesn't "reboot" the outlets.
>>> What is the exact NUT package version
>> 2.4.2-4
> 2.7.2-4? (Sorry to sound pedantic, just trying to get the right version in
the list archives.) I was concerned that there was an older package sticking
around, but that is of course less likely with a new install.
oops, yes, 2.7.2-4.
>
>>> , and which driver are you using?
>> usbhid-ups
>>> Also, is this a new Debian installation, or was it upgraded from
wheezy?
>> new install
>>> (If I understand correctly - I haven't upgraded yet - this
determines which init system is used to control the shutdown.)
>> yes, debian 8 by default installs systemd but i've switched back to
sysvinit (2.88dsf-59) on both computers. in fact, libsystemd0 remains installed
because essential packages depend on it.
> libsystemd0 shouldn't matter - I just wanted to make sure I was looking
at the correct init scripts. Here's nut-server.init corresponding to
2.7.2-4:
>
>
http://anonscm.debian.org/cgit/collab-maint/nut.git/tree/debian/nut-server.init?id=564becd819124049542e5085a7159dd62e00ef97#n151
>
> It does "/sbin/upsdrvctl shutdown", which runs
"/lib/nut/usbhid-ups -a <name-of-ups> -k" to kill power:
>
>
http://anonscm.debian.org/cgit/collab-maint/nut.git/tree/drivers/upsdrvctl.c?id=564becd819124049542e5085a7159dd62e00ef97#n337
>
> In the output of "upsc" for your UPS, is
"ups.start.auto" turned on?
ups.start.auto does not appear neither on the computer that makes the
ups reboot nor in the other.> Do the values for "ups.delay.shutdown" and
"ups.delay.start" (times in seconds) look reasonable?
ups.delay.shutdown is set to 20 on both computers, and ups.delay.start
is missing in both outputs.
i'd like to note that i have not used upsrw at all to modify any variable.
>
> What you can do is run "/lib/nut/usbhid-ups -a <name-of-ups> -k
-DDD" (as root) with the computer powered from another UPS or outlet. That
will show any debug messages as the driver tries to shut down the UPS. (The
driver tries "shutdown.return" before "shutdown.stayoff".)
You may want to add "2>&1 | tee /tmp/ups-shutdown.log" to the
command line, then gzip and attach that log to your reply to keep the message
size small.
>
surprisingly, now both computers made the ups reboot !?!?!?!? so i've
tried once more and confirmed that while forcing the reboot works, the
computer itself does not reboot the ups when the battery is too low.
i attach you four files:
upsc-no-reboot.gz upsc output from the computer that makes NOT the ups
reboot
upsc-reboot.gz upsc output from the computer that makes the ups
reboot
ups-shutdown.log-no-reboot.gz usbhid-ups -k output from the computer
that makes NOT the ups reboot
ups-shutdown.log-reboot.gz usbhid-ups -k output from the
computer that makes the ups reboot
charles, many thanks for your time.
david.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ups-shutdown.log-reboot.gz
Type: application/gzip
Size: 3694 bytes
Desc: not available
URL:
<http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150716/0b6fb0e0/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ups-shutdown.log-no-reboot.gz
Type: application/gzip
Size: 3615 bytes
Desc: not available
URL:
<http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150716/0b6fb0e0/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: upsc-reboot.gz
Type: application/gzip
Size: 406 bytes
Desc: not available
URL:
<http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150716/0b6fb0e0/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: upsc-no-reboot.gz
Type: application/gzip
Size: 410 bytes
Desc: not available
URL:
<http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150716/0b6fb0e0/attachment-0003.bin>