Chapter 2. The LVM Logical Volume Manager
This chapter provides a summary of the features of the LVM logical volume manager that are new for the initial and subsequent releases of Red Hat Enterprise Linux 6. Following that, this chapter provides a high-level overview of the components of the Logical Volume Manager (LVM).
2.1. New and Changed Features
This section lists new and changed features of the LVM logical volume manager that are included with the initial and subsequent releases of Red Hat Enterprise Linux 6.
2.1.1. New and Changed Features for Red Hat Enterprise Linux 6.0
Red Hat Enterprise Linux 6.0 includes the following documentation and feature updates and changes.
- You can define how a mirrored logical volume behaves in the event of a device failure with the
mirror_image_fault_policy
andmirror_log_fault_policy
parameters in theactivation
section of thelvm.conf
file. When this parameter is set toremove
, the system attempts to remove the faulty device and run without it. When this parameter is set toallocate
, the system attempts to remove the faulty device and tries to allocate space on a new device to be a replacement for the failed device; this policy acts like theremove
policy if no suitable device and space can be allocated for the replacement. For information on the LVM mirror failure policies, see Section 5.4.3.1, “Mirrored Logical Volume Failure Policy”. - For the Red Hat Enterprise Linux 6 release, the Linux I/O stack has been enhanced to process vendor-provided I/O limit information. This allows storage management tools, including LVM, to optimize data placement and access. This support can be disabled by changing the default values of
data_alignment_detection
anddata_alignment_offset_detection
in thelvm.conf
file, although disabling this support is not recommended.For information on data alignment in LVM as well as information on changing the default values ofdata_alignment_detection
anddata_alignment_offset_detection
, see the inline documentation for the/etc/lvm/lvm.conf
file, which is also documented in Appendix B, The LVM Configuration Files. For general information on support for the I/O Stack and I/O limits in Red Hat Enterprise Linux 6, see the Storage Administration Guide. - In Red Hat Enterprise Linux 6, the Device Mapper provides direct support for
udev
integration. This synchronizes the Device Mapper with alludev
processing related to Device Mapper devices, including LVM devices. For information on Device Mapper support for theudev
device manager, see Section A.3, “Device Mapper Support for the udev Device Manager”. - For the Red Hat Enterprise Linux 6 release, you can use the
lvconvert --repair
command to repair a mirror after disk failure. This brings the mirror back into a consistent state. For information on thelvconvert --repair
command, see Section 5.4.3.3, “Repairing a Mirrored Logical Device”. - As of the Red Hat Enterprise Linux 6 release, you can use the
--merge
option of thelvconvert
command to merge a snapshot into its origin volume. For information on merging snapshots, see Section 5.4.8, “Merging Snapshot Volumes”. - As of the Red Hat Enterprise Linux 6 release, you can use the
--splitmirrors
argument of thelvconvert
command to split off a redundant image of a mirrored logical volume to form a new logical volume. For information on using this option, see Section 5.4.3.2, “Splitting Off a Redundant Image of a Mirrored Logical Volume”. - You can now create a mirror log for a mirrored logical device that is itself mirrored by using the
--mirrorlog mirrored
argument of thelvcreate
command when creating a mirrored logical device. For information on using this option, see Section 5.4.3, “Creating Mirrored Volumes”.
2.1.2. New and Changed Features for Red Hat Enterprise Linux 6.1
Red Hat Enterprise Linux 6.1 includes the following documentation and feature updates and changes.
- The Red Hat Enterprise Linux 6.1 release supports the creation of snapshot logical volumes of mirrored logical volumes. You create a snapshot of a mirrored volume just as you would create a snapshot of a linear or striped logical volume. For information on creating snapshot volumes, see Section 5.4.5, “Creating Snapshot Volumes”.
- When extending an LVM volume, you can now use the
--alloc cling
option of thelvextend
command to specify thecling
allocation policy. This policy will choose space on the same physical volumes as the last segment of the existing logical volume. If there is insufficient space on the physical volumes and a list of tags is defined in thelvm.conf
file, LVM will check whether any of the tags are attached to the physical volumes and seek to match those physical volume tags between existing extents and new extents.For information on extending LVM mirrored volumes with the--alloc cling
option of thelvextend
command, see Section 5.4.14.3, “Extending a Logical Volume with thecling
Allocation Policy”. - You can now specify multiple
--addtag
and--deltag
arguments within a singlepvchange
,vgchange
, orlvchange
command. For information on adding and removing object tags, see Section D.1, “Adding and Removing Object Tags”. - The list of allowed characters in LVM object tags has been extended, and tags can contain the "/", "=", "!", ":", "#", and "&" characters. For information on LVM object tags, see Appendix D, LVM Object Tags.
- You can now combine RAID0 (striping) and RAID1 (mirroring) in a single logical volume. Creating a logical volume while simultaneously specifying the number of mirrors (
--mirrors X
) and the number of stripes (--stripes Y
) results in a mirror device whose constituent devices are striped. For information on creating mirrored logical volumes, see Section 5.4.3, “Creating Mirrored Volumes”. - As of the Red Hat Enterprise Linux 6.1 release, if you need to create a consistent backup of data on a clustered logical volume you can activate the volume exclusively and then create the snapshot. For information on activating logical volumes exclusively on one node, see Section 5.7, “Activating Logical Volumes on Individual Nodes in a Cluster”.
2.1.3. New and Changed Features for Red Hat Enterprise Linux 6.2
Red Hat Enterprise Linux 6.2 includes the following documentation and feature updates and changes.
- The Red Hat Enterprise Linux 6.2 release supports the
issue_discards
parameter in thelvm.conf
configuration file. When this parameter is set, LVM will issue discards to a logical volume's underlying physical volumes when the logical volume is no longer using the space on the physical volumes. For information on this parameter, see the inline documentation for the/etc/lvm/lvm.conf
file, which is also documented in Appendix B, The LVM Configuration Files.
2.1.4. New and Changed Features for Red Hat Enterprise Linux 6.3
Red Hat Enterprise Linux 6.3 includes the following documentation and feature updates and changes.
- As of the Red Hat Enterprise Linux 6.3 release, LVM supports RAID4/5/6 and a new implementation of mirroring. For information on RAID logical volumes, see Section 5.4.16, “RAID Logical Volumes”.
- When you are creating a new mirror that does not need to be revived, you can specify the
--nosync
argument to indicate that an initial synchronization from the first device is not required. For information on creating mirrored volumes, see Section 5.4.3, “Creating Mirrored Volumes”. - This manual now documents the snapshot
autoextend
feature. For information on creating snapshot volumes, see Section 5.4.5, “Creating Snapshot Volumes”.
2.1.5. New and Changed Features for Red Hat Enterprise Linux 6.4
Red Hat Enterprise Linux 6.4 includes the following documentation and feature updates and changes.
- Logical volumes can now be thinly provisioned. This allows you to create logical volumes that are larger than the available extents. Using thin provisioning, you can manage a storage pool of free space, known as a thin pool, to be allocated to an arbitrary number of devices when needed by applications. You can then create devices that can be bound to the thin pool for later allocation when an application actually writes to the logical volume. The thin pool can be expanded dynamically when needed for cost-effective allocation of storage space.For general information on thinly-provisioned logical volumes, see Section 3.3.5, “Thinly-Provisioned Logical Volumes (Thin Volumes)”. For information on creating thin volumes, see Section 5.4.4, “Creating Thinly-Provisioned Logical Volumes”.
- The Red Hat Enterprise Linux release 6.4 version of LVM provides support for thinly-provisioned snapshot volumes. Thin snapshot volumes allow many virtual devices to be stored on the same data volume. This simplifies administration and allows for the sharing of data between snapshot volumes.For general information on thinly-provisioned snapshot volumes, see Section 3.3.7, “Thinly-Provisioned Snapshot Volumes”. For information on creating thin snapshot volumes, see Section 5.4.6, “Creating Thinly-Provisioned Snapshot Volumes”.
- This document includes a new section detailing LVM allocation policy, Section 5.3.2, “LVM Allocation”.
- LVM now provides support for
raid10
logical volumes. For information on RAID logical volumes, see Section 5.4.16, “RAID Logical Volumes”. - The LVM metadata daemon,
lvmetad
, is supported in Red Hat Enterprise Linux release 6.4. Enabling this daemon reduces the amount of scanning on systems with many block devices. Thelvmetad
daemon is not currently supported across the nodes of a cluster, and requires that the locking type be local file-based locking.For information on the metadata daemon, see Section 4.6, “The Metadata Daemon (lvmetad)”.
In addition, small technical corrections and clarifications have been made throughout the document.
2.1.6. New and Changed Features for Red Hat Enterprise Linux 6.5
Red Hat Enterprise Linux 6.5 includes the following documentation and feature updates and changes.
- You can control I/O operations on a RAID1 logical volume with the
--writemostly
and--writebehind
parameters of thelvchange
command. For information on these parameters, see Section 5.4.16.11, “Controlling I/O Operations on a RAID1 Logical Volume”. - The
lvchange
command now supports a--refresh
parameter that allows you to restore a transiently failed device without having to reactivate the device. This feature is described in Section 5.4.16.8.1, “The allocate RAID Fault Policy”. - LVM provides scrubbing support for RAID logical volumes. For information on this feature, see Section 5.4.16.10, “Scrubbing a RAID Logical Volume”.
- The fields that the
lvs
command supports have been updated. For information on thelvs
command, see Table 5.4, “lvs Display Fields”. - The
lvchange
command supports the new--maxrecoveryrate
and--minrecoveryrate
parameters, which allow you to control the rate at whichsync
operations are performed. For information on these parameters, see Section 5.4.16.10, “Scrubbing a RAID Logical Volume”. - You can control the rate at which a RAID logical volume is initialized by implementing recovery throttling. You control the rate at which
sync
operations are performed by setting the minimum and maximum I/O rate for those operations with the--minrecoveryrate
and--maxrecoveryrate
options of thelvcreate
command, as described in Section 5.4.16.1, “Creating a RAID Logical Volume”. - You can now create a thinly-provisioned snapshot of a non-thinly-provisioned logical volume. For information on creating these volumes, known as external volumes, see Section 3.3.7, “Thinly-Provisioned Snapshot Volumes”.
In addition, small technical corrections and clarifications have been made throughout the document.
2.1.7. New and Changed Features for Red Hat Enterprise Linux 6.6
Red Hat Enterprise Linux 6.6 includes the following documentation and feature updates and changes.
- The documentation for thinly-provisioned volumes and thinly-provisioned snapshots has been clarified. Additional information about LVM thin provisioning is now provided in the
lvmthin
(7) man page. For general information on thinly-provisioned logical volumes, see Section 3.3.5, “Thinly-Provisioned Logical Volumes (Thin Volumes)”. For information on thinly-provisioned snapshot volumes, see Section 3.3.7, “Thinly-Provisioned Snapshot Volumes”. - This manual now documents the
lvm dumpconfig
command, in Section B.2, “Thelvmconfig
Command”. Note that as of the Red Hat Enterprise Linux 6.8 release, this command was renamedlvmconf
, although the old format continues to work. - This manual now documents LVM profiles, in Section B.3, “LVM Profiles”.
- This manual now documents the
lvm
command in Section 4.7, “Displaying LVM Information with thelvm
Command”. - In the Red Hat Enterprise Linux 6.6 release, you can control activation of thin pool snapshots with the -k and -K options of the
lvcreate
andlvchange
command, as documented in Section 5.4.17, “Controlling Logical Volume Activation”. - This manual documents the
--force
argument of thevgimport
command. This allows you to import volume groups that are missing physical volumes and subsequently run thevgreduce --removemissing
command. For information on thevgimport
command, see Section 5.3.15, “Moving a Volume Group to Another System”.
In addition, small technical corrections and clarifications have been made throughout the document.
2.1.8. New and Changed Features for Red Hat Enterprise Linux 6.7
Red Hat Enterprise Linux 6.7 includes the following documentation and feature updates and changes.
- As of Red Hat Enterprise Linux release 6.7, many LVM processing commands accept the
-S
or--select
option to define selection criteria for those commands. LVM selection criteria are documented in the new appendix Appendix C, LVM Selection Criteria. - This document provides basic procedures for creating cache logical volumes in Section 5.4.7, “Creating LVM Cache Logical Volumes”.
- The troubleshooting chapter of this document includes a new section, Section 7.8, “Duplicate PV Warnings for Multipathed Devices”.
2.1.9. New and Changed Features for Red Hat Enterprise Linux 6.8
Red Hat Enterprise Linux 6.8 includes the following documentation and feature updates and changes.
- When defining selection criteria for LVM commands, you can now specify time values as selection criteria for fields with a field type of
time
. For information on specifying time values as selection criteria, see Section C.3.1, “Specifying Time Values”.