diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-domain.h index b929877643..de2456812c 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -5070,6 +5070,7 @@ typedef enum { VIR_DOMAIN_GUEST_INFO_TIMEZONE = (1 << 2), /* return timezone information */ VIR_DOMAIN_GUEST_INFO_HOSTNAME = (1 << 3), /* return hostname information */ VIR_DOMAIN_GUEST_INFO_FILESYSTEM = (1 << 4), /* return filesystem information */ + VIR_DOMAIN_GUEST_INFO_DISKS = (1 << 5), /* return disks information */ } virDomainGuestInfoTypes; int virDomainGetGuestInfo(virDomainPtr domain, diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index 0d0041f983..35e95e5395 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -12341,6 +12341,23 @@ virDomainSetVcpu(virDomainPtr domain, * "fs..disk..serial" - the serial number of the disk * "fs..disk..device" - the device node of the disk * + * VIR_DOMAIN_GUEST_INFO_DISKS: + * Returns information about the disks within the domain. The typed + * parameter keys are in this format: + * + * "disks.count" - the number of disks defined on this domain + * as an unsigned int + * "disks..name" - device node (Linux) or device UNC (Windows) + * "disks..partition" - whether this is a partition or disk + * "disks..dependencies.count" - the number of device dependencies + * e.g. for LVs of the LVM this will + * hold the list of PVs, for LUKS encrypted volume this will + * contain the disk where the volume is placed. (Linux) + * "disks..dependencies..name" - a dependency + * "disks..alias" - the device alias of the disk (e.g. sda) + * "disks..guest_alias" - optional alias assigned to the disk, on Linux + * this is a name assigned by device mapper + * * VIR_DOMAIN_GUEST_INFO_HOSTNAME: * Returns information about the hostname of the domain. The typed * parameter keys are in this format: