centos 7 LVM expansion space

Initialize the disk:
fdisk disk path to obtain the -l #
fdisk / dev / sdb # Initialize Disk
mkfs.xfs / dev / sdb3

Creating the PV
the pvcreate / dev / sdb3
pvdisplay # pv status display
added to the logical partition
vgdiplay # View vg condition and name vg
pv vgextend CentOS / dev / sdb # join the newly created VG, centos is the name of VG name.
lvextend -L + 200G / dev / mapper / centos-root # VG added to the LV.
lvdisplay # View LV state
xfs_growfs / dev / mapper / centos- root # resize the file system.
Note: for the primary partition type is used when xfs xfs_growfs, such as not using resize2fs

Guess you like

Origin blog.csdn.net/qq_42409788/article/details/82185872