Hands-on Lab·Red Hat Certified System Administrator
LVM Logical Volumes
The top LVM layer and the one you actually put a filesystem on. Both ways of specifying size are used here, including the percentage forms that save arithmetic under time pressure, and the rounding LVM performs is shown announcing itself.
Local Storage Guide 34 of 67 Intermediate
- OSRHEL 10.0
- Kernel6.12.0-55.9.1.el10_0
- dnf4.20.0
- Flatpak1.16.0
- TimeAbout 12 min
A logical volume appears under two paths: /dev/<vg>/<lv> and /dev/mapper/<vg>-<lv>. Both are symlinks to the same /dev/dm-N. Either works in /etc/fstab, though a UUID is better still - see guide 35.
| Server Name | IP Address | OS | Roles | CPU | RAM | HDD |
|---|---|---|---|---|---|---|
| RHCSA-A01 | 192.168.0.31 | RHEL 10.0 | Practice node (graded) - spare /dev/sda | 2 Core | 4 GB | 50 GB + 15 GB |
This guide includes
Use this for the top LVM layer, the one you actually put a filesystem on. This matters because there are two ways to state a size - and both round to whole extents, which is where the number you asked for stops matching.
- creating logical volumes
- finding where the device actually appears
- using the two ways to state a size, and meeting the rounding
- removing them again
Before you start
- A volume group with free space -
guide 33builds one. - Every destructive command on this page names a
/dev/sdadevice. On this machine the operating system is entirely on/dev/sdb. Check yours before running anything here - the first step shows how.
-
Creating them
-
Where the device appears
-
Two ways to say how big, and the rounding
-
Removing them