Installation guide
Table Of Contents
- LVM Administrator's Guide
- Table of Contents
- Introduction
- Chapter 1. The LVM Logical Volume Manager
- Chapter 2. LVM Components
- Chapter 3. LVM Administration Overview
- Chapter 4. LVM Administration with CLI Commands
- 1. Using CLI Commands
- 2. Physical Volume Administration
- 3. Volume Group Administration
- 3.1. Creating Volume Groups
- 3.2. Adding Physical Volumes to a Volume Group
- 3.3. Displaying Volume Groups
- 3.4. Scanning Disks for Volume Groups to Build the Cache File
- 3.5. Removing Physical Volumes from a Volume Group
- 3.6. Changing the Parameters of a Volume Group
- 3.7. Activating and Deactivating Volume Groups
- 3.8. Removing Volume Groups
- 3.9. Splitting a Volume Group
- 3.10. Combining Volume Groups
- 3.11. Backing Up Volume Group Metadata
- 3.12. Renaming a Volume Group
- 3.13. Moving a Volume Group to Another System
- 3.14. Recreating a Volume Group Directory
- 4. Logical Volume Administration
- 4.1. Creating Logical Volumes
- 4.2. Persistent Device Numbers
- 4.3. Resizing Logical Volumes
- 4.4. Changing the Parameters of a Logical Volume Group
- 4.5. Renaming Logical Volumes
- 4.6. Removing Logical Volumes
- 4.7. Displaying Logical Volumes
- 4.8. Growing Logical Volumes
- 4.9. Extending a Striped Volume
- 4.10. Shrinking Logical Volumes
- 5. Creating Snapshot Volumes
- 6. Controlling LVM Device Scans with Filters
- 7. Online Data Relocation
- 8. Activating Logical Volumes on Individual Nodes in a Cluster
- 9. Customized Reporting for LVM
- Chapter 5. LVM Configuration Examples
- Chapter 6. LVM Troubleshooting
- Chapter 7. LVM Administration with the LVM GUI
- Appendix A. The Device Mapper
- Appendix B. The LVM Configuration Files
- Appendix C. LVM Object Tags
- Appendix D. LVM Volume Group Metadata
- Index

Argument Header Description
seg_size SSize The size of the segments in the logical volume
seg_start Start Offset of the segment in the logical volume
seg_tags Seg Tags LVM tags attached to the segments of the logical volume
segtype Type The segment type of a logical volume (for example: mirror,
striped, linear)
snap_percent Snap% Current percentage of a snapshot volume that is in use
stripes #Str Number of stripes or mirrors in a logical volume
stripesize
stripe_size
Stripe Unit size of the stripe in a striped logical volume
Table 4.3. lvs Display Fields
The lvs command displays the following fields by default: lv_name, vg_name, lv_attr, lv_size,
origin, snap_percent, move_pv, mirror_log, copy_percent. The default display is sorted by
vg_name and lv_name within the volume group.
# lvs
LV VG Attr LSize Origin Snap% Move Log Copy%
lvol0 new_vg owi-a- 52.00M
newvgsnap1 new_vg swi-a- 8.00M lvol0 0.20
Using the -v argauament with the lvs command adds the following fields to the default display:
seg_count, lv_major, lv_minor, lv_kernel_major, lv_kernel_minor, lv_uuid.
# lvs -v
Finding all logical volumes
LV VG #Seg Attr LSize Maj Min KMaj KMin Origin Snap% Move Copy% Log LV UUID
lvol0 new_vg 1 owi-a- 52.00M -1 -1 253 3 LBy1Tz-sr23-OjsI-LT03-nHLC-y8XW-EhCl78
newvgsnap1 new_vg 1 swi-a- 8.00M -1 -1 253 5 lvol0 0.20 1ye1OU-1cIu-o79k-20h2-ZGF0-qCJm-CfbsIx
You can use the --segments argument of the lvs command to display information with default
columns that emphasize the segment information. When you use the segments argument, the
seg prefix is optional. The lvs --segments command displays the following fields by default:
lv_name, vg_name, lv_attr, stripes, segtype, seg_size. The default display is sorted by vg_name,
lv_name within the volume group, and seg_start within the logical volume. If the logical volumes
were fragmented, the output from this command would show that.
# lvs --segments
LV VG Attr #Str Type SSize
LogVol00 VolGroup00 -wi-ao 1 linear 36.62G
LogVol01 VolGroup00 -wi-ao 1 linear 512.00M
lv vg -wi-a- 1 linear 104.00M
lv vg -wi-a- 1 linear 104.00M
lv vg -wi-a- 1 linear 104.00M
lv vg -wi-a- 1 linear 88.00M
9.2. Object Selection
47