From: Liu Yuan <tailai...@taobao.com>
Signed-off-by: Liu Yuan <tailai...@taobao.com> --- tests/011 | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/tests/011 b/tests/011 index 781c4fb..b214c3c 100755 --- a/tests/011 +++ b/tests/011 @@ -31,8 +31,16 @@ dd if=/dev/zero of=$STORE/0.img seek=$((2 * 1024 ** 3 - 1)) bs=1 count=1 > $seq. dd if=/dev/zero of=$STORE/1.img seek=$((4 * 1024 ** 3 - 1)) bs=1 count=1 > $seq.full 2>&1 dd if=/dev/zero of=$STORE/2.img seek=$((8 * 1024 ** 3 - 1)) bs=1 count=1 > $seq.full 2>&1 +if [ "$(df -T / | grep ext)" ]; then + mkops="-q -F" +elif [ "$(df -T / | grep xfs)" ]; then + mkops="-f" +else + _die "For now we only support xfs and ext*." +fi + for i in 0 1 2; do - mkfs.xfs -f $STORE/$i.img > $seq.full + mkfs $mkops $STORE/$i.img > $seq.full mkdir $STORE/$i mount -o loop $STORE/$i.img $STORE/$i _start_sheep $i -- 1.7.1 -- sheepdog mailing list sheepdog@lists.wpkg.org http://lists.wpkg.org/mailman/listinfo/sheepdog