How To Increase XFS File System LVM In Linux Step by Step Guide

XFS Stands for eXtended File System. If already there are a few file systems available for Linux Operating system. Then why XFS.? Extended File System is Highly Scalable, High-Performance file system which was originally developed/designed by Silicon Graphics. In RHEL 7 default file system is XFS. In this Article we are going to see How To Increase XFS File system LVM In RHEL 7/Centos 7.

XFS File System Features

  • Quick Crash Recovery
  • XFS Supports Defragmentation
  • Support Quick Backup and Restore
  • Extent Based Allocation
  • Delayed Allocation ( To Improve Performance Optimization with not guaranteed on-disk until fsync() call)
  • Space Pre-allocation
  • Quota Journaling

The main disadvantage comparatively with EXT 4 is We can’t Shrink/Reduce LVM Partition size with XFS File system. Maybe Advantage in some cases.

How To Increase XFS File System LVM In Linux Step by Step Guide

First Step Let’s go ahead and create New LVM partition with low disk space. Use fdisk utility to create

# fdisk /dev/sdb
Create XFS LVM RHEL7

Create Partition RHEL7

Save and Exit from fdisk utility

:wq

Update Kernel about new partition creation

# partprobe /dev/sdb
Creating XFS LVM in RHEL 7

Creating XFS LVM in RHEL 7

Simple steps to Create LVM Partition within 2.5TB in size

# pvcreate <Valid Partition Name>
# vgcreate <VG NAME><PV NAME>
# lvcreate -n <LV NAME> -L <SIZE M|G|T> <VG NAME>
# mkfs.xfs <LV PATH>

Let’s mount and see how the partition comes online 

Mounting XFS LVM

Mounting XFS LVM

LVM Partition is mounted successfully and ready to increase it’s size from 1G to 3G

# lvextend -L +2G /dev/VG1/lv_xfs0 -r
XFS LVM Extend

XFS LVM Extend

If you use -r option which means no need to run resize command again

# xfs_growfs <Mount Point>

Other Options to Extend XFS LVM

# lvextend -L +1G /dev/VG1/lv_xfs0 /dev/sdc1

Did you created a Volume Group using Multiple Physical Volumes then if you want to increase particular LVM size by mentioning PV name (use above command)

Extend the Logical Volume using Physical extend values Or physical extent numbers

# lvextend -l <extent value> <LVM Path>

That’s it about How To Increase XFS File System LVM. 

I Hope you enjoyed reading…!! Your Feedback is More important for us.

Related Articles 

Linux Learners Guide

HowTo Reduce Logical Volume

Linux Tutorial

More Details

Thanks for your wonderful Support and Encouragement

blank

Ravi Kumar Ankam

My Name is ARK. Expert in grasping any new technology, Interested in Sharing the knowledge. Learn more & Earn More

Leave a Reply

Your email address will not be published. Required fields are marked *