BlockDev.LVMLVdata

Fields

Name

Type

Access

Description

attr

str

r/w

attributes of the LV

copy_percent

int

r/w

synchronization percentage of a mirrored logical volume

data_lv

str

r/w

data LV of the LV (for thin and cache pools)

data_lvs

[str]

r/w

list of data sub-LVs this LV (for raids, etc).

data_percent

int

r/w

available data space in a thin pool

lv_name

str

r/w

name of the LV

lv_tags

[str]

r/w

list of LVM tags for this LV

metadata_lv

str

r/w

metadata LV of the LV (for thin and cache pools)

metadata_lvs

[str]

r/w

list of metadata sub-LVS for this LV (for raids, etc).

metadata_percent

int

r/w

available metadata space in a thin pool

move_pv

str

r/w

source physical volume of a temporary logical volume created with the pvmove command

origin

str

r/w

origin of the LV (for snapshots, etc.)

pool_lv

str

r/w

pool LV of the LV (for thin and cached LVs)

roles

str

r/w

comma separated list of this LV’s roles

segs

[BlockDev.LVMSEGdata]

r/w

The segments of this LV.

segtype

str

r/w

segment type of the LV

size

int

r/w

size of the LV

uuid

str

r/w

UUID of the LV

vg_name

str

r/w

name of the VG the LV belongs to

Methods

None

Details

class BlockDev.LVMLVdata

The segs, data_lvs, and metadata_lvs fields are only filled by a call to BlockDev.lvm_lvinfo_tree or BlockDev.lvm_lvs_tree. They are all None normally. If they are filled, they follow these rules:

A LV is either stored directly on physical volumes, or is made up of sub-LVs. If it is stored on PVs, the segs list is non-empty and the data_lvs and metadata_lvs fields are both None. If it is made up of sub-LVs, then segs is None, data_lvs is non-empty and metadata_lvs might or might not be empty but is non-None. The sub-LVs contained in data_lv and metadata_lv are always included in data_lvs and metadata_lvs, respectively.

For a partial LV, the segs list might not be complete; i.e., the sum of the sizes of the listed segments might not be equal to the size reported for the LV itself.

Also, the order of entries in segs must be assumed to be random; it does not correspond to the order of segments in the logical volume itself.