How to Extend/Reduce LVM’s (Logical Volume Management) in Linux
To extend or reduce an LVM (Logical Volume Management) in Linux, you can follow the steps below. This involves managing the logical volumes, volume groups, and physical volumes. I will break down both extending and reducing the logical volume (LV).

Requirements
When do we need to reduce volume?
May be we need to create a separate partition for any other use or we need to expand the size of any low space partition, if so we can reduce the large size partition and we can expand the low space partition very easily by the following simple easy steps.
My Server Setup--Requirements
- Operating System- RHEL-9
- Server IP – 192.168.13.84

Logical Volume Extending
Currently, we have One PV, VG and 2 LV. Let’s list them one by one using following commands.
# pvs
# vgs
# lvs

I’m using a virtual machine that has a 8GB hard disk at the moment. We can verify this with the fdisk command:

I will power off this machine and extend the size of the harddisk in VMWare to 2GB:



For adding a new PV we have to use fdisk to create the LVM partition.
# fdisk /dev/sda

- To Create new partition Press n.
- Choose primary partition use p.
- Choose which number of partition to be selected to create the primary partition.
- Press 1 if any other disk available.
- Change the type using t
- Type 8e to change the partition type to Linux LVM.
- Use p to print the create partition ( here we have not used the option).
- Press w to write the changes
List and check the partition we have created using fdisk. The below command
# fdisk -l /dev/sda

Next, Create new PV (Physical Volume ) using following command.
# pvcreate /dev/sda1
verify the pv using below command.
# pvs

Extending a Disk using LVM
For the first time we have created a , now we will extend it
# vgextend vgapps /dev/sda1
Add space to LV
# lvextend -L +1000MB /dev/vgapps/app2-lv

Make this new space available to fileSystem
Here is the basic command for ext4:
# resize2fs /dev/vgapps/app2-lv 3T
You Can use the below command for XFS
# xfs_growfs /dev/vgapps/app2-lv (now check using df -H)