diff --git a/scripts/zpool-config/file-raid0.sh b/scripts/zpool-config/file-raid0.sh index 14429c43d9..5ec80b05c1 100644 --- a/scripts/zpool-config/file-raid0.sh +++ b/scripts/zpool-config/file-raid0.sh @@ -12,8 +12,8 @@ zpool_create() { for FILE in ${FILES}; do msg "Creating ${FILE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" done msg ${ZPOOL} create ${FORCE_FLAG} ${ZPOOL_NAME} ${FILES} diff --git a/scripts/zpool-config/file-raid10.sh b/scripts/zpool-config/file-raid10.sh index a632a4f4cd..ae7f0ae07b 100644 --- a/scripts/zpool-config/file-raid10.sh +++ b/scripts/zpool-config/file-raid10.sh @@ -13,8 +13,8 @@ zpool_create() { for FILE in ${FILES}; do msg "Creating ${FILE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" done msg ${ZPOOL} create ${FORCE_FLAG} ${ZPOOL_NAME} \ diff --git a/scripts/zpool-config/file-raidz.sh b/scripts/zpool-config/file-raidz.sh index 9302c85e97..5b6c3ea2c2 100644 --- a/scripts/zpool-config/file-raidz.sh +++ b/scripts/zpool-config/file-raidz.sh @@ -12,8 +12,8 @@ zpool_create() { for FILE in ${FILES}; do msg "Creating ${FILE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" done msg ${ZPOOL} create ${FORCE_FLAG} ${ZPOOL_NAME} raidz ${FILES} diff --git a/scripts/zpool-config/file-raidz2.sh b/scripts/zpool-config/file-raidz2.sh index 681352783c..bc0e5ec8af 100644 --- a/scripts/zpool-config/file-raidz2.sh +++ b/scripts/zpool-config/file-raidz2.sh @@ -12,8 +12,8 @@ zpool_create() { for FILE in ${FILES}; do msg "Creating ${FILE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" done msg ${ZPOOL} create ${FORCE_FLAG} ${ZPOOL_NAME} raidz2 ${FILES} diff --git a/scripts/zpool-config/lo-raid0.sh b/scripts/zpool-config/lo-raid0.sh index d37d5138f7..321d9b1f71 100644 --- a/scripts/zpool-config/lo-raid0.sh +++ b/scripts/zpool-config/lo-raid0.sh @@ -14,8 +14,8 @@ zpool_create() { DEVICE=`unused_loop_device` msg "Creating ${FILE} using loopback device ${DEVICE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" ${LOSETUP} ${DEVICE} ${FILE} || die "Error $? creating ${FILE} -> ${DEVICE} loopback" DEVICES="${DEVICES} ${DEVICE}" diff --git a/scripts/zpool-config/lo-raid10.sh b/scripts/zpool-config/lo-raid10.sh index 8d3672dd1b..f9c47cd1e1 100644 --- a/scripts/zpool-config/lo-raid10.sh +++ b/scripts/zpool-config/lo-raid10.sh @@ -16,8 +16,8 @@ zpool_create() { DEVICE=`unused_loop_device` msg "Creating ${FILE} using loopback device ${DEVICE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" ${LOSETUP} ${DEVICE} ${FILE} || die "Error $? creating ${FILE} -> ${DEVICE} loopback" DEVICES_M1="${DEVICES_M1} ${DEVICE}" @@ -27,8 +27,8 @@ zpool_create() { DEVICE=`unused_loop_device` msg "Creating ${FILE} using loopback device ${DEVICE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" ${LOSETUP} ${DEVICE} ${FILE} || die "Error $? creating ${FILE} -> ${DEVICE} loopback" DEVICES_M2="${DEVICES_M2} ${DEVICE}" diff --git a/scripts/zpool-config/lo-raidz.sh b/scripts/zpool-config/lo-raidz.sh index 6efcd1041a..509f6ee1d7 100644 --- a/scripts/zpool-config/lo-raidz.sh +++ b/scripts/zpool-config/lo-raidz.sh @@ -14,8 +14,8 @@ zpool_create() { DEVICE=`unused_loop_device` msg "Creating ${FILE} using loopback device ${DEVICE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" ${LOSETUP} ${DEVICE} ${FILE} || die "Error $? creating ${FILE} -> ${DEVICE} loopback" DEVICES="${DEVICES} ${DEVICE}" diff --git a/scripts/zpool-config/lo-raidz2.sh b/scripts/zpool-config/lo-raidz2.sh index f59c7f2d65..6e61293c0b 100644 --- a/scripts/zpool-config/lo-raidz2.sh +++ b/scripts/zpool-config/lo-raidz2.sh @@ -14,8 +14,8 @@ zpool_create() { DEVICE=`unused_loop_device` msg "Creating ${FILE} using loopback device ${DEVICE}" rm -f ${FILE} || exit 1 - dd if=/dev/zero of=${FILE} bs=1024k count=256 &>/dev/null || - die "Error $? creating ${FILE}" + dd if=/dev/zero of=${FILE} bs=1024k count=0 seek=256 \ + &>/dev/null || die "Error $? creating ${FILE}" ${LOSETUP} ${DEVICE} ${FILE} || die "Error $? creating ${FILE} -> ${DEVICE} loopback" DEVICES="${DEVICES} ${DEVICE}"