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

Re: [Xen-devel] domains not shutting down properly - theproblemisback again


  • To: James Harper <james.harper@xxxxxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
  • Date: Fri, 02 Jan 2009 10:28:50 +0000
  • Cc:
  • Delivery-date: Fri, 02 Jan 2009 02:29:14 -0800
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: AclsEUiDJwnrGfQLQ6G5Bsw4GM+wzgAAL2RgAAIdJkkAHEzXYAAA9a8QAAD1UUAACaHcAAABmirxAAAQbpAAARbDWA==
  • Thread-topic: [Xen-devel] domains not shutting down properly - theproblemisback again

On 02/01/2009 10:11, "James Harper" <james.harper@xxxxxxxxxxxxxxxx> wrote:

>> xenstored will not auto-connect to any domain. So since it holds no
>> resources of the domU, it won't impede the domU's destruction.
> 
> Even a domain I create subsequent to restarting xenstored & xend? 'xm
> console' doesn't work in that case so I'm guessing not.

No. I'd be a bit surprised if you could create a domain without a wotrking
dom0 ring connection to xenstored though.

> I have previously logged xenstored_domain.c:domain_cleanup() - it never
> gets called during the domain crashing or being shut down. I think the
> action of creating another domain (or an explicit 'xm destroy') results
> in domain_cleanup() getting called somewhere along the way, which mostly
> cleans up the domain but obviously leaves a few pages and an event
> channel lying around (as revealed by 'xm debug q' and 'lsevtchn').

As long as domain_cleanup() gets called at some point it should see the
dying domU has dominfo.dying and then release resources.

> I guess I'll start adding some logs to domain.c...

Good idea. Maybe something is going wrong in domain_kill(). That will be
called by the DOMCTL_destroydomain hypercall, which should be triggered by
'xm destroy'. Note the hypercall is preemptable, requiring a loop on EAGAIN
in libxenctrl, to make sure it completes its work. The notification on
VIRQ_DOM_EXC is near the end of the function.

 -- Keir



_______________________________________________
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®.