[Linux-cluster] [PATCH] cman/init.d/cman.in: don't assume chkconfig exists

Fabio M. Di Nitto fdinitto at redhat.com
Tue Mar 23 06:55:12 UTC 2010


Hi Guido,

in future, can you please send patches to cluster-devel at redhat.com? It´s
easier for me to spot them.

On 3/10/2010 10:27 PM, Guido Günther wrote:
> Hi,
> attached patch makes sure we don't rely on chkconffig (which doesn't
> exist on Debian based distros). It also checks additionally for
> network-manager since this is the name of the service on Debian/Ubuntu.
> Cheers,
>  -- Guido

I am not entirely sure why we need this patch.

> # deb based distros
> if [ -d /etc/default ]; then
>         [ -f /etc/default/cluster ] && . /etc/default/cluster
>         [ -f /etc/default/cman ] && . /etc/default/cman
>         [ -z "$LOCK_FILE" ] && LOCK_FILE="/var/lock/cman"
>         type chkconfig > /dev/null 2>&1 || alias chkconfig=local_chkconfig
> fi

local_chkconfig mimics chkconfig behavior on Debian based systems that
don´t have chkconfig.

It was tested successfully on Ubuntu, but I don´t see why it would work
on Debian. If the local_chkconfig is broken, then we need to fix that as
it is used also for xen_bridge workaround.

Thanks
Fabio




More information about the Linux-cluster mailing list