Logical Volume Management is the next step after dealing with Linux VG management; it allows groups to be separated into logical areas that can store data based on the requirements of the administrator.
In particular, LVM is used to abstract away the existence of specific physical disks and partitions into “logical” groups that can be managed with less concern for their physical locations and sizes.
The building blocks of LVM are:
- Physical volumes
- This is the actual storage unit, such as HDDs, SSDs
- It can also be a specific partition inside a drive
- Volume groups
- Volume groups are pools of space created by combining physical volumes
- This is what we allocate space from
- Logical Volumes
- Logical volumes are space with specific file systems and mounts
- In a way, they are like partitions, but independent of a specific physical drive
- This allows the volume to expand into other drives as necessary, and we can therefore address multiple drives as a single storage unit not entirely unlike RAID, but without stripping or any of the RAID-specific usage.
Logical Volumes
| Command | Description |
|---|---|
lvcreate | This is used to make a logical volume from an existing volume group, assigning a name and specifying a desired size |
lvdisplay | Displays information about a specific logical volume |
lvs | Summaries all logical volumes |
lvchange | Used to changed status or attributes of a logical volume (such as activating, etc.) |
lvresize | Used to increase or decrease the size of a logical volume |
lvextend | This is a specific version of lvresize that only extends the data by certain amounts |
lvremove | Delete a logical volume from the system |