clone or copy images help

  • Thread starter Thread starter planohog
  • Start date Start date
P

planohog

Guest
Greetings, i am a converted xen user, proxmox loaded nicely and was
able to use all 32G of my memory.. Ok I have created a centos5.2 image
that I have loaded with all my goodies. I need to be able to clone this
image to use for deployment. Yes I will have to change the ip every time but
that is low hanging fruit. Can you give me some instruction on how to do this. thanks in advance. -tm
 
Greetings, i am a converted xen user, proxmox loaded nicely and was
able to use all 32G of my memory.. Ok I have created a centos5.2 image
that I have loaded with all my goodies. I need to be able to clone this
image to use for deployment. Yes I will have to change the ip every time but
that is low hanging fruit. Can you give me some instruction on how to do this. thanks in advance. -tm

Do you talk about KVM or OpenVZ on Proxmox VE?
(OpenVZ is our preferred for running Linux)
 
OpenVZ is main container but KVM may be good to know as well..
 
Probably the best way to do this with openvz would be to create a new template. I've done this with ubuntu, and it should probably be the same with centos.

Assuming your container ID is 101 and that you have stopped your container:

Remove the ip address of the container:
Code:
vzctl set 101 --ipdel all --save
then tar the private area to the template file you want. Make sure the first word of your new template is 'centos' (this helps openVZ find the right config template to use with newly created containers).
Code:
cd /var/lib/vz/private/101
tar czf /var/lib/vz/template/cache/centos-5.2-custom.tar.gz .
You should now see that template as an option when creating new containers.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!