summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2010-03-18 13:48:03 +0000
committerRichard Jones <rjones@redhat.com>2010-03-18 15:21:08 +0000
commit50d2af4f8541a81d047753d7d300804ff649230c (patch)
tree8bc80cd1004314574e9354c2215fd8485f3e3676 /src
parent27e73269d384814eb5f76468f609f7844cb75b0b (diff)
downloadlibguestfs-50d2af4f8541a81d047753d7d300804ff649230c.tar.gz
libguestfs-50d2af4f8541a81d047753d7d300804ff649230c.tar.xz
libguestfs-50d2af4f8541a81d047753d7d300804ff649230c.zip
New APIs: Query the relationship between LVM objects.
These calls allow you to query the relationship between LVM objects, for example, which PVs contain a VG, or which LVs are contained in a VG. See the example / test program 'regressions/test-lvm-mapping.pl' for an example of how to do this from Perl.
Diffstat (limited to 'src')
-rw-r--r--src/MAX_PROC_NR2
-rwxr-xr-xsrc/generator.ml42
2 files changed, 43 insertions, 1 deletions
diff --git a/src/MAX_PROC_NR b/src/MAX_PROC_NR
index 7b473380..f4146713 100644
--- a/src/MAX_PROC_NR
+++ b/src/MAX_PROC_NR
@@ -1 +1 @@
-221
+226
diff --git a/src/generator.ml b/src/generator.ml
index 83f307b1..fdd228eb 100755
--- a/src/generator.ml
+++ b/src/generator.ml
@@ -4290,6 +4290,48 @@ contained in a Linux initrd or initramfs image:
See also C<guestfs_initrd_list>.");
+ ("pvuuid", (RString "uuid", [Device "device"]), 222, [],
+ [],
+ "get the UUID of a physical volume",
+ "\
+This command returns the UUID of the LVM PV C<device>.");
+
+ ("vguuid", (RString "uuid", [String "vgname"]), 223, [],
+ [],
+ "get the UUID of a volume group",
+ "\
+This command returns the UUID of the LVM VG named C<vgname>.");
+
+ ("lvuuid", (RString "uuid", [Device "device"]), 224, [],
+ [],
+ "get the UUID of a logical volume",
+ "\
+This command returns the UUID of the LVM LV C<device>.");
+
+ ("vgpvuuids", (RStringList "uuids", [String "vgname"]), 225, [],
+ [],
+ "get the PV UUIDs containing the volume group",
+ "\
+Given a VG called C<vgname>, this returns the UUIDs of all
+the physical volumes that this volume group resides on.
+
+You can use this along with C<guestfs_pvs> and C<guestfs_pvuuid>
+calls to associate physical volumes and volume groups.
+
+See also C<guestfs_vglvuuids>.");
+
+ ("vglvuuids", (RStringList "uuids", [String "vgname"]), 226, [],
+ [],
+ "get the LV UUIDs of all LVs in the volume group",
+ "\
+Given a VG called C<vgname>, this returns the UUIDs of all
+the logical volumes created in this volume group.
+
+You can use this along with C<guestfs_lvs> and C<guestfs_lvuuid>
+calls to associate logical volumes and volume groups.
+
+See also C<guestfs_vgpvuuids>.");
+
]
let all_functions = non_daemon_functions @ daemon_functions