(file) Return to tog-pegasus.rc CVS log (file) (dir) Up to [Pegasus] / pegasus / rpm

 1 w.otsuka 1.1 #! /bin/sh
 2              #%/////////////////////////////////////////////////////////////////////////////
 3              #
 4              # Copyright (c) 2004 BMC Software, Hewlett-Packard Company, IBM,
 5              # The Open Group, Tivoli Systems
 6              #
 7              # Permission is hereby granted, free of charge, to any person obtaining a copy
 8              # of this software and associated documentation files (the "Software"), to
 9              # deal in the Software without restriction, including without limitation the
10              # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
11              # sell copies of the Software, and to permit persons to whom the Software is
12              # furnished to do so, subject to the following conditions:
13 w.otsuka 1.3 #
14 w.otsuka 1.1 # THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
15              # ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
16              # "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
17              # LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
18              # PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
19              # HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
20              # ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21              # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22              #
23              #==============================================================================
24              #
25              #%/////////////////////////////////////////////////////////////////////////////
26              
27              ### BEGIN INIT INFO
28              # Provides: tog-pegasus
29              # Required-Start: $syslog $network
30 w.otsuka 1.3 # Should-Start: $time
31              # Required-Stop: $syslog
32 w.otsuka 1.1 # Default-Start:  3 5
33              # Default-Stop: 0 1 2 6
34 w.otsuka 1.3 # Description:	  init script for Pegasus CIM server
35 w.otsuka 1.1 ### END INIT INFO
36              
37              CIMSERVER_BIN=/opt/tog-pegasus/sbin/cimserver
38              prog=cimserver
39              
40              test -x $CIMSERVER_BIN || exit 5
41              
42              . /lib/lsb/init-functions
43              RETVAL=0
44              
45              case "$1" in
46                   start)
47 w.otsuka 1.3 	echo -n $"Starting up CIM server: "
48 w.otsuka 1.1 	start_daemon $CIMSERVER_BIN
49              	RETVAL=$?
50              	[ "$RETVAL" -eq 0 ] && log_success_msg $"$prog start" || log_failure_msg $"$prog start"
51              	echo
52              	;;
53              
54                   stop)
55 w.otsuka 1.3 	echo -n $"Shutting down CIM server: "
56 w.otsuka 1.2 	killproc cimserver
57 w.otsuka 1.1 	RETVAL=$?
58              	[ "$RETVAL" -eq 0 ] && log_success_msg $"$prog stop" || log_failure_msg $"$prog stop"
59              	echo
60              	;;
61 w.otsuka 1.3      status)
62              	pid=`pidofproc $CIMSERVER_BIN`
63 w.otsuka 1.1 	RETVAL=$?
64 w.otsuka 1.3 	if [ "$RETVAL" -eq 0 ]; then
65              		echo "CIM server is running"
66              	else
67              		echo "CIM server is not running"
68              	fi
69 w.otsuka 1.1 	;;
70                   try-restart)
71              	$0 stop && $0 start
72              	;;
73                   restart|force-reload)
74              	$0 stop
75              	$0 start
76              	;;
77                   reload)
78              	;;
79                   *)
80              	echo "Usage: $0 {start|stop|status|restart|reload|force-reload|try-restart}"
81              	exit 1
82              esac
83              
84              exit $RETVAL
85              

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2