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

Re: [Xen-devel] question about reboot VM

On Mon, Mar 26, 2007 at 02:12:33PM +0800, tgh wrote:

> hi
> I try to understand the"xm reboot" for vm, but confused about the python
> code
> I could not find which function or code in C language is called by the
> python when rebooting

At the client (xm) the code is in xen/xm/shutdown.py.  This just sends simple
messages to Xend (the server).  In Xend there is some marshalling, but
eventually the call pops out in xen/xend/XendDomainInfo.py:shutdown, with the
reason set to "reboot".  This makes a request to the domain to shut itself
down, and the shutdown the proceeds asynchronously.

When the domain finally shuts down, a watch is fired which comes into
XendDomainInfo.refreshShutdown, and Xend handles the cleanup and reboot from

There is no C code explicitly about rebooting -- this is handled by Xend as a
cleanup of one domain, and creation of a new one in its place.



Xen-devel mailing list



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