%post
-RUNLEVEL=`/sbin/runlevel`
-
if [ "$1" -ge 1 ]; then
chkconfig --add pl_mom
chkconfig --level 3 pl_mom on
- if [[ "$RUNLEVEL" != "unknown" ]]; then
+ if [[ "$PL_BOOTCD" != "1" ]]; then
/etc/init.d/pl_mom stop
/etc/init.d/pl_mom start
fi
fi
%preun
-RUNLEVEL=`/sbin/runlevel`
-
if [ "$1" -eq 0 ]; then
- if [[ "$RUNLEVEL" != "unknown" ]]; then
+ if [[ "$PL_BOOTCD" != "1" ]]; then
/etc/init.d/pl_mom stop
fi
+
+ chkconfig --del pl_mom
+ chkconfig pl_mom off
fi