From 5209508584c4751eae77548e96636cb77a8502dd Mon Sep 17 00:00:00 2001 From: openoms Date: Thu, 16 May 2024 23:10:47 +0200 Subject: [PATCH] correct rootPartition and rootPartitionBytes with volume group --- home.admin/config.scripts/blitz.bootdrive.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/home.admin/config.scripts/blitz.bootdrive.sh b/home.admin/config.scripts/blitz.bootdrive.sh index 95bcb71fe..79ff3c69f 100644 --- a/home.admin/config.scripts/blitz.bootdrive.sh +++ b/home.admin/config.scripts/blitz.bootdrive.sh @@ -27,10 +27,11 @@ action=$1 ######################### # STATUS -# gather data on sd card +# gather data on SDcard / OS drive minimumSizeByte=16384000000 -rootPartition=$(sudo mount | grep " / " | cut -d " " -f 1 | cut -d "/" -f 3) -rootPartitionBytes=$(lsblk -b -o NAME,SIZE | grep "${rootPartition}" | tr -s ' ' | cut -d " " -f 2) +rootPartitionLine=$(sudo mount | grep " / " | cut -d " " -f 1) +rootPartition=$(basename ${rootPartitionLine}) +rootPartitionBytes=$(lsblk -b -o NAME,SIZE | grep "${rootPartition}" | awk '{print $2}') # make conclusions needsExpansion=0