FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Cluster Development

 
 
LinkBack Thread Tools
 
Old 01-06-2011, 09:37 AM
"Fabio M. Di Nitto"
 
Default Cman: test that corosync is not already running

Re-iterating the patch for ACK to go in RHEL6.

Fabio

On 1/6/2011 11:28 AM, Fabio M. Di Nitto wrote:
> From: Jan Friesse <jfriesse@redhat.com>
>
> Patch fixes init file so now before cman start is tested, if corosync is
> running. If so, init script will refuse to start.
>
> Resolves: rhbz#617234
> ---
> cman/init.d/cman.in | 14 ++++++++++++++
> 1 files changed, 14 insertions(+), 0 deletions(-)
>
> diff --git a/cman/init.d/cman.in b/cman/init.d/cman.in
> index 7dae24d..6dfc119 100644
> --- a/cman/init.d/cman.in
> +++ b/cman/init.d/cman.in
> @@ -521,11 +521,25 @@ stop_configfs()
> fi
> }
>
> +corosync_running()
> +{
> + [ -f /var/run/corosync.pid ] || return 1
> +
> + read corosync_pid foo < /var/run/corosync.pid
> + if [ "$(pidof corosync)" == "$corosync_pid" ];then
> + errmsg="Corosync Cluster Engine is already running"
> + return 0
> + fi
> +
> + return 1
> +}
> +
> start_cman()
> {
> check_exec cman_tool || return $?
> cman_running && return 0
> cman_checkconfig || return 1
> + corosync_running && return 1
>
> tmpfile=$(mktemp -t cmanstartup.XXXXXXXXXX)
> if [ -z "$tmpfile" ]; then
 

Thread Tools




All times are GMT. The time now is 02:39 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org