This is a short note of what to do when you change size of the physical disk an LVM setup, such as the default configuration in CentOS 7.
- Modify the physical disk size
- Modify the partition size
- I used fdisk to delete the partition, then re-create with a larger size
- Reboot
- Extend the physical volume size
-
pvresize <path to enlarged partition>
-
- Extend the logical volume size
-
lvextend <lv path> -l100%FREE
-
- Extend filesystem size
-
resize2fs <lv path>
-
#If you're running CentOS 7, the default filesystem is actually XFS, not ext4. In that case:
xfs_growfs <lv path>
-
- Profit.