WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-api

[Xen-API] Cloning and Templates

To: xen-api@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-API] Cloning and Templates
From: Nick Moffitt <nick@xxxxxxxx>
Date: Sat, 7 Feb 2009 14:43:12 +0000
Delivery-date: Sat, 07 Feb 2009 06:43:56 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-api-request@lists.xensource.com?subject=help>
List-id: Discussion of API issues surrounding Xen <xen-api.lists.xensource.com>
List-post: <mailto:xen-api@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=unsubscribe>
Mail-followup-to: Nick Moffitt <nick@xxxxxxxx>, xen-api@xxxxxxxxxxxxxxxxxxx
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.17+20080114 (2008-01-14)
I'm building a system that needs to be able to bring up fresh VMs rather
quickly, and I've had experience scripting around with lvm2
copy-on-write snapshots for this in the past.  The trouble now is that
I'll be needing to manage a pool of physical servers that host VMs, and
I'm hoping to save myself the fuss of maintaining much of this
infrastructure myself, and using the Xen API to do most of the remote
legwork.

Looking through the xen-api docs in the Xen 3.2 source tree, I found:

        \subsubsection{RPC name:~clone}

        {\bf Overview:} 
        Clones the specified VM, making a new VM. Clone automatically
        exploits the capabilities of the underlying storage repository
        in which the VM's disk images are stored (e.g. Copy on Write).
        This function can only be called when the VM is in the Halted
        State.

This seems tailor-made for my needs!  Unfortunately I've had some
trouble trying to figure out what I need to do to make it work.  

The documentation does talk about a 'template' type for VMs, but I can
find no formal documentation of same: all google turns up for me is a
more casual use of the term.  

Ignoring the 'template' status, I ran xen-create-image from the shell
and then popped into python and ran VM.get_all_records() (which appears
nowhere in the API documentation that I can find, and I only know about
it because of the examples[1]).  All that I got back was the dom0, and
get_all() just gave me the all-zeroes UID that was the dom0 key.

Is there better documentation for this sort of task somewhere?  Am I
going on the right path by using the Xen API over some kind of remote
connection to each physical server?  I did see mention of all kinds of
pooling and management techniques, but I'm a bit lost as to whether
they'd be supported in Xen 3.2.

-- 
"There should be a homonym exam before people are         Nick Moffitt
issued keyboards."     -- George Moffitt                 nick@xxxxxxxx

1: 
http://ca.downloads.xensource.com/XenServer-5.0.0RC4/api/client-examples/python/index.html

_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-API] Cloning and Templates, Nick Moffitt <=