[Nut-upsuser] script to check configuration
roger at rogerprice.org
Thu Apr 4 08:34:11 BST 2019
On Wed, 3 Apr 2019, James wrote:
> Is there a script to check that the automatic shutdown and logging
> configuration is set right?
Not that I know of. Since the sysadmin is free to configure as he or she sees
fit it would be a huge job to check every possible situation.
> I had hoped I set it up right to at least log when it goes and off
> battery but I guess I missed something.
> /etc/nut# grep upssched /var/log/syslog
> Apr 3 12:31:06 gw upssched: Timer daemon started
> Apr 3 12:31:06 gw upssched: New timer: onbatt (30 seconds)
> Apr 3 12:31:36 gw upssched: Event: onbatt
> Apr 3 12:31:36 gw upssched-cmd: Unrecognized command: onbatt
> Apr 3 12:31:51 gw upssched: Timer queue empty, exiting
> Apr 3 16:03:55 gw upssched-cmd: Unrecognized command:
I find that very detailed logging from upssched-cmd together with command line
calls of the upssched-cmd script help to debug that script.
In your case, the « Apr 3 12:31:36 gw upssched-cmd: Unrecognized command:
onbatt » is a good starting point.
More information about the Nut-upsuser