I would like to install two OpenVZ templates, each one in a different logical volume. I have created a separate partition, made it a physical volume, assigned it a group volume and separated in two logical volumes vzprimary and vzsecondary, mounted on /vz/vzprimary and /vz/vzsecondary like this:

[root@primary lost+found]# df -h
Filesystem            Size  Used Avail Use% Mounted on
                       18G  3.7G   13G  23% /
tmpfs                 946M  224K  946M   1% /dev/shm
/dev/sda1             477M   65M  387M  15% /boot
                      4.7G  9.7M  4.4G   1% /vz/primary
                      4.7G  9.7M  4.4G   1% /vz/secondary

I would like to install one template in eache logical volume. Can I do that? From what I read, I could not find an option like that: the vzctl create command requires only the CT ID and the name of the OS template as arguments.


You should have --private option for vzctl create:

vzctl create CTID --private /vz/primary
vzctl create CTID --private /vz/secondary

If each container has a dedicated partition, also consider specifying --layout simfs. ploop might be unneeded overhead.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.