From 3b527f01db1d8258810eb4a8af8a63fc63bd96b0 Mon Sep 17 00:00:00 2001 From: Gregoire Pichon Date: Wed, 16 Jan 2013 14:59:53 +0100 Subject: [PATCH] LU-2625 scripts: prevent several errors in lustre_rmmod This fix prevents lustre_rmmod scripts from returning errors when lustre modules are partially or not loaded. Signed-off-by: Gregoire Pichon Change-Id: Iefb4166b9b14315319858031f53ecb148c589474 Reviewed-on: http://review.whamcloud.com/5040 Tested-by: Hudson Reviewed-by: Andreas Dilger Reviewed-by: Faccini Bruno Tested-by: Maloo --- lustre/scripts/lustre_rmmod | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lustre/scripts/lustre_rmmod b/lustre/scripts/lustre_rmmod index e07f4c9..a4f81d8 100755 --- a/lustre/scripts/lustre_rmmod +++ b/lustre/scripts/lustre_rmmod @@ -28,9 +28,9 @@ unload_dep_module() { return 0 } -lsmod | grep libcfs > /dev/null && $LCTL dl -lsmod | grep $FSTYPE && unload_dep_module $FSTYPE -unload_dep_module libcfs +lsmod | grep obdclass > /dev/null && $LCTL dl +lsmod | grep $FSTYPE > /dev/null && unload_dep_module $FSTYPE +lsmod | grep libcfs > /dev/null && unload_dep_module libcfs MODULES=$($LCTL modules | awk '{ print $2 }') if [ -n "$MODULES" ]; then -- 1.8.3.1