In sanity.sh test_51b print out the space usage before and after
the test so that the failure can be debugged.
Skip test_51b and test_51ba for ZFS when running regular review
tests, since there isn't a limit of 60000 subdirectories (ZFS
nlink is a 64-bit number), and they take a long time to run in
a VM (20 minutes combined).
Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=51 \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
clientdistro=el6 ossdistro=el6 mdsdistro=el6 \
mdtcount=1 mdssizegb=2 ostcount=2 ostsizegb=8 \
testlist=sanity
Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=51 \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
clientdistro=el6 ossdistro=el6 mdsdistro=el6 \
mdtcount=1 mdssizegb=2 ostcount=2 ostsizegb=8 nettypes=o2ib \
testlist=sanity
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: I21b072fbcb05dea3fd7803bf3353de11ffbcab07
Reviewed-on: http://review.whamcloud.com/12185
Tested-by: Jenkins
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
[ "$SLOW" = "no" ] && EXCEPT_SLOW="24o 27m 64b 68 71 77f 78 115 124b 230d"
[ "$SLOW" = "no" ] && EXCEPT_SLOW="24o 27m 64b 68 71 77f 78 115 124b 230d"
-[ $(facet_fstype $SINGLEMDS) = "zfs" ] &&
-# bug number for skipped test: LU-1593 LU-2833 LU-1957 LU-2805
- ALWAYS_EXCEPT="$ALWAYS_EXCEPT 34h 48a 180 184c"
+if [ $(facet_fstype $SINGLEMDS) = "zfs" ]; then
+ # bug number for skipped test: LU-1593 LU-2833 LU-1957 LU-2805
+ ALWAYS_EXCEPT="$ALWAYS_EXCEPT 34h 48a 180 184c"
+ [ "$SLOW" = "no" ] && EXCEPT_SLOW="$EXCEPT_SLOW 51b 51ba"
+fi
local mdtidx=$(printf "%04x" $($LFS getstripe -M $BASE))
local numfree=$(lctl get_param -n mdc.$FSNAME-MDT$mdtidx*.filesfree)
local mdtidx=$(printf "%04x" $($LFS getstripe -M $BASE))
local numfree=$(lctl get_param -n mdc.$FSNAME-MDT$mdtidx*.filesfree)
- [[ $numfree -lt 21000 ]] && skip "not enough free inodes ($numfree)" &&
+ [[ $numfree -lt 21000 ]] &&
+ skip "not enough free inodes ($numfree) on MDT$mdtidx" &&
return
[[ $numfree -lt $NUMTEST ]] && NUMTEST=$(($numfree - 50)) &&
return
[[ $numfree -lt $NUMTEST ]] && NUMTEST=$(($numfree - 50)) &&
- echo "reduced count to $NUMTEST due to inodes"
+ echo "reduced count to $NUMTEST due to inodes on MDT$mdtidx"
# need to check free space for the directories as well
local blkfree=$(lctl get_param -n mdc.$FSNAME-MDT$mdtidx*.kbytesavail)
numfree=$((blkfree / 4))
# need to check free space for the directories as well
local blkfree=$(lctl get_param -n mdc.$FSNAME-MDT$mdtidx*.kbytesavail)
numfree=$((blkfree / 4))
- [[ $numfree -lt $NUMTEST ]] && NUMTEST=$(($numfree - 50)) &&
- echo "reduced count to $NUMTEST due to blocks"
+ [[ $numfree -lt $NUMTEST ]] && NUMTEST=$((numfree - 50)) &&
+ echo "reduced count to $NUMTEST due to blocks on MDT$mdtidx"
createmany -d $BASE/d $NUMTEST && echo $NUMTEST > $BASE/fnum ||
createmany -d $BASE/d $NUMTEST && echo $NUMTEST > $BASE/fnum ||
+ {
+ $LFS df
+ $LFS df -i
echo "failed" > $BASE/fnum
echo "failed" > $BASE/fnum
+ error "failed to create $NUMTEST subdirs in MDT$mdtidx:$BASE"
+ }
}
run_test 51b "exceed 64k subdirectory nlink limit"
}
run_test 51b "exceed 64k subdirectory nlink limit"