Extend standard disk ( Non lvm)
After the disk has been extended, then rescan for changes.
This guide is based on the SDA disk and the 3 partition. Change the device and partition to match your needs
Rescan for changes in the sda disk
echo 1 | sudo tee /sys/class/block/sdb/device/rescan Code language: PHP (php)
Extend the partition and disk
- Extend the partition with all free space placed after it self.
- Extend the physical volume to its max
- Extend the logical volume group to its max
- Resize the filesystem
- list the result with a df
EXT4
sudo growpart /dev/sdb 1
resize2fs /dev/sdb1
df -h | grep sdb1
XFS
sudo growpart /dev/sdb 1
sudo xfs_growfs /dev/sdb 1
df -h | grep sdb1 