[CentOS] Re: UPS support on CentOS 4.4

Fri Dec 29 18:00:38 UTC 2006
Aleksandar Milivojevic <alex at milivojevic.org>

Quoting Edward Diener <eldiener at tropicsoft.com>:

> I am considering writing a program for myself also, since I am a
> programmer. But if something already exists which works well, I will
> use that.

Looking at the apcupsd config files, you probably want to enable ANNOY  
stuff in /etc/apcupsd/apcupsd.conf, and than create onbattery (power  
lost, running on battery) and annoyme (I'm gonna shut down soon)  
scripts in /etc/apcupsd that will display popup windows.  Default  
action from apccontrol file will be also executed after your script  
unless you exit from the script with exit code 99.  See  
/etc/apcupsd/apccontrol for details.  You probably want to background  
the process that opens popup window so that your scripts exit right  
away (instead of waiting for user to close popup).