ALT Linux Bugzilla
– Attachment 874 Details for
Bug 6514
/etc/init.d/halt: umount /proc/bus/usb выполняется до передачи UPS команды на отключение.
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
инитскрипт
apcupsd-killpowercheck.init (text/plain), 1.31 KB, created by
Sergey Y. Afonin
on 2005-05-13 17:25:33 MSD
(
hide
)
Description:
инитскрипт
Filename:
MIME Type:
Creator:
Sergey Y. Afonin
Created:
2005-05-13 17:25:33 MSD
Size:
1.31 KB
patch
obsolete
>#!/bin/sh ># ># killpowercheck No service. ># ># chkconfig: 2345 00 00 ># description: this script check for UPS with delayed shutdown \ ># and send killpower to it if UPS exist \ ># processname: none ># config: none ># pidfile: none > ># Do not load RH compatibility interface. >WITHOUT_RC_COMPAT=1 > ># Source function library. >. /etc/init.d/functions > >RETVAL=0 > >start() >{ > rm -f /etc/powerkilled > return 0 >} > >stop() >{ > upscheck > RET=$? > > [ $RET -ne 0 ] || return 100 > > if [ $[ $RET < 180 ] == 1 ]; then > echo "UPS shutdown time too low ($RET sec). Please set 180 sec or more" > return 101 > fi > > UPSCTL=/etc/apcupsd/apccontrol > if [ -x "$UPSCTL" -a -f /etc/apcupsd/powerfail ]; then > action "Attempting to turn the UPS off:" "$UPSCTL" killpower > RETVAL=$? > [ $RETVAL -ne 0 ] || echo "UPS will be shutdown after $RET sec" > touch /etc/powerkilled > # ÉÌÉ ÄÒÕÇÏÅ ÍÅÓÔÏ root file system > fi > > UPSCTL=/sbin/upsdrvctl > if [ -x "$UPSCTL" -a -f /etc/killpower ]; then > action "Attempting to turn the UPS off:" "$UPSCTL" shutdown > RETVAL=$? > [ $RETVAL -ne 0 ] || echo "UPS will be shutdown after $RET sec" > touch /etc/powerkilled > fi > > return $RETVAL >} > ># See how we were called. >case "$1" in > start) > start > ;; > stop) > stop > ;; > *) > msg_usage "${0##*/} {start|stop}" > RETVAL=1 >esac > >exit $RETVAL
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 6514
: 874 |
875