X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Fscripts%2Flustre;h=73c5b22353047dca664990b28f23886d29804944;hb=dd62978b709aebf3dda536f2230f1b79c5361d9c;hp=e6cca001a4fb8ad21e5b6259bfa566d8a2ced5c0;hpb=113303973ec9f8484eb2355a1a6ef3c4c7fd6a56;p=fs%2Flustre-release.git diff --git a/lustre/scripts/lustre b/lustre/scripts/lustre index e6cca00..73c5b22 100755 --- a/lustre/scripts/lustre +++ b/lustre/scripts/lustre @@ -28,8 +28,8 @@ SERVICE=${0##*/} [ -f /etc/sysconfig/lustre ] && . /etc/sysconfig/lustre : ${LUSTRE_CONFIG_XML:=/etc/lustre/config.xml} -: ${LCONF:=/usr/sbin/lconf} -: ${LCTL:=/usr/sbin/lctl} +: ${LCONF:=lconf} +: ${LCTL:=lctl} # Some distros use modprobe.conf.local if [ -f /etc/modprobe.conf.local ]; then : ${MODPROBE_CONF:=/etc/modprobe.conf.local} @@ -136,7 +136,7 @@ stop() { return fi # Cat the modprobe file and place all lines that follow a trailing backslash on the same line - ROUTER=`cat ${MODPROBE_CONF} | sed ':a;N;$!ba;s#\\\[:space:]*\\n##g' | grep lnet | grep forwarding=\"enabled\"` ++ ROUTER=`cat ${MODPROBE_CONF} | sed ':a;N;$!ba;s#\\\[:space:]*\\n##g' | grep lnet | grep forwarding=\"enabled\"` if [[ ! -z ${ROUTER} ]]; then MODULE_LOADED=`lsmod | awk ' { print $1 } ' | grep lnet` if [[ ! -z ${MODULE_LOADED} ]]; then @@ -214,7 +214,7 @@ status() { # If Lustre is up , check if the service really exists # Skip this is we are not checking a specific service if [ $RETVAL -eq 0 ] && [ $SERVICE != 'lustre' ]; then - DUMMY=`lctl dl | grep $SERVICE` + DUMMY=$( $LCTL dl | grep "$SERVICE") [ $? -ne 0 ] && STATE="not_found" && RETVAL=3 fi