Output DD results

This commit is contained in:
Joshua Boniface 2021-12-12 00:49:30 -05:00
parent 87011ff63b
commit 0708f286db
1 changed files with 4 additions and 3 deletions

View File

@ -518,10 +518,11 @@ blockcheck() {
echo -n "Checking if block device '${target_disk}' is already wiped... " echo -n "Checking if block device '${target_disk}' is already wiped... "
if ! cmp --silent --bytes ${blockdev_size_bytes} /dev/zero ${target_disk}; then if ! cmp --silent --bytes ${blockdev_size_bytes} /dev/zero ${target_disk}; then
echo "false." echo "false."
echo -n "Wiping block device '${target_disk}' (${count} blocks of ${size} bytes)... " echo "Wiping block device '${target_disk}' (${count} blocks of ${size} bytes)..."
dd if=/dev/zero of=${target_disk} bs=${size} count=${count} oflag=direct &>/dev/null dd if=/dev/zero of=${target_disk} bs=${size} count=${count} oflag=direct status=progress
fi else
echo "done." echo "done."
fi
} }
blockcheck blockcheck