Recently we faced with one problem. We have to have many CMS on different virtual machines located on our ESX server. One CMS for one VM (it is important). But we don't want to store them all simultaneously and we're searching for solution to configure VMs on demand. All machines are differed only by CMS, underlying OS and all soft (apache, php etc) are the same. Can anybody help us with this? May be there are existing opensource (or not very expensive) solutions? Thanks in advance!
There are at least 2 oob ways to clone a VM with EXS.
- If you have vCenter you can just use Clone option
- If you don't have vCenter then you can just create a copy of VM disk and then create a new VM pointing it to that disk
If you don't want to bother with vSphere client for these tasks, then you can just create simple scripts with vCLI or PowerCLI. If you are cloning Windows VM, then it might be useful to do to this over syspreped image.
While the above is the answer to the question you asked, but this is probably not the answer you want, because, as far as I understood, your primary problem is configuring of CMS inside of VM (I might be mistaken here) which is actually not the thing that ESX should worry about. If so, then you need to elaborate your question and provide as much details as you can, e.g.:
- What is "different" CMS's? Are these really different CMS's or just different versions of the same CMS
- CMS is you SUT or you run your SUT at the top of some third-party CMS's?
- What OS is inside your VM
There's a couple of options I can think of right now.
The low-impact version is to have an off-server data store where your VM images are kept and moved to the ESX server on demand. This can be automated fairly easily using the sysinternals tools and command line (I'm presuming you have command line access to manage your ESX server).
If you need to install and configure the VM and then the CMS on the fly things get more complex: you could probably still do this with a command line interface but it would be a whole lot more complicated to set up.
If your issue is purely with drive space, I'd recommend investing in some hard drives and use these as your template locations so the server platters are only hosting the currently active VMs.
If your issue relates to IO then things get more awkward.