packages: ibmusbasm/ibmusbasm.init, ibmusbasm/ibmusbasm.spec - ibmasm daemo...
glen
glen at pld-linux.org
Wed Jun 17 05:01:52 CEST 2009
Author: glen Date: Wed Jun 17 03:01:52 2009 GMT
Module: packages Tag: HEAD
---- Log message:
- ibmasm daemon uses /var/lock/subsys/ibmusbasm for internal locking, do not use that
---- Files affected:
packages/ibmusbasm:
ibmusbasm.init (1.5 -> 1.6) , ibmusbasm.spec (1.9 -> 1.10)
---- Diffs:
================================================================
Index: packages/ibmusbasm/ibmusbasm.init
diff -u packages/ibmusbasm/ibmusbasm.init:1.5 packages/ibmusbasm/ibmusbasm.init:1.6
--- packages/ibmusbasm/ibmusbasm.init:1.5 Wed Jun 17 04:55:14 2009
+++ packages/ibmusbasm/ibmusbasm.init Wed Jun 17 05:01:46 2009
@@ -1,6 +1,6 @@
#!/bin/sh
#
-# ibmusbasm This shell script takes care of starting and stopping \
+# ibmasm This shell script takes care of starting and stopping \
# the IBM Remote Supervisor Adapter II daemon.
#
# chkconfig: 2345 85 15
@@ -16,24 +16,27 @@
. /etc/rc.d/init.d/functions
# Get service config - may override defaults
-[ -f /etc/sysconfig/ibmusbasm ] && . /etc/sysconfig/ibmusbasm
+[ -f /etc/sysconfig/ibmasm ] && . /etc/sysconfig/ibmasm
start() {
# Check if the service is already running?
- if [ -f /var/lock/subsys/ibmusbasm ]; then
+ if [ -f /var/lock/subsys/ibmasm ]; then
msg_already_running "IBM Remote Supervisor Adapter"
return
fi
msg_starting "IBM Remote Supervisor Adapter"
# start the daemon in the background
+ # it will take some time to initialize and it will check using
+ # /var/lock/subsys/ibmusbasm lockfile to see if it's not already running,
+ # so don't use that as lockfile for initscript.
daemon --fork /sbin/ibmasm
RETVAL=$?
- [ $RETVAL -eq 0 ] && touch /var/lock/subsys/ibmusbasm
+ [ $RETVAL -eq 0 ] && touch /var/lock/subsys/ibmasm
}
stop() {
- if [ ! -f /var/lock/subsys/ibmusbasm ]; then
+ if [ ! -f /var/lock/subsys/ibmasm ]; then
msg_not_running "IBM Remote Supervisor Adapter"
return
fi
@@ -41,11 +44,11 @@
# Stop daemons.
msg_stopping "IBM Remote Supervisor Adapter"
killproc --pidfile /var/run/ibmusbasm.pid ibmasm -TERM
- rm -f /var/lock/subsys/ibmusbasm
+ rm -f /var/lock/subsys/ibmasm
}
condrestart() {
- if [ ! -f /var/lock/subsys/ibmusbasm ]; then
+ if [ ! -f /var/lock/subsys/ibmasm ]; then
msg_not_running "IBM Remote Supervisor Adapter"
RETVAL=$1
return
@@ -75,7 +78,7 @@
condrestart 7
;;
status)
- status ibmusbasm ibmasm
+ status ibmasm
RETVAL=$?
;;
*)
================================================================
Index: packages/ibmusbasm/ibmusbasm.spec
diff -u packages/ibmusbasm/ibmusbasm.spec:1.9 packages/ibmusbasm/ibmusbasm.spec:1.10
--- packages/ibmusbasm/ibmusbasm.spec:1.9 Wed Jun 17 04:50:31 2009
+++ packages/ibmusbasm/ibmusbasm.spec Wed Jun 17 05:01:46 2009
@@ -61,7 +61,7 @@
install -d $RPM_BUILD_ROOT{%{_libdir},%{_sbindir},%{_sysconfdir},/etc/rc.d/init.d}
install ibmusbasm-src/shlib/libsysSp.so.1 $RPM_BUILD_ROOT%{_libdir}
install ibmusbasm-src/src/ibmasm $RPM_BUILD_ROOT%{_sbindir}
-install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ibmusbasm
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ibmasm
ln -s libsysSp.so.1 $RPM_BUILD_ROOT%{_libdir}/libsysSp.so
%clean
@@ -69,12 +69,12 @@
%post
/sbin/ldconfig
-/sbin/chkconfig --add ibmusbasm
-%service ibmusbasm restart
+/sbin/chkconfig --add ibmasm
+%service ibmasm restart
if [ "$1" = "0" ]; then
- %service -q ibmusbasm stop
- /sbin/chkconfig --del ibmusbasm
+ %service -q ibmasm stop
+ /sbin/chkconfig --del ibmasm
fi
%postun -p /sbin/ldconfig
@@ -82,7 +82,7 @@
%files
%defattr(644,root,root,755)
%doc readme.txt
-%attr(754,root,root) /etc/rc.d/init.d/ibmusbasm
+%attr(754,root,root) /etc/rc.d/init.d/ibmasm
%attr(755,root,root) %{_libdir}/libsysSp.so
%attr(755,root,root) %{_libdir}/libsysSp.so.1
%attr(755,root,root) %{_sbindir}/ibmasm
@@ -93,6 +93,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.10 2009/06/17 03:01:46 glen
+- ibmasm daemon uses /var/lock/subsys/ibmusbasm for internal locking, do not use that
+
Revision 1.9 2009/06/17 02:50:31 glen
- update to 1.46
- use same lock/pidfile that the daemon itself does for consistency
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/ibmusbasm/ibmusbasm.init?r1=1.5&r2=1.6&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/ibmusbasm/ibmusbasm.spec?r1=1.9&r2=1.10&f=u
More information about the pld-cvs-commit
mailing list