diff options
author | Brian Behlendorf <[email protected]> | 2015-07-13 10:30:22 -0700 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2015-07-13 11:02:59 -0700 |
commit | 5970eb3d60346d385d0910c00ed5199b9af223c8 (patch) | |
tree | b307f23ec0686bf9fb19fab5da47c1bb8bd9db25 /scripts | |
parent | 541da9935d07ad40fb5e000114d9c904c2dde632 (diff) |
Use truncate instead of fallocate in ziltest.sh
For the purposes of creating sparse files the truncate command is
preferable to fallocate because generic sparse files are more widely
supported by older platforms. Specifically Debian Wheezy which is
based on a 2.6.32 kernel used ext3 by default which at the time did
not support it.
Signed-off-by: Brian Behlendorf <[email protected]>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/ziltest.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/ziltest.sh b/scripts/ziltest.sh index dafeb5751..62cf09e88 100755 --- a/scripts/ziltest.sh +++ b/scripts/ziltest.sh @@ -116,8 +116,8 @@ test $# -eq 0 || bail "usage: $CMD" # Create a destination for runtime copy of FS # Freeze transaction syncing in the pool # ==================================================================== -fallocate -l "$DEVSIZE" $POOLFILE || bail "can't make $POOLFILE" -fallocate -l "$DEVSIZE" $SLOGFILE || bail "can't make $SLOGFILE" +truncate -s "$DEVSIZE" $POOLFILE || bail "can't make $POOLFILE" +truncate -s "$DEVSIZE" $SLOGFILE || bail "can't make $SLOGFILE" zpool create $POOL $POOLFILE log $SLOGFILE || bail "can't create pool $POOL" zpool list $POOL |