From 804d52e9d52f9f1004bdc1c0b5920a1a17d4db6f Mon Sep 17 00:00:00 2001 From: dzogin Date: Wed, 26 Aug 2009 19:41:55 +0000 Subject: [PATCH] Branch b1_8 b=14951 i=grev Modified Files: lustre/ChangeLog lustre/tests/conf-sanity.sh Description: Improved cleanup procedure for conf-sanity test_46a. --- lustre/ChangeLog | 4 ++++ lustre/tests/conf-sanity.sh | 32 +++++++++++++++++++++++--------- 2 files changed, 27 insertions(+), 9 deletions(-) diff --git a/lustre/ChangeLog b/lustre/ChangeLog index 2fc3569..3c4fdc1 100644 --- a/lustre/ChangeLog +++ b/lustre/ChangeLog @@ -15,6 +15,10 @@ tbd Sun Microsystems, Inc. more information, please refer to bugzilla 17630. Severity : normal +Bugzilla : 14951 +Description: Improved cleanup procedure for conf-sanity test_46a. + +Severity : normal Bugzilla : 19566 Description: Prevent inconsistences between linux and lustre mount structures. Details : Wait indefinitely in server_wait_finished() until mnt_count drops. diff --git a/lustre/tests/conf-sanity.sh b/lustre/tests/conf-sanity.sh index a07e9b2..53b4a58 100644 --- a/lustre/tests/conf-sanity.sh +++ b/lustre/tests/conf-sanity.sh @@ -1502,8 +1502,27 @@ test_45() { #17310 } run_test 45 "long unlink handling in ptlrpcd" +cleanup_46a() { + trap 0 + local rc=0 + local count=5 + + umount_client $MOUNT2 || rc=$? + umount_client $MOUNT || rc=$? + while [ $count -gt 0 ]; do + stop ost${count} -f || rc=$? + let count=count-1 + done + stop_mds || rc=$? + # writeconf is needed after the test, otherwise, + # we might end up with extra OSTs + writeconf || rc=$? + cleanup_nocli || rc=$? + return $rc +} + test_46a() { - OSTCOUNT=6 + OSTCOUNT=5 reformat start_mds || return 1 #first client should see only one ost @@ -1511,6 +1530,7 @@ test_46a() { wait_osc_import_state mds ost FULL #start_client mount_client $MOUNT || return 3 + trap cleanup_46a EXIT ERR start_ost2 || return 4 start ost3 `ostdevname 3` $OST_MOUNT_OPTS || return 5 @@ -1536,14 +1556,8 @@ test_46a() { # will be deadlock stat $MOUNT/widestripe || return 12 - umount_client $MOUNT2 || return 13 - umount_client $MOUNT || return 14 - stop ost5 -f || return 20 - stop ost4 -f || return 21 - stop ost3 -f || return 22 - stop_ost2 || return 23 - stop_ost || return 24 - stop_mds || return 25 + cleanup_46a || { echo "cleanup_46a failed!" && return 13; } + return 0 } run_test 46a "handle ost additional - wide striped file" -- 1.8.3.1