Applicable to:
- SolusVM
Question
How to create a template in OpenVZ Virtuozzo 7 using standard(legacy) OpenVZ 6 template to use in SolusVM?
Answer
Use the OpenVZ 6 pre-created template on the Virtuozzo 7 host-node which automatically converts the pre-created template to the EZ template by running the command during the VPS creation from the SolusVM.
- Access OpenVZ 7 node via SSH
- Download a standard(legacy) OS template (for example, centos 7 minimal):
# cd /vz/template/cache/
# wget http://download.openvz.org/template/precreated/centos-7-x86_64-minimal.tar.gz - Convert the template so that it can be used by OpenVZ 7 with the command:
# /usr/libexec/ovz-template-converter --verbose /vz/template/cache/centos-7-x86_64-minimal.tar.gz
Note: if conversion fails with error
def writeconfig(configfile, configtext, configmode=0644)
, use patched file from this article - To use the converted template in SolusVM it is required to create corresponding tar.gz file. Create a new container using OpenVZ native tools:
# vzctl create 999999 --ostemplate centos-7-x86_64-minimal
- Change directory to the container's private area:
# cd /vz/private/999999/
- Pack a template with the name structure as
{distribution}-{release}-{arch}-{custom}.tar.gz
:# tar -cvzpf /vz/template/cache/centos-7-x86_64-test.tar.gz .
Note: dot at the end of the command query above is a mandatory after space
After that the newly created template can be used for deploying VPSes on OpenVZ 7 via from Admin panel.
Comments
0 commentsPlease sign in to leave a comment.