Re: [libvirt] [PATCH 6/7] VMware ESX: Add esxDomainUndefine() based on esxVI_UnregisterVM()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/9/4 Daniel Veillard <veillard@xxxxxxxxxx>:
> On Thu, Sep 03, 2009 at 06:45:54PM +0200, Matthias Bolte wrote:
>> * src/esx/esx_driver.c: add esxDomainUndefine() based on
>>   esxVI_UnregisterVM()
>> * src/esx/esx_vi_methods.[ch]: add esxVI_UnregisterVM()
>
>  Looks fine, there is just that small limitiation
>
> +    if (powerState != esxVI_VirtualMachinePowerState_Suspended &&
> +        powerState != esxVI_VirtualMachinePowerState_PoweredOff) {
> +        ESX_ERROR(domain->conn, VIR_ERR_OPERATION_INVALID,
> +                  "Domain is not suspended or powered off");
> +        goto failure;
>
>  I don't think we have that restriction of non-running domain
> in other drivers, but I think it's fine to error then, just a driver
> specific behaviour.
>

ESX won't let you undefine/unregister a domain that's running, that's
the reason for this check. When the domain is suspended or powered
off, then the complete status of that domain has been written to disk,
so it's save to unregister it.

Matthias

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]