From 6074dcb99970d066b1b0c8bdeac3a40b13a343d0 Mon Sep 17 00:00:00 2001 From: Chiradeep Vittal Date: Fri, 28 Jan 2011 17:29:37 -0800 Subject: [PATCH] Silence vhd-convert, tell us how long it takes --- patches/systemvm/debian/convert.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/patches/systemvm/debian/convert.sh b/patches/systemvm/debian/convert.sh index 3d7dac7f487..6533b5ad599 100755 --- a/patches/systemvm/debian/convert.sh +++ b/patches/systemvm/debian/convert.sh @@ -1,11 +1,12 @@ #!/bin/bash +begin=$(date +%s) echo "Backing up systemvm.img" cp systemvm.img systemvm.img.tmp echo "Converting raw image to fixed vhd" -vhd-util convert -s 0 -t 1 -i systemvm.img.tmp -o systemvm.vhd +vhd-util convert -s 0 -t 1 -i systemvm.img.tmp -o systemvm.vhd &> /dev/null echo "Converting fixed vhd to dynamic vhd" -vhd-util convert -s 1 -t 2 -i systemvm.vhd -o systemvm.vhd +vhd-util convert -s 1 -t 2 -i systemvm.vhd -o systemvm.vhd &> /dev/null echo "Compressing vhd..." bzip2 -c systemvm.vhd > systemvm.vhd.bz2 echo "Done VHD" @@ -37,3 +38,6 @@ md5sum systemvm.vhd.bz2 >> md5sum md5sum systemvm.qcow2 >> md5sum md5sum systemvm.qcow2.bz2 >> md5sum md5sum systemvm.ova >> md5sum +fin=$(date +%s) +t=$((fin-begin)) +echo "Finished compressing/converting image in $t seconds"