aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xshare/hydractl/provision8
1 files changed, 4 insertions, 4 deletions
diff --git a/share/hydractl/provision b/share/hydractl/provision
index 35137ee..c219a0f 100755
--- a/share/hydractl/provision
+++ b/share/hydractl/provision
@@ -231,7 +231,7 @@ else
# See https://rainbow.chard.org/2013/01/30/how-to-align-partitions-for-best-performance-using-parted/
# https://www.kernel.org/doc/Documentation/ABI/testing/sysfs-block
# https://people.redhat.com/msnitzer/docs/io-limits.txt
- megabyte="$((1024*1024))"
+ mebibyte="$((1024*1024))"
block="`echo $device | sed -e 's|^/dev/||'`"
optimal_size="`cat /sys/block/$block/queue/optimal_io_size`"
@@ -240,7 +240,7 @@ else
# https://blog.hqcodeshop.fi/archives/273-GNU-Parted-Solving-the-dreaded-The-resulting-partition-is-not-properly-aligned-for-best-performance.html
# http://opensource.hqcodeshop.com/Parted%20calculator/parted_mkpart_calc.sh
if [ "$optimal_size" == "0" ]; then
- optimal_size="$megabyte"
+ optimal_size="$mebibyte"
fi
alignment_offset="`cat /sys/block/$block/alignment_offset`"
@@ -249,7 +249,7 @@ else
optimal_sector_size="$(($optimal_size / $block_size))"
# Sector size for a 1MB partition
- bios_grub_size="$(($megabyte/$block_size))"
+ bios_grub_size="$(($mebibyte/$block_size))"
bios_grub_end="$(($start + $bios_grub_size - 1))"
# Regular disk partitioning.
@@ -289,7 +289,7 @@ else
#boot_start="$(($bios_grub_end + 1))"
boot_size="1024"
boot_start="`partition_sector_start $start $bios_grub_end $optimal_sector_size`"
- boot_size="$(($boot_size * $megabyte / $block_size))"
+ boot_size="$(($boot_size * $mebibyte / $block_size))"
boot_end="$(($boot_start + $boot_size -1))"
#lvm_start="$($boot_end + 1))"
lvm_start="`partition_sector_start $start $boot_end $optimal_sector_size`"