correct rootPartition and rootPartitionBytes with volume group

This commit is contained in:
openoms 2024-05-16 23:10:47 +02:00
parent 425442c248
commit 5209508584
No known key found for this signature in database
GPG key ID: 5BFB77609B081B65

View file

@ -27,10 +27,11 @@ action=$1
######################### #########################
# STATUS # STATUS
# gather data on sd card # gather data on SDcard / OS drive
minimumSizeByte=16384000000 minimumSizeByte=16384000000
rootPartition=$(sudo mount | grep " / " | cut -d " " -f 1 | cut -d "/" -f 3) rootPartitionLine=$(sudo mount | grep " / " | cut -d " " -f 1)
rootPartitionBytes=$(lsblk -b -o NAME,SIZE | grep "${rootPartition}" | tr -s ' ' | cut -d " " -f 2) rootPartition=$(basename ${rootPartitionLine})
rootPartitionBytes=$(lsblk -b -o NAME,SIZE | grep "${rootPartition}" | awk '{print $2}')
# make conclusions # make conclusions
needsExpansion=0 needsExpansion=0