What Is Linux LVM (Logical Volume Management)? – POFTUT

What Is Linux LVM (Logical Volume Management)?

LVM or Logical Volume Management used to create, manage and delete logical volumes in Linux operating systems. LVM provides RAID like architectures for disk drives. We can create single logical volume from multiple physical disks.


LVM consist of 3 main concepts:

  • Physical  Volumes
  • Volume Groups
  • Logical Volumes

Let me explain in a simple manner. By adding one or more than one Physical Volume we will create a Volume Group and than we can create one or more Logical Volume from a Volume Group. As we can see LVM provides some abstraction for disk and partition management.

Physical Volume

Physical Volume is a physical disk or a partition which is the source of the storage. We can also use RAID disks or partitions. Physical volume will be added into Volume Groups and this will add more disk space to the Volume Groups.

Volume Groups

Volume Groups a logical disk where one or more Physical Disk will participate. This will create enough disk space in order to create Logical Volumes.Volume groups provides flexibility like adding, removing physical volume , resizing Logical Volume on the fly.

Volume Groups

Volume Groups

Logical Volume

Logical Volumes are the virtual disk or partitions created from a Volume Groups. We can resize and snapshot the Logical Volume without any interruption.

Volume Groups

Volume Groups

Create Volume Group

We will start by creating a Volume Group. First we will initialize the physical disk for the Volume Group. We will use pvcreate command by providing the disk device.

After the disk sdb1 initialized we will create a volume Group named myvg with the vgcreate command

Create Logical Volume

Than we will create Logical Volume with the lvcreate command by providing the Volume Group and the Logical Volume name. In this example we will use -n option for Logical Volume Name and -L for setting the size of the Logical Volume. The Logical Volume size will be 5GB .

Resize Partition

LVM provides a lot of features against standard disk usage. We can resize the Logical Volume or partition on the fly without unmounting or restarting the system. This operation also called extending where we will use lvextend command. -L option is used to specify how much disk space will be added .

Leave a Reply

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

Enjoy this blog? Please spread the word :)