mirror of
				https://git.proxmox.com/git/mirror_corosync
				synced 2025-10-31 16:40:41 +00:00 
			
		
		
		
	 ec4a06ec3c
			
		
	
	
		ec4a06ec3c
		
	
	
	
	
		
			
			git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1648 fd59a12c-fef9-0310-b244-a6a79926bd2f
		
			
				
	
	
		
			59 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			59 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
| #!/bin/sh
 | |
| #
 | |
| # Corosync daemon init script for Red Hat Linux and compatibles.
 | |
| #
 | |
| # chkconfig: - 20 20
 | |
| # processname:  corosync
 | |
| # pidfile:      /var/run/corosync.pid
 | |
| # description:  Corosync Cluster Engine
 | |
| 
 | |
| # Source function library
 | |
| . /etc/rc.d/init.d/functions
 | |
| 
 | |
| prog="corosync"
 | |
| exec="/usr/sbin/corosync"
 | |
| lockfile="/var/lock/subsys/corosync"
 | |
| 
 | |
| [ -x "$exec" ] || exit 0
 | |
| 
 | |
| start() {
 | |
|     echo -n $"Starting Corosync Cluster Engine ($prog): "
 | |
|     daemon $exec
 | |
|     retval=$?
 | |
|     [ "$retval" -eq 0 ] && touch "$lockfile"
 | |
|     echo
 | |
|     return $retval
 | |
| }
 | |
| 
 | |
| stop() {
 | |
|     echo -n $"Stopping Corosync Cluster Engine ($prog): "
 | |
|     killproc $prog
 | |
|     retval=$?
 | |
|     [ "$retval" -eq 0 ] && rm -f "$lockfile"
 | |
|     echo
 | |
|     return $retval
 | |
| }
 | |
| 
 | |
| restart() {
 | |
|     stop
 | |
|     start
 | |
| }
 | |
| 
 | |
| case "$1" in
 | |
|     start|stop|restart)
 | |
|         $1
 | |
|         ;;
 | |
|     reload|force-reload)
 | |
|         restart
 | |
|         ;;
 | |
|     condrestart|try-restart)
 | |
|         [ ! -f "$lockfile" ] || restart
 | |
|         ;;
 | |
|     status)
 | |
|         status $prog
 | |
|         ;;
 | |
|     *)
 | |
|         echo $"Usage: $0 {start|stop|restart|try-restart|condrestart|reload|force-reload|status}"
 | |
|         exit 2
 | |
| esac
 |