Update a container and then make copies

UserIsNew

New Member
Jul 29, 2014
9
0
1
hey guys
i have a centos container configured the way i want it
and now i would like to create copies
and change ip address etc

cp -r /var/lib/vz/private/100/ /var/lib/vz/private/101
cp /etc/vz/conf/100.conf /etc/vz/conf/101.conf

and edited the 101.conf

what all do i need to change in it ?
i changed ip and mac and it didnt boot

thanx all
 
Hello UserIsNew

cp -r /var/lib/vz/private/100/ /var/lib/vz/private/101
cp /etc/vz/conf/100.conf /etc/vz/conf/101.conf

In principle ok but the first cp command has to be slightly different.

Here is an example, I created container 1094 by copying it from 1093, in my case the storage is /mnt/pve/vpx and directory for configuration files /etc/pve/openvz:

Code:
cp -a -v /mnt/pve/vpx/private/1093/ /mnt/pve/vpx/private/1094
cp /etc/pve/openvz/1093.conf /etc/pve/openvz/1094.conf

Then I edited 1094.conf:

- all where I found "1093" I changed it to "1094"

- changed the mac- and IP-addresses to new values

That´s all

Kind regards

Mr.Holmes
 
Last edited:

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!