A Virtuozzo Container is based on an Operating System template (OS template). When creating a Container, you must choose and specify the OS template name. The OS templates are shipped with Virtuozzo Containers software and are installed on the Hardware Node. To get the list of the available OS templates, use the vzapkgm/list
call as shown in the following example:
<packet version="4.0.0" id="32">
<target>vzapkgm</target>
<data>
<vzapkgm>
<list>
<options>
<type>os</type>
</options>
</list>
</vzapkgm>
</data>
</packet>
The output will contain the list of the available OS templates:
<packet id="32" time="2007-09-10T10:22:45+0000" priority="0" version="4.0.0">
<origin>vzapkgm</origin>
<target>vzclient136-4fce28dd-0cd3-1345-bb94-3192b940fb90</target>
<dst>
<director>gend</director>
</dst>
<data>
<vzapkgm>
<packages>
<package>
<name>redhat-as3-minimal</name>
<version>20061020</version>
Linux
<platform>Linux</platform>
<name/>
</os>
<arch>x86</arch>
<os_template>1</os_template>
<cached>1</cached>
<uptodate>0</uptodate>
<technology>nptl</technology>
<technology>x86</technology>
<base>1</base>
</package>
</packages>
</vzapkgm>
</data>
</packet>
Choose the OS template from the list and get its name. The template name will be used as a parameter in the call that will create the Container later. In our example, we have just one template and its name is "redhat-as3-minimal" (the standard Virtuozzo Containers Red Hat Linux template).