Imported Upstream version 2.4.3
This commit is contained in:
commit
26fb71b504
446 changed files with 148951 additions and 0 deletions
37
scripts/Solaris8/S99upsmon
Executable file
37
scripts/Solaris8/S99upsmon
Executable file
|
@ -0,0 +1,37 @@
|
|||
#! /bin/sh
|
||||
# Copyright (c) 1995-2000 ???
|
||||
#
|
||||
# Author: Sandro Wefel <wefel@informatik.uni-halle.de>
|
||||
#
|
||||
# Put it in /etc/rc2.d/ or /etc/rc3.d depending on runlevel
|
||||
#
|
||||
|
||||
PATH=/sbin:/bin:/usr/sbin:/usr/bin
|
||||
export PATH
|
||||
|
||||
UPSDPATH=/usr/local/ups/sbin
|
||||
|
||||
# See how we are called.
|
||||
case "$1" in
|
||||
'start')
|
||||
if [ -x $UPSDPATH/upsmon ]; then
|
||||
echo "NUT Starting UPS monitor "
|
||||
$UPSDPATH/upsmon >/dev/console 2>&1
|
||||
touch /var/lock/subsys/upsmon
|
||||
fi
|
||||
;;
|
||||
'stop')
|
||||
echo "NUT Stopping UPS monitor "
|
||||
/usr/bin/pkill -x upsmon
|
||||
rm -f /var/lock/subsys/upsmon
|
||||
;;
|
||||
'restart')
|
||||
$0 stop
|
||||
$0 start
|
||||
;;
|
||||
*)
|
||||
echo "Usage: upsmon {start|stop|restart}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
exit 0
|
Loading…
Add table
Add a link
Reference in a new issue