X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Ftests%2Fsanity.sh;h=af78fe52b052e2201e79617201efba3e860e1715;hp=b25855a2b5f5fc7056b85fbffb2e48fc42b2d14b;hb=4bba67075aa3d8739d8ca99642ff2b2836774479;hpb=e45e8a92a2ecab742b3680716a55aaa1d9827057 diff --git a/lustre/tests/sanity.sh b/lustre/tests/sanity.sh index b25855a..af78fe5 100755 --- a/lustre/tests/sanity.sh +++ b/lustre/tests/sanity.sh @@ -25435,6 +25435,34 @@ test_820() { } run_test 820 "update max EA from open intent" +test_822() { + local p="$TMP/$TESTSUITE-$TESTNAME.parameters" + + save_lustre_params mds1 \ + "osp.$FSNAME-OST*-osc-MDT0000.max_create_count" > $p + do_facet $SINGLEMDS "$LCTL set_param -n \ + osp.$FSNAME-OST*MDT0000.max_create_count=0" + do_facet $SINGLEMDS "$LCTL set_param -n \ + osp.$FSNAME-OST0000*MDT0000.max_create_count=20000" + + # wait for statfs update to clear OS_STATFS_NOPRECREATE + local maxage=$(do_facet mds1 $LCTL get_param -n \ + osp.$FSNAME-OST0000*MDT0000.maxage) + sleep $((maxage + 1)) + + #define OBD_FAIL_NET_ERROR_RPC 0x532 + do_facet mds1 "$LCTL set_param fail_loc=0x80000532 fail_val=5" + + stack_trap "restore_lustre_params < $p; rm $p" + + local count=$(do_facet $SINGLEMDS "lctl get_param -n \ + osp.$FSNAME-OST0000*MDT0000.create_count") + for i in $(seq 1 $count); do + touch $DIR/$tfile.${i} || error "touch failed" + done +} +run_test 822 "test precreate failure" + # # tests that do cleanup/setup should be run at the end #