LVM: Layers of Abstraction
LVM: Layers of Abstraction
7h 28m

In this course, you will learn how to install a Linux system and connect to it, whether that be on Mac or Windows.


As I said at the beginning of this lesson. The logical volume manager introduces extra layers of abstraction between the storage devices and the file systems placed on those storage devices. The first layer of abstraction are physical volumes. These are storage devices that are used by LVM. The name is a bit of a legacy name though. To be clear, these storage devices do not have to be physical. They just have to be made available to the Linux operating system. In other words, as long as Linux sees the device as a block storage device it can be used as a physical volume, also known as a PV, physical hard drives, iSCSI devices, SanDisks, and so on can be PVs. You can allocate an entire storage device as a PV or you can partition a storage device and use just that one partition as a PV.

The next layer of abstraction is the volume group. A volume group is made up of one or more physical volumes. You can think of a volume group as a pool of storage. If you want to increase the size of the pool you simply add more PVs. Keep in mind that you can have different types of storage in the same volume group if you want. For example, you could have some PVs that are backed by hard disks and other PVs that are backed by SanDisks. We'll talk about how this can come in handy when performing data migrations later in this lesson.

The next layer of abstraction is the logical volume layer. Logical volumes are created from a volume group, file systems are then created on top of those logical volumes. Without LVM, you would create a file system on a disc partition but with LVM you create a file system on a logical volume. As long as there is free space in the volume group logical volumes can be extended. You can also shrink logical volumes to reclaim unused space if you want. But typically in practice you'll find yourself extending logical volumes.

About the Author
Learning Paths

A world-leading tech and digital skills organization, we help many of the world’s leading companies to build their tech and digital capabilities via our range of world-class training courses, reskilling bootcamps, work-based learning programs, and apprenticeships. We also create bespoke solutions, blending elements to meet specific client needs.