Top |
Activate (IN a{sv} options, OUT o result); Deactivate (IN a{sv} options); Delete (IN a{sv} options); Rename (IN s new_name, IN a{sv} options, OUT o result); Resize (IN t new_size, IN a{sv} options); Repair (IN ao pvs, IN a{sv} options); CreateSnapshot (IN s name, IN t size, IN a{sv} options, OUT o result); CacheAttach (IN s cache_name, IN a{sv} options); CacheSplit (IN a{sv} options); CacheDetach (IN a{sv} options);
VolumeGroup readable o Name readable s Active readable b UUID readable s Size readable t DataAllocatedRatio readable d MetadataAllocatedRatio readable d Type readable s Layout readable s Structure readable a{sv} SyncRatio readable d ThinPool readable o Origin readable o ChildConfiguration readable a(sa{sv}) BlockDevice readable o
Objects with this interface represent logical volumes in a volume group. Active logical volumes are associated with a block device, which link back to the logical volume object via their "LogicalVolume" property.
Logical volume objects are children of their volume group object, and also link to it via the #VolumeGroup property.
Since 2.0.0
Activate (IN a{sv} options, OUT o result);
Activate this logical volume, which makes it appear as a block device in the system.
Non-thin snapshots are always activated and deactivated together with their origins.
No additional options are currently defined.
|
Additional options. |
|
The UDisks2 object path of the block device. |
Since 2.0.0
Deactivate (IN a{sv} options);
Deactivate this logical volume, which makes its block device disappear.
Non-thin snapshots are always activated and deactivated together with their origins.
No additional options are currently defined.
|
Additional options. |
Since 2.0.0
Delete (IN a{sv} options);
Delete this logical volume.
If there are any non-thin snapshots of this logical volume, they will be deleted as well.
If this is a thin pool, all its contained thin volumes will be deleted as well.
If the option tear-down
is set to
TRUE
, then the logical volume and all its children will be
cleaned up before deletion. This cleanup consists of
removing entries from /etc/fstab and /etc/crypttab, and
locking of encrypted block devices. Entries in /etc/fstab
and /etc/crypttab that have been created with the
'track-parents' options to AddConfigurationItem will be
removed even if their block device is currently unavailable.
|
Additional options. |
Since 2.0.0
Rename (IN s new_name, IN a{sv} options, OUT o result);
Rename this logical volume. This might cause the logical volume object to disappear from D-Bus and reappear with a different path.
No additional options are currently defined.
|
The new name. |
|
Additional options. |
|
The new object path. |
Since 2.0.0
Resize (IN t new_size, IN a{sv} options);
Resize this logical volume.
Additional options:
resize_fsys (b): Whether to resize the filesystem on the logical volume as well. Default to 'false'.
force (b): Whether to force the resize even if it might destroy data.
pvs (ao): A list of physical volumes to allocate more space from.
|
The new size, in bytes. |
|
Additional options. |
Since 2.0.0
Repair (IN ao pvs, IN a{sv} options);
Attempt a repair of this logical volume after it has lost some physical volumes. Space is allocated from the given physical volumes as needed. A empty list means to allocate from all physical volumes.
No additional options are currently defined.
|
A list of physical volumes to use for the repair. |
|
Additional options. |
Since 2.10.0
CreateSnapshot (IN s name, IN t size, IN a{sv} options, OUT o result);
Create a snapshot of this logical volume.
When creating a snapshot of a non-thin volume, a non-zero size must be specified. A non-thin snapshot is created in this case.
When creating a snapshot of a thin volume, specifying a size
of zero will create a thin snapshot in the same pool.
When creating a snapshot of a thin volume, specifying a
non-zero size
will create a non-thin snapshot.
No additional options are currently defined.
|
The name of the snapshot. |
|
The size of the backing store for the snapshot, in bytes. |
|
Additional options. |
|
|
Since 2.0.0
CacheAttach (IN s cache_name, IN a{sv} options);
Creates cache LV. Logical volume which name is provided, will be formatted, converted to cache type and attached to origin logical volume as a cache pool LV. Logical volumes must be in the same volume group.
No additional options are currently defined.
|
The name of an existing volume. |
|
Additional options. |
Since 2.3.0
CacheSplit (IN a{sv} options);
Splits Cache LV to Cache pool LV and Origin LV, not afeecting its content.
No additional options are currently defined.
|
Additional options. |
Since 2.3.0
VolumeGroup readable o
The path of the volume group object that this logical volume belongs to.
Since 2.0.0
Name readable s
The name of this logical volume, as it is known to LVM2.
Since 2.0.0
UUID readable s
The UUID of this logical volume. It is guaranteed to be unique within the group, but it might change over time.
Since 2.0.0
Size readable t
The total size of this logical volume in bytes, including the size of the metadata.
Since 2.0.0
DataAllocatedRatio readable d
For a thin pool or a non-thin snapshot, indicates how full
the area for storing data is. A value of 1.0 corresponds to
100.
Since 2.0.0
MetadataAllocatedRatio readable d
For a thin pool or a non-thin snapshot, indicates how full
the area for storing meta data is. A value of 1.0
corresponds to 100.
Since 2.0.0
Type readable s
The general type of a logical volume. One of "block", "pool" or "vdopool". More types might be defined in the future.
A volume of type "block" can be used as a block device. A volume of type "pool" can be used to create thin volumes. A volume of type "vdopool" is the internal pool for the VDO logical volume device.
Since 2.0.0
Layout readable s
The layout of this logical volume, such as "linear", "raid5", etc.
Since 2.10.0
Structure readable a{sv}
The detailed structure of how this logical volume is stored on physical volumes.
The following fields are present:
- name (s): The name of the logical volume. - type (s): The layout type of the logical volume. - size (t): The size in bytes of the logical volume.
If the logical volume is stored directly on physical volumes, this field is present as well:
- segs (a(tto)): Information about the segments of the logical volume (see below).
A segment is represented by a "(tto)" tuple, where the fields have these meanings:
- (t): The start of this segement on the physical volume, in bytes. - (t): The size of the segment, in bytes. - (o): The path of the org.freedesktop.UDisks.Block object of the physical volume.
For a healthy logical volume, the sizes of its segments will add up exactly to its own size. If a volume group has lost some physical volumes, a affected logical volume will have a list of segments here that do not add up to its full size.
If the logical volume is stored on other logical volumes, these fields are present in the "Structure" value instead of "segs":
- data (aa{sv}): The list of "Structure" objects for the data sub-volumes. - metadata (aa{sv}): The list of "Structure" objects for the metadata sub-volumes.
For example, a minimal "raid5" layout will have three "data" sub-volumes (and three parallel "metadata" sub-volumes), which are the three stripes of the RAID configuration. Each of those sub-volume will be stored directly on physical volumes and one can inspect the "segs" field of those to figure out how many are damaged. From that, one can deduce whether the RAID is degraded (exactly one damaged), or has lost data (more than one damaged).
Since 2.10.0
SyncRatio readable d
How far along the logical volume is with resynchronizing. A value of 1.0 corresponds to fully synchronized and indicates that no operation is in progress. This is only relevant for logical volumes with some redundancy, like "raid1" or "raid5".
Since 2.10.0
ThinPool readable o
For a thin volume, the object path of its pool.
Since 2.0.0
ChildConfiguration readable a(sa{sv})
Configuration items belonging to the
block device of this logical volume and its children. This is also valid when this logical volume is not currently active and there is no block device for it. It works via the 'track-parents' options of AddConfigurationItem(), which see.
Since 2.0.0