Just a quoted string does not really do what we need
Fixes:
8befc64e5a ("LU-13404 utils: fix lfs mirror duplicate file check")
Fixes:
41bfc1ec78 ("LU-8998 tests: test scripts for PFL")
Fixes:
3afede2b81 ("LU-8900 snapshot: user interface for write barrier on MDT")
Fixes:
fdad38781c ("LU-11376 lmv: new foreign LMV format")
Fixes:
6a20bdcc60 ("LU-11376 lov: new foreign LOV format")
Fixes:
4af3ab1945 ("LU-2017 mdc: add layout swap between 2 objects")
Test-Parameters: trivial testlist=sanity,sanity-pfl,sanity-flr,sanity-lfsck
Change-Id: Id0f70512ade1cc93cbd4979dc2925f1e834f6816
Signed-off-by: Oleg Drokin <green@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/45995
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Nunez <jnunez@whamcloud.com>
$LFS mirror resync $DIR/$tfile || error "resync $DIR/$tfile failed"
cmp /etc/hosts $DIR/$tfile || error "cmp with /etc/hosts failed"
$LFS mirror resync $DIR/$tfile || error "resync $DIR/$tfile failed"
cmp /etc/hosts $DIR/$tfile || error "cmp with /etc/hosts failed"
- $LFS mirror read -N2 -o $TMP/$tfile $DIR/$tfile || "read mirror failed"
+ $LFS mirror read -N2 -o $TMP/$tfile $DIR/$tfile || error "read mirror failed"
stack_trap "rm -f $TMP/$tfile"
cmp $TMP/$tfile $DIR/$tfile || error "cmp with $TMP/$tfile failed"
stack_trap "rm -f $TMP/$tfile"
cmp $TMP/$tfile $DIR/$tfile || error "cmp with $TMP/$tfile failed"
- $LFS mirror write -N2 -i /etc/passwd $DIR/$tfile || "write failed"
+ $LFS mirror write -N2 -i /etc/passwd $DIR/$tfile || error "write failed"
$LFS setstripe --comp-set -I 65537 --comp-flags=stale $DIR/$tfile ||
error "set component 1 stale failed"
$LFS mirror resync $DIR/$tfile || error "resync $DIR/$tfile failed"
$LFS setstripe --comp-set -I 65537 --comp-flags=stale $DIR/$tfile ||
error "set component 1 stale failed"
$LFS mirror resync $DIR/$tfile || error "resync $DIR/$tfile failed"
error "$DIR/$tdir/$tfile: setstripe should fail"
# R/W should fail
error "$DIR/$tdir/$tfile: setstripe should fail"
# R/W should fail
- cat $DIR/$tdir/$tfile && "$DIR/$tdir/$tfile: read should fail"
+ cat $DIR/$tdir/$tfile && error "$DIR/$tdir/$tfile: read should fail"
cat /etc/passwd > $DIR/$tdir/$tfile &&
error "$DIR/$tdir/$tfile: write should fail"
cat /etc/passwd > $DIR/$tdir/$tfile &&
error "$DIR/$tdir/$tfile: write should fail"
[ "$old_chksum" != "$chksum" ] &&
error "(composite -> v1) $old_chksum != $chksum"
[ "$old_chksum" != "$chksum" ] &&
error "(composite -> v1) $old_chksum != $chksum"
- rm -f $comp_file || "Delete $comp_file failed"
+ rm -f $comp_file || error "Delete $comp_file failed"
}
run_test 6 "Migrate composite file"
}
run_test 6 "Migrate composite file"
$RUNAS $LFS setstripe --component-add -E -1 -c 5 $comp_file ||
error "Add last component to $comp_file failed"
$RUNAS $LFS setstripe --component-add -E -1 -c 5 $comp_file ||
error "Add last component to $comp_file failed"
- rm $comp_file || "Delete composite failed"
+ rm $comp_file || error "Delete composite failed"
}
run_test 7 "Add/Delete/Create composite file by non-privileged user"
}
run_test 7 "Add/Delete/Create composite file by non-privileged user"
error "$DIR/$tdir/${tdir}2: invalid LMV EA value"
# file create in dir should fail
error "$DIR/$tdir/${tdir}2: invalid LMV EA value"
# file create in dir should fail
- touch $DIR/$tdir/$tdir/$tfile && "$DIR/$tdir: file create should fail"
+ touch $DIR/$tdir/$tdir/$tfile && error "$DIR/$tdir: file create should fail"
touch $DIR/$tdir/${tdir}2/$tfile &&
touch $DIR/$tdir/${tdir}2/$tfile &&
- "$DIR/${tdir}2: file create should fail"
+ error "$DIR/${tdir}2: file create should fail"
# chmod should work
chmod 777 $DIR/$tdir/$tdir ||
# chmod should work
chmod 777 $DIR/$tdir/$tdir ||
# file create in dir should fail
# ("/{foreign_symlink_prefix}/${uuid1}/${uuid2}/" missing)
# file create in dir should fail
# ("/{foreign_symlink_prefix}/${uuid1}/${uuid2}/" missing)
- touch $DIR/$tdir/$tdir/$tfile && "$DIR/$tdir: file create should fail"
+ touch $DIR/$tdir/$tdir/$tfile && error "$DIR/$tdir: file create should fail"
# rename should succeed
mv $DIR/$tdir/$tdir $DIR/$tdir/${tdir}.new ||
# rename should succeed
mv $DIR/$tdir/$tdir $DIR/$tdir/${tdir}.new ||
$LFS swap_layouts $file1 $file2 || error "swap of file layout failed"
gen=$($LFS getstripe -g $file1)
[[ $gen1 != $gen ]] ||
$LFS swap_layouts $file1 $file2 || error "swap of file layout failed"
gen=$($LFS getstripe -g $file1)
[[ $gen1 != $gen ]] ||
- "Layout generation on $file1 does not change"
+ error "Layout generation on $file1 does not change"
gen=$($LFS getstripe -g $file2)
[[ $gen2 != $gen ]] ||
gen=$($LFS getstripe -g $file2)
[[ $gen2 != $gen ]] ||
- "Layout generation on $file2 does not change"
+ error "Layout generation on $file2 does not change"
cmp $ref1 $file2 || error "content compare failed ($ref1 != $file2)"
cmp $ref2 $file1 || error "content compare failed ($ref2 != $file1)"
cmp $ref1 $file2 || error "content compare failed ($ref1 != $file2)"
cmp $ref2 $file1 || error "content compare failed ($ref2 != $file1)"
prep_801
mkdir $DIR/$tdir || error "(1) fail to mkdir"
prep_801
mkdir $DIR/$tdir || error "(1) fail to mkdir"
- createmany -d $DIR/$tdir/d 6 || "(2) fail to mkdir"
+ createmany -d $DIR/$tdir/d 6 || error "(2) fail to mkdir"
touch $DIR/$tdir/d2/f10 || error "(3) fail to touch"
touch $DIR/$tdir/d3/f11 || error "(4) fail to touch"
touch $DIR/$tdir/d4/f12 || error "(5) fail to touch"
touch $DIR/$tdir/d2/f10 || error "(3) fail to touch"
touch $DIR/$tdir/d3/f11 || error "(4) fail to touch"
touch $DIR/$tdir/d4/f12 || error "(5) fail to touch"