]> gitweb.fluxo.info Git - hydra.git/commitdiff
Get time spent on rsync at sync-guestfs
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 4 Jun 2017 18:05:30 +0000 (15:05 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 4 Jun 2017 18:05:30 +0000 (15:05 -0300)
share/hydractl/sync-guestfs

index 96e74cdec28501600434772120e43cd48e360c04..4055c0a86806801f6b4c2b3a08a17559c5c0b4a0 100755 (executable)
@@ -59,10 +59,10 @@ DEST_MOUNT="`mktemp -d $TMP/sync-guestfs-dest.XXXXXXXXXX`"
       # See https://gergap.wordpress.com/2013/08/10/rsync-and-sparse-files/
       #     https://stackoverflow.com/questions/19821186/rsync-sparse-does-transfer-whole-data#19827546
       echo "Making the first copy of $image to $DEST, which might take a while..."
-      $SUDO $RSYNC --sparse $image $DEST/$image
+      time $SUDO $RSYNC --sparse $image $DEST/$image
     else
       echo "Destination $DEST/$image exists, syncing..."
-      $SUDO $RSYNC --inplace $image $DEST/$image
+      time $SUDO $RSYNC --inplace $image $DEST/$image
 
       #
       # Sync using libguestfs-tools: mount existing