|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] run a script before creating domain
On Fri, Jan 13, 2006 at 11:57:48AM +1100, James Harper wrote:
> I seem to be living in constant fear of starting the same domain on more
> than one machine at once. As a way of preventing this, I'd like to be
> able to have a script execute as part of an 'xm create' that runs before
> doing any of the actual domain creation.
>
> At the moment, all I'd do is do a 'ping' to see if the domain is up and
> running. Not foolproof but would save me >99% of the time. In a cluster
> environment there should be a way to determine remotely if a domain is
> running.
For such a quick-and-dirty check, couldn't you just write yourself a wrapper
script that did the ping and then called xm create?
If you want to do this properly, then inside Xend would be the best place, as
Mark Williamson suggests. XendRoot handles the config file and the script
directories (see XendRoot.get_network_script for example).
Cheers,
Ewan.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|