(file) Return to pegasus CVS log (file) (dir) Up to [Pegasus] / pegasus / rpm

 1 sage  1.1 #! /bin/sh
 2           #
 3           # Author: Markus Mueller <markus_mueller@de.ibm.com>
 4           #
 5           # /etc/init.d/pegasus
 6           #
 7           #   and symbolic its link
 8           #
 9           # /usr/sbin/rcsshd
10           #
11           ### BEGIN INIT INFO
12           # Provides: pegasus
13           # Required-Start: $network
14           # Required-Stop: $network
15           # Default-Start: 3 5
16           # Default-Stop: 0 1 2 6
17 sage  1.2.2.1 # Description: Start the cimom daemon
18 sage  1.1     ### END INIT INFO
19               
20               . /etc/rc.status
21               . /etc/rc.config
22               
23               # Determine the base and follow a runlevel link name.
24               base=${0##*/}
25               link=${base#*[SK][0-9][0-9]}
26               
27               # Force execution if not called by a runlevel directory.
28               test $link = $base && START_PEGASUS=yes
29               test "$START_PEGASUS" = yes || exit 0
30               
31               # Shell functions sourced from /etc/rc.status:
32               #      rc_check         check and set local and overall rc status
33               #      rc_status        check and set local and overall rc status
34               #      rc_status -v     ditto but be verbose in local rc status
35               #      rc_status -v -r  ditto and clear the local rc status
36               #      rc_failed        set local and overall rc status to failed
37               #      rc_reset         clear local rc status (overall remains)
38               #      rc_exit          exit appropriate to overall rc status
39 sage  1.1     
40               export PEGASUS_HOME=/etc/pegasus
41               
42               # First reset status of this service
43               rc_reset
44               case "$1" in
45                   start)
46               	echo -n "Starting PEGASUS daemon"
47               	## Start daemon with startproc(8). If this fails
48               	## the echo return value is set appropriate.
49               
50 sage  1.2.2.1 	#startproc /usr/bin/cimserver
51 sage  1.2             export PEGASUS_HOME=/etc/pegasus
52                       cimserver -logdir /var/pegasus -d 
53 sage  1.1     
54               	# Remember status and be verbose
55               	rc_status -v
56               	;;
57                   stop)
58               	echo -n "Shutting down PEGASUS daemon:"
59               	## Stop daemon with killproc(8) and if this fails
60               	## set echo the echo return value.
61               
62 sage  1.2.2.1 	#killproc -INT /usr/bin/cimserver
63 sage  1.1     	killall -2 cimserver
64               
65               	# Remember status and be verbose
66               	rc_status -v
67               	;;
68                   restart)
69               	## If first returns OK call the second, if first or
70               	## second command fails, set echo return value.
71               	$0 stop  &&  $0 start
72               
73               	# Remember status and be quiet
74               	rc_status
75               	;;
76                   reload)
77                       echo -n "Reload service PEGASUS"
78 sage  1.2.2.1         #killproc -p /var/run/pegasus.pid -HUP /usr/bin/cimserver
79 sage  1.1     	$0 stop  &&  $0 start
80               	#
81               	rc_status -v
82               	;;
83                   status)
84               	echo -n "Checking for service PEGASUS: "
85 sage  1.2.2.1 	checkproc /usr/bin/cimserver && echo OK || echo No process
86 sage  1.1     	;;
87                   *)
88               	echo "Usage: $0 {start|stop|status|restart|reload}"
89               	exit 1
90               	;;
91               esac
92               rc_exit

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2