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

Re: [Xen-devel] [PATCH][XEND] Don't call destroy() on exception instart()



Hi Aravindh,

I think that destroy() is need. If a domain creating failed by 
xm start command, it cleans up the unfinished domain. 

If your patch is applied, the unfinished domain is not cleaned 
up as follows. (I'm able to fail the domain creating by giving 
a wrong parameter(vcpus=33).)

# xm new /xen/vm1.conf vcpus=33
Using config file "/xen/vm1.conf".
# xm list
Name                                      ID   Mem VCPUs      State   Time(s)
Domain-0                                   0   942     2     r-----     68.1
vm1                                            256    33                 0.0
# xm start vm1
Error: (22, 'Invalid argument')
Usage: xm start <DomainName>

Start a Xend managed domain
  -p, --paused                   Do not unpause domain after starting it    

# xm list
Name                                      ID   Mem VCPUs      State   Time(s)
Domain-0                                   0   942     2     r-----     69.1
vm1                                        1   256    33     ------      0.0


If currently xen-unstable, the unfinished domain is cleaned up 
as follows.

# xm new /xen/vm1.conf vcpus=33
Using config file "/xen/vm1.conf".
# xm list
Name                                      ID   Mem VCPUs      State   Time(s)
Domain-0                                   0   942     2     r-----     67.8
vm1                                            256    33                 0.0
# xm start vm1
Error: (22, 'Invalid argument')
Usage: xm start <DomainName>

Start a Xend managed domain
  -p, --paused                   Do not unpause domain after starting it    

# xm list
Name                                      ID   Mem VCPUs      State   Time(s)
Domain-0                                   0   942     2     r-----     68.7
vm1                                            256    33                 0.0


Best regards,
 Kan

>destroy() is being called on exception in both start() and create(). It
>needs to be called only in create().
>
>Signed-off-by: Aravindh Puthiyaparambil
><aravindh.puthiyaparambil@xxxxxxxxxx>
>
>-------------------------------text/plain-------------------------------
>_______________________________________________
>Xen-devel mailing list
>Xen-devel@xxxxxxxxxxxxxxxxxxx
>http://lists.xensource.com/xen-devel


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.