From a0fbd41d2b10829503df1826bf2c98dc347de739 Mon Sep 17 00:00:00 2001 From: Aravinda VK Date: Fri, 17 Jan 2014 16:45:55 +0530 Subject: geo-rep: Fix no error when slave size less than master size in df command output, default block-size is 1K, but BUFFER_SIZE is in bytes, so verify will succeed even if slave size is less than master size. Added -B1 to df command(that is --block-size=1) to get all values in bytes. BUG: 1056518 Change-Id: I2384d2a6f2505d967e0538b95fbf111c15b26f30 Signed-off-by: Aravinda VK Reviewed-on: http://review.gluster.org/6746 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- geo-replication/src/gverify.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'geo-replication/src/gverify.sh') diff --git a/geo-replication/src/gverify.sh b/geo-replication/src/gverify.sh index bd1b25f2482..24580be44f5 100755 --- a/geo-replication/src/gverify.sh +++ b/geo-replication/src/gverify.sh @@ -32,7 +32,7 @@ echo 0:0; exit 1; fi; cd \$d; -available_size=\$(df \$d | tail -1 | awk "{print \\\$2}"); +available_size=\$(df -B1 \$d | tail -1 | awk "{print \\\$2}"); umount -l \$d; rmdir \$d; ver=\$(gluster --version | head -1 | cut -f2 -d " "); @@ -61,7 +61,7 @@ echo 0:0; exit 1; fi; cd \$d; -available_size=\$(df \$d | tail -1 | awk "{print \\\$4}"); +available_size=\$(df -B1 \$d | tail -1 | awk "{print \\\$4}"); no_of_files=\$(find \$d -maxdepth 0 -empty); umount -l \$d; rmdir \$d; -- cgit