try to restart rpc-rquotad if it is not running
authorRonnie Sahlberg <ronniesahlberg@gmail.com>
Fri, 12 Feb 2010 02:19:57 +0000 (13:19 +1100)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Tue, 16 Feb 2010 00:02:37 +0000 (11:02 +1100)
bz60317

config/events.d/60.nfs

index 1eca005746882a7550def30450aafe48dd38803b..2115d46e647d840d35715f51c81fcc16036c95e2 100755 (executable)
@@ -103,6 +103,16 @@ case "$1" in
                rpc.mountd $RPCMOUNTDOPTS &
                exit 1
        }
+       # rquotad needs special handling since it is sometimes not started
+       # correctly on RHEL5
+       # this is not a critical service so we dont flag the node as unhealthy
+       rpcinfo -u localhost 100011 1 > /dev/null || {
+               echo "ERROR: RQUOTAD is not running. Trying to restart it."
+               RPCRQUOTADOPTS=""
+               [ -n "$RQUOTAD_PORT" ] && RPCRQUOTADOPTS="$RPCRQUOTADOPTS -p $RQUOTAD_PORT"
+               killall -q -9 rpc.rquotad
+               rpc.rquotad $RPCRQUOTADOPTS &
+       }
                ;;
 
     *)