14 new_fs ext2 /tmp/ost 10000
17 new_fs ${MDSFS} /tmp/mds 10000
20 echo 0xffffffff > /proc/sys/portals/debug
38 mount -t lustre_light -o device=3 none /mnt/obd
41 echo $1 > /proc/sys/lustre/fail_loc
46 echo "Cleaning up and restarting MDS"
54 echo 0 > /proc/sys/lustre/fail_loc
61 mount -t lustre_light -o device=3 none /mnt/obd
67 chmod a+x /mnt/obd/foo
70 # OBD_FAIL_MDS_REINT_SETATTR_WRITE - MDS will discard data from setattr
71 test_fail 0x10a chmod 000 /mnt/obd/foo
73 [ ! -x /mnt/obd/foo ] && echo "/mnt/obd/foo is executable!" 1>&2 && exit -1
75 # OBD_FAIL_MDS_REINT_CREATE_WRITE - MDS will not create the file
76 test_fail 0x10c touch /mnt/obd/bar
78 [ $? -eq 0 ] && echo "/mnt/obd/bar was created!" 1>&2 && exit -1
80 # OBD_FAIL_MDS_REINT_UNLINK_WRITE - MDS will discard data from unlink
81 test_fail 0x10e rm /mnt/obd/foo
83 [ $? -eq 1 ] && echo "/mnt/obd/foo has been removed!" 1>&2 && exit -1
85 # OBD_FAIL_MDS_REINT_RENAME_WRITE - MDS will discard data from rename
86 test_fail 0x112 mv /mnt/obd/foo /mnt/obd/bar
88 [ $? -eq 0 ] && echo "/mnt/obd/foo has been renamed to bar!" 1>&2 && exit -1