Commit b15035d0 authored by Mike Hibler's avatar Mike Hibler
Browse files

Fix calculation of slop size when comparing actual/expected sizes of LVs.

parent 78bb403f
#!/usr/bin/perl -wT #!/usr/bin/perl -wT
# #
# Copyright (c) 2013-2015 University of Utah and the Flux Group. # Copyright (c) 2013-2016 University of Utah and the Flux Group.
# #
# {{{EMULAB-LICENSE # {{{EMULAB-LICENSE
# #
...@@ -947,8 +947,13 @@ sub os_check_storage_slice($$) ...@@ -947,8 +947,13 @@ sub os_check_storage_slice($$)
$dev = "emulab/$lv"; $dev = "emulab/$lv";
$mdev = "mapper/emulab-$lv"; $mdev = "mapper/emulab-$lv";
$devtype = "LVM"; $devtype = "LVM";
# XXX LVM rounds up to extent size (4 MiB) # XXX LVM rounds up to physical extent size (4 MiB)
$slop = 3; # on every physical volume that is in the VG
if (exists($so->{'LVM_VGDEVS'}) && $so->{'LVM_VGDEVS'} > 1) {
$slop = (4 * $so->{'LVM_VGDEVS'}) - 1;
} else {
$slop = 3;
}
} }
my $devsize = $href->{'VOLSIZE'}; my $devsize = $href->{'VOLSIZE'};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment