[ $MDSCOUNT -gt 9 ] &&
error "script cannot handle more than 9 MDTs, please fix" && exit
-[ $(facet_fstype $SINGLEMDS) = "zfs" ] &&
-# bug number for skipped test: LU-3700
- ALWAYS_EXCEPT="$ALWAYS_EXCEPT 51b"
-
check_and_setup_lustre
if [[ $(lustre_version_code $SINGLEMDS) -lt $(version_code 2.4.53) ]]; then
local fid=$(make_small $f)
check_hsm_flags $f "0x00000000"
+ # LU-4388/LU-4389 - ZFS does not report full number of blocks
+ # used until file is flushed to disk
+ if [ $(facet_fstype ost1) == "zfs" ]; then
+ # this causes an OST_SYNC rpc to be sent
+ dd if=/dev/zero of=$f bs=512 count=1 oflag=sync conv=notrunc,fsync
+ # clear locks to reread file data
+ cancel_lru_locks osc
+ fi
+
local orig_size=$(stat -c "%s" $f)
local orig_blocks=$(stat -c "%b" $f)