aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--initscripts.spec2
-rwxr-xr-xrc.d/init.d/halt10
2 files changed, 8 insertions, 4 deletions
diff --git a/initscripts.spec b/initscripts.spec
index 19bad442..36abea5f 100644
--- a/initscripts.spec
+++ b/initscripts.spec
@@ -24,6 +24,8 @@ Conflicts: dhclient < 3.0.3-7
Conflicts: tcsh < 6.13-5
Conflicts: xorg-x11, glib2 < 2.11.1-2
Conflicts: alsa-utils < 1.0.14-0.5.rc2.fc7
+# http://bugzilla.redhat.com/show_bug.cgi?id=252973
+Conflicts: nut < 2.2.0
Obsoletes: rhsound sapinit
Obsoletes: hotplug
Prereq: /sbin/chkconfig, /usr/sbin/groupadd, /bin/sed, coreutils
diff --git a/rc.d/init.d/halt b/rc.d/init.d/halt
index 74bcb635..a6d719ef 100755
--- a/rc.d/init.d/halt
+++ b/rc.d/init.d/halt
@@ -204,12 +204,14 @@ elif [ -f /forcefsck ]; then
echo $"On the next boot fsck will be forced."
fi
-if [ "$command" = /sbin/halt -a -r /etc/ups/upsmon.conf -a -f /etc/killpower -a -f /etc/sysconfig/ups ] ; then
+# Shutdown UPS drivers
+if [ "$command" = /sbin/halt -a -f /etc/sysconfig/ups ]; then
. /etc/sysconfig/ups
- if [ "$SERVER" = "yes" -a "$MODEL" = "upsdrvctl" ] ; then
+ if [ -z $POWERDOWNFLAG ]; then
+ POWERDOWNFLAG=/etc/killpower
+ fi
+ if [ "$SERVER" = "yes" -a -f $POWERDOWNFLAG ]; then
/sbin/upsdrvctl shutdown
- elif [ "$SERVER" = "yes" -a "$MODEL" != "NONE" -a -n "$MODEL" -a -n "$DEVICE" ] ; then
- $MODEL $OPTIONS_HALT -k $DEVICE
fi
fi