8.6. Historical logical volumes
You can configure the system to track thin snapshot and thin logical volumes that have been removed by enabling the record_lvs_history
metadata option in the lvm.conf
configuration file. This allows you to display a full thin snapshot dependency chain that includes logical volumes that have been removed from the original dependency chain and have become historical logical volumes.
You can configure the system to retain historical volumes for a defined period of time by specifying the retention time, in seconds, with the lvs_history_retention_time
metadata option in the lvm.conf
configuration file.
A historical logical volume retains a simplified representation of the already removed logical volume, including the following reporting fields for the volume:
-
lv_time_removed
: the removal time of the logical volume -
lv_time
: the creation time of the logical volume -
lv_name
: the name of the logical volume -
lv_uuid
: the UUID of the logical volume -
vg_name
: the volume group that contains the logical volume.
A historical logical volume cannot be reactivated.
When you remove a volume, the historical logical volume name acquires a hyphen as a prefix. For example, if you remove the logical volume lvol1
, the name of the historical volume becomes -lvol1
.
Logical Volume Manager (LVM) does not keep historical logical volumes if the volume has no live descendant. This means that if you remove a logical volume at the end of a snapshot chain, the logical volume is not retained as a historical logical volume.
To include historical logical volumes in volume display, you specify the -H|--history
option of an LVM display command. You can display a full thin snapshot dependency chain that includes historical volumes by specifying the lv_full_ancestors
and lv_full_descendants
reporting fields along with the -H
option.