[Libvirt-cim] [PATCH] Add state transition poll to DestroySystem() call

Kaitlin Rupert kaitlin at linux.vnet.ibm.com
Wed Jul 2 19:36:51 UTC 2008


Dan Smith wrote:
> KR> # HG changeset patch
> KR> # User Kaitlin Rupert <karupert at us.ibm.com>
> KR> # Date 1214850941 25200
> KR> # Node ID 98e6e7b6160be701c4124cb04eef9c893fdfaa1d
> KR> # Parent  b123b6b1fb08c3ab956f1c33801e743e082192b9
> KR> Add state transition poll to DestroySystem() call.
> 
> Sorry for the delay here...
> 
> KR> +#define STATE_TRANSITION_TIMEOUT 120
> 
> First off, 120 seconds is sure to be longer than the CIM timeout, so
> if the call really lasts this long, the client will get a timeout.  I
> think it's probably reasonable to expect that after a destroy(), the
> undefine() would happen before the domain could really be pulled
> offline.  However, 120 seconds should be considered "something is
> wrong and the domain isn't going away" IMHO.
> 
> If you think that 120 seconds is necessary (and reasonable), then we
> need to check for online-ness, and start a job to do this in that case.

I did some more testing, and adding the additional 
virDomainLookupByName() (to handle the case where the domain was created 
using virsh/virt-manager without being defined first) slows things down 
enough to prevent the issue I was seeing.

I'm going to resubmit with the loop removed.  And then I'll do some 
further testing with a system under load to see what happens.
-- 
Kaitlin Rupert
IBM Linux Technology Center
kaitlin at linux.vnet.ibm.com




More information about the Libvirt-cim mailing list