[Nut-upsuser] Best practice to shutdown hosts which has not NUT via upssched

Dmitri Stepanov dstep at mail.ru
Fri Jul 15 08:22:38 UTC 2016


 Thank you for idea Kris. I guess I know now why my scripts doesn't work from upssched... That's because it's running as another user (_ups in my NUT-master OpenBSD box). And I tested it by hand as root. Unfortunately now I haven't ability to connect to and check my theory by practice on the system.


>Пятница, 15 июля 2016, 1:54 +03:00 от Kris Jordan <nut01.kj at sagebrushnetworks.com>:
>
>Dmitri Stepanov wrote on 7/14/2016 5:18 AM:
>> All the hosts are installed together in one rack and have fed from one 
>> UPS (only I am remote from the system :) and I haven't ability to 
>> connect to it. Some of hosts haven't NUT for a number of reasons. I 
>> don't need to inform not-NUT hosts about any UPS events, heartbeat, 
>> etc... but only shutdown all the hosts after upssched timer expired. 
>> Because script shutdown-all-hosts.sh works fine (there is no ssh 
>> problem) if it's been run by hand but don't work from CMDSCRIPT - I 
>> thought that I miss something "at the NUT side".
>
>I do something similar, I don't want inbound connections (DMZ --> LAN), 
>so I use SSH.
>
>SSH environment difference (e.g. SSH agent forwarding)? That could 
>explain why it works manually, but not when unattended (upssched).
>
>I specifically set SSH_AUTH_SOCK="" in my shutdown script so it won't 
>affect my testing when running the script by hand. I use ssh -i 
><password-less identity file> for each host to shut down.
>
>_______________________________________________
>Nut-upsuser mailing list
>Nut-upsuser at lists.alioth.debian.org
>http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/nut-upsuser

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


More information about the Nut-upsuser mailing list