Skip to content
Snippets Groups Projects
Commit 65774f57 authored by Elena Gryaznova's avatar Elena Gryaznova
Browse files

b=13147

i=Nathan

Set fail_loc properly on remote mds.
Abort test if zconf_mount $MOUNT2 fail.
parent 97122d8a
No related branches found
No related tags found
No related merge requests found
...@@ -156,9 +156,9 @@ test_9() { ...@@ -156,9 +156,9 @@ test_9() {
mcreate $MOUNT1/$tfile-1 mcreate $MOUNT1/$tfile-1
mcreate $MOUNT2/$tfile-2 mcreate $MOUNT2/$tfile-2
# drop first reint reply # drop first reint reply
sysctl -w lustre.fail_loc=0x80000119 do_facet mds sysctl -w lustre.fail_loc=0x80000119
fail mds fail mds
sysctl -w lustre.fail_loc=0 do_facet mds sysctl -w lustre.fail_loc=0
rm $MOUNT1/$tfile-[1,2] || return 1 rm $MOUNT1/$tfile-[1,2] || return 1
...@@ -172,9 +172,9 @@ test_10() { ...@@ -172,9 +172,9 @@ test_10() {
munlink $MOUNT1/$tfile-1 munlink $MOUNT1/$tfile-1
mcreate $MOUNT2/$tfile-2 mcreate $MOUNT2/$tfile-2
# drop first reint reply # drop first reint reply
sysctl -w lustre.fail_loc=0x80000119 do_facet mds sysctl -w lustre.fail_loc=0x80000119
fail mds fail mds
sysctl -w lustre.fail_loc=0 do_facet mds sysctl -w lustre.fail_loc=0
checkstat $MOUNT1/$tfile-1 && return 1 checkstat $MOUNT1/$tfile-1 && return 1
checkstat $MOUNT1/$tfile-2 || return 2 checkstat $MOUNT1/$tfile-2 || return 2
...@@ -192,11 +192,11 @@ test_11() { ...@@ -192,11 +192,11 @@ test_11() {
mcreate $MOUNT2/$tfile-4 mcreate $MOUNT2/$tfile-4
mcreate $MOUNT1/$tfile-5 mcreate $MOUNT1/$tfile-5
# drop all reint replies for a while # drop all reint replies for a while
sysctl -w lustre.fail_loc=0x0119 do_facet mds sysctl -w lustre.fail_loc=0x0119
facet_failover mds facet_failover mds
#sleep for while, let both clients reconnect and timeout #sleep for while, let both clients reconnect and timeout
sleep $((TIMEOUT * 2)) sleep $((TIMEOUT * 2))
sysctl -w lustre.fail_loc=0 do_facet mds sysctl -w lustre.fail_loc=0
while [ -z "$(ls $MOUNT1/$tfile-[1-5] 2>/dev/null)" ]; do while [ -z "$(ls $MOUNT1/$tfile-[1-5] 2>/dev/null)" ]; do
sleep 5 sleep 5
echo -n "." echo -n "."
...@@ -216,10 +216,10 @@ test_12() { ...@@ -216,10 +216,10 @@ test_12() {
sleep 5 sleep 5
#define OBD_FAIL_LDLM_ENQUEUE 0x302 #define OBD_FAIL_LDLM_ENQUEUE 0x302
sysctl -w lustre.fail_loc=0x80000302 do_facet mds sysctl -w lustre.fail_loc=0x80000302
facet_failover mds facet_failover mds
df $MOUNT || return 1 df $MOUNT || return 1
sysctl -w lustre.fail_loc=0 do_facet mds sysctl -w lustre.fail_loc=0
ls $DIR/$tfile ls $DIR/$tfile
kill -USR1 $MULTIPID || return 3 kill -USR1 $MULTIPID || return 3
...@@ -242,10 +242,10 @@ test_13() { ...@@ -242,10 +242,10 @@ test_13() {
wait $MULTIPID || return 4 wait $MULTIPID || return 4
# drop close # drop close
sysctl -w lustre.fail_loc=0x80000115 do_facet mds sysctl -w lustre.fail_loc=0x80000115
facet_failover mds facet_failover mds
df $MOUNT || return 1 df $MOUNT || return 1
sysctl -w lustre.fail_loc=0 do_facet mds sysctl -w lustre.fail_loc=0
ls $DIR/$tfile ls $DIR/$tfile
$CHECKSTAT -t file $DIR/$tfile || return 2 $CHECKSTAT -t file $DIR/$tfile || return 2
...@@ -270,7 +270,7 @@ test_14() { ...@@ -270,7 +270,7 @@ test_14() {
# first 25 files should have been replayed # first 25 files should have been replayed
unlinkmany $MOUNT1/$tfile- 25 || return 2 unlinkmany $MOUNT1/$tfile- 25 || return 2
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
run_test 14 "timeouts waiting for lost client during replay" run_test 14 "timeouts waiting for lost client during replay"
...@@ -287,7 +287,7 @@ test_15() { ...@@ -287,7 +287,7 @@ test_15() {
unlinkmany $MOUNT1/$tfile- 25 || return 2 unlinkmany $MOUNT1/$tfile- 25 || return 2
[ -e $MOUNT1/$tfile-2-0 ] && error "$tfile-2-0 exists" [ -e $MOUNT1/$tfile-2-0 ] && error "$tfile-2-0 exists"
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
run_test 15 "timeout waiting for lost client during replay, 1 client completes" run_test 15 "timeout waiting for lost client during replay, 1 client completes"
...@@ -336,7 +336,7 @@ test_15a() { ...@@ -336,7 +336,7 @@ test_15a() {
} }
done done
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
#CROW run_test 15a "OST clear orphans - synchronize ids on MDS and OST" #CROW run_test 15a "OST clear orphans - synchronize ids on MDS and OST"
...@@ -352,7 +352,7 @@ test_15b() { ...@@ -352,7 +352,7 @@ test_15b() {
df $MOUNT || return 1 df $MOUNT || return 1
do_facet ost1 "sysctl -w lustre.fail_loc=0" do_facet ost1 "sysctl -w lustre.fail_loc=0"
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
#CROW run_test 15b "multiple delayed OST clear orphans" #CROW run_test 15b "multiple delayed OST clear orphans"
...@@ -368,7 +368,7 @@ test_15c() { ...@@ -368,7 +368,7 @@ test_15c() {
df $MOUNT || return 1 df $MOUNT || return 1
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
run_test 15c "remove multiple OST orphans" run_test 15c "remove multiple OST orphans"
...@@ -386,7 +386,7 @@ test_16() { ...@@ -386,7 +386,7 @@ test_16() {
unlinkmany $MOUNT1/$tfile- 25 || return 2 unlinkmany $MOUNT1/$tfile- 25 || return 2
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
...@@ -407,7 +407,7 @@ test_17() { ...@@ -407,7 +407,7 @@ test_17() {
unlinkmany $MOUNT1/$tfile- 25 || return 2 unlinkmany $MOUNT1/$tfile- 25 || return 2
zconf_mount `hostname` $MOUNT2 zconf_mount `hostname` $MOUNT2 || error "mount $MOUNT2 fail"
return 0 return 0
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment