I recently ran out of storage space on my development server that has both Hybris and Adobe Experience Manager (AEM) installed.
A quick df -h command confirmed my suspicion:
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg_system-opt 7.0G 7.0G 20K 100% /opt
After installing a new disk. the operating system identified this new disk as /dev/sdb. Since this is a brand new disk, no partitions exist.
The following are the steps required to add additional space to a Red Hat Enterprise Linux Server Volume Group.
1. Convert this new disk into a physical volume:
# pvcreate /dev/sdb
Physical volume “/dev/sdb” successfully created
2. Add the physical volume to the volume group being used (vg_system)
# vgextend vg_system /dev/sdb
Volume group “vg_system” successfully extended
3. Run the lvdisplay command to display existing logical volume properties, and grab the LV Path that requires more storage space.
4. If lvdisplay isn’t installed, run the following yum install command to install lvdisplay.
# yum install system-config-lvm
3. Increase the size of the logical volume to 130GB (select the appropriate size for your environment)
# lvextend -L+130G /dev/vg_system/opt
4. Finally, resize the file system to use the additional space.
# xfs_growfs /dev/vg_system/opt
5. For good measure, check if the space is available by performing the df -h command again.
# df -h
The 130GB has been successfully allocated to the RHEL Volume Group, and this concludes this tutorial.