07-20-2021, 09:08 PM
(This post was last modified: 07-20-2021, 09:08 PM by Tim Curtis.)
In earlier post "df -h" reports 3.5G for rootfs but "lsblk" reports 7530545152 (7.0G). These two should be ~same.
These commands show the numbers in G
Examples from couple of my systems
These commands show the numbers in G
Code:
lsblk -o size -n /dev/disk/by-label/rootfs
df -h | grep root | awk '{print $2}'
Examples from couple of my systems
Code:
pi@rp2:~ $ lsblk -o size -n /dev/disk/by-label/rootfs
29.5G
pi@rp2:~ $ df -h | grep root | awk '{print $2}'
29G
pi@moode:~ $ lsblk -o size -n /dev/disk/by-label/rootfs
3.9G
pi@moode:~ $ df -h | grep root | awk '{print $2}'
3.9G