Changes

Jump to: navigation, search

Man/vzctl.8

25,433 bytes added, 18:21, 23 April 2015
Automated import of articles *** existing text overwritten ***
<p style="margin-top: 1em">[<i>flags</i>] <b>create</b>
<i>CTID</i> [<b>--ostemplate&nbsp;</b><i>name</i>][<b>--config&nbsp;</b><i>name</i>][<b>--root&nbsp;parameter value</b><i>path</i>][<b>--private&nbsp;</b><i>path</i>][<b>--ipadd&nbsp;</b><i>addr</i>][<b>--hostname&nbsp;</b><i>name</i>...]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<p>[<i>flags</i>] <b>start</b> <i>CTID</i> [<b>--wait</b>]
[<b>--force</b>] [<b>--skip-fsck</b>][<b>--skip-remount</b>]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>stop</b> <i>CTID</i>[<b>--fast</b>][<b>--fastskip-umount</b>]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<p>[<i>flags</i>] <b>restart</b> <i>CTID</i>
[<b>--wait</b>] [<b>--force</b>] [<b>--fast</b>][<b>--skip-fsck</b>] [<b>--skip-remount</b>]</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>chkpntsuspend</b> | <b>restoreresume</b><i>CTID</i> [<b>--dumpfile&nbsp;</b><i>name</i>]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>setsnapshot</b> <i>CTID</i> [<b>--save</b>][<b>--setmode&nbsp;restart</b>|<b>ignore</b>][<b>--onboot&nbsp;yes</b>|<b>no</b>][<b>--bootorderid&nbsp;</b><i>number</i>][<b>--root&nbsp;uuid</b><i>path</i>][<b>--private&nbsp;</b><i>path</i>][<b>--userpasswd&nbsp;</b><i>user</i>:<i>pass</i>][<b>--disabled&nbsp;yes</b>|<b>no</b>]
[<b>--name&nbsp;</b><i>name</i>]
[<b>--description&nbsp;</b><i>stringdesc</i>][<b>--ipadd&nbsp;</b><i>addr</i>][<b>--ipdel&nbsp;</b><i>addr</i>|<b>all</b>][<b>-skip-hostname&nbsp;suspend</b><i>name</i>][<b>--nameserver&nbsp;</b><i>addr</i>][<b>skip--searchdomain&nbsp;config</b><i>name</i>][<b>--netif_add&nbsp;</bp><i>dev</i>[,<itd>params</itr>...]][<b>--netif_del&nbsp;</b><i>dev</i>] [<b>--ifname</btr valign="top" align="left"><i>dev</itd width="11%"> [<b>--mac&nbsp;</btd><i>hwaddr</i>][<b>--host_ifname&nbsp;</b><itd width="7%">dev</i>][<b>--host_mac&nbsp;</b><i>hwaddr</i>][<bp>--bridge&nbsp;</b><i>namevzctl</i>][<b>--mac_filter&nbsp;on</b>|<bp>off</btd>]][<btd width="2%">--numproc&nbsp;</btd><i>items</i>][<b>--numtcpsock&nbsp;</b><i>items</itd width="80%">][<b>--numothersock&nbsp;</b><i>items</i>][<b>--vmguarpages&nbsp;</bp><i>pages</i>][<b>--kmemsize&nbsp;</b><i>bytesflags</i>][<b>snapshot--tcpsndbuf&nbsp;switch</b><i>bytesCTID</i>][<b>--tcprcvbuf&nbsp;</b><i>bytes</i>][<b>skip--othersockbuf&nbsp;resume</b><i>bytes</i>][| <b>--dgramrcvbuf&nbsp;</b><i>bytes</i>][<b>-must-oomguarpages&nbsp;resume</b><i>pages</i>][<b>--lockedpages&nbsp;</b><i>pages</i>][<b>skip--privvmpages&nbsp;config</b><i>pages</i>][<b>--shmpages&nbsp;id</b><i>pagesuuid</i>][<b>--numfile&nbsp;</b><ip>items</itd>][<b>--numflock&nbsp;</b><i>items</itr>][<b>--numpty&nbsp;</btr valign="top" align="left"><i>items</i>][<btd width="11%">--numsiginfo&nbsp;</btd><i>items</i>][<b>--dcachesize&nbsp;</btd width="7%"><i>bytes</i>][<b>--numiptent&nbsp;</b><i>num</i>][<bp>--physpages&nbsp;</b><i>pagesvzctl</i>][<b>--swappages&nbsp;</b><ip>pages</itd>][<btd width="2%">--cpuunits&nbsp;</btd><i>num</i>][<b>--cpulimit&nbsp;</b><itd width="80%">num</i>][<b>--cpus&nbsp;</b><i>num</i>][<b>--cpumask&nbsp;</bp><i>cpus</i>|<b>all</b>][<b>--meminfo&nbsp;none</b>|<i>mode</i>:<i>valueflags</i>][<b>snapshot--iptables&nbsp;delete</b><i>nameCTID</i>][<b>--netdev_add&nbsp;id</b><i>ifnameuuid</i>][<b>--netdev_del&nbsp;</b><i>ifname</i>][<b>--diskquota&nbsp;yes</b>|<b>no</bp>][<b>--diskspace&nbsp;</b><itd>num</itr>][<b>--diskinodes&nbsp;</btr valign="top" align="left"><i>num</i>][<btd width="11%">--quotatime&nbsp;</b><i>seconds</itd>][<btd width="7%">--quotaugidlimit&nbsp;</b><i>num</i>][<b>--noatime&nbsp;yes</b>|<b>no</b>][<bp>--capability&nbsp;</b><i>capnamevzctl</i>:<b>on</b>|<bp>off</btd>][<btd width="2%">--devnodes&nbsp;</btd><i>param</i>][<b>--devices&nbsp;</b><itd width="80%">param</i>][<b>--pci_add&nbsp;</b><i>dev</i>][<bp>--pci_del&nbsp;</b><i>dev</i>][<b>--features&nbsp;</b><i>paramflags</i>:<b>on</b>|<b>off</b>][<b>snapshot--applyconfig&nbsp;mount</b><i>nameCTID</i>][<b>--applyconfig_map&nbsp;id</b><i>groupuuid</i>][<b>--ioprio&nbsp;target</b><i>numdir</i>]</p> </td></tr><tr valign="top" align="left">
<td width="11%"></td>
<td width="7%">
<td width="80%">
<p>[<i>flags</i>] <b>destroy</b> | <b>delete</b> |<b>mount</b> | <b>snapshot-umount</b> | <bi>statusCTID</bi> |<b>quotaon--id</b> | <b>quotaoff</b> | <b>quotainit</b><i>CTIDuuid</i></p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>execsnapshot-list</b> | <i>CTID</i>[<b>-H</b>] [<b>exec2-o</b> <i>CTIDfield</i>[,<i>field</i>...]command[<b>--id</b> <i>uuid</i>]</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="7%"> <p><b>vzctl</b></p></td><td width="2%"></td><td width="80%"> <p> [<i>argflags</i>] <b>set</b> <i> CTID --parameter value</i>[...] [<b>--save</b>] [<b>--force</b>][<b>--setmode&nbsp;restart</b>|<b>ignore</b>]</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>enterset</b> <i>CTID</i>[<b>--exec&nbsp;reset_ub</b><i>command&nbsp;</i>[<i>arg&nbsp;</i>...]]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>runscriptdestroy</b> | <b>delete</b> |<b>mount</b> | <b>umount</b> | <b>status</b> |<b>quotaon</b> | <b>quotaoff</b> | <b>quotainit</b><i>CTID script</i></p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>--helpconsole</b> | <bi>CTID</i>[<i>--versionttynum</bi>]</p></td></tr><tr valign="top" align="left"><td width="11%"></tabletd><td width="7%">
<p><b>vzctl</b></p></td><td width="2%"></td><td width= DESCRIPTION =="80%">
<p style="margin>[<i>flags</i>] <b>convert</b> <i>CTID</i>[<b>--left:11%layout&nbsp; margin-topploop</b>[<b>: 1em"</b>{<b>expanded</b>|<b>plain</b>Utility|<b>vzctlraw</b> runs on the host system (otherwise known as}]]</p> </td></tr>Hardware Node, or HN) and performs direct manipulations with<tr valign="top" align="left">containers (CTs).<td width="11%"></ptd><td width="7%">
<p style="margin-left:11%; margin-top: 1em">Containers canbe referred to by either numeric <ib>vzctl</b></p>CTID</itd> or by name (see<btd width="2%">--name</btd> option). Note that CT ID &lt;= 100 arereserved for OpenVZ internal purposes.</ptd width="80%">
<p>[<i>flags</i>] <b>compact</b> <i>CTID</i></p></td></tr><tr valign="top" align= OPTIONS "left"><td width="11%"></td><td width="7%">
<p><b>vzctl</b></p></td><td width="2%"></td><td width== Flags ==="80%">
<p style="margin-top: 1em">These [<i>flags come before a</i>] <b>exec</b> | <b>exec2</b> <i>CTIDcommand, and can be used with any command</i> [<i>arg</i> ... They affect]</p></td></tr>logging to console (terminal) only, and do not affect<tr valign="top" align="left">logging to a log file.<td width="11%"></ptd><td width="7%">
<p style="margin-left:11%;"><b>--quietvzctl</b></p></td><td width="2%"></td><td width="80%">
<p style>[<i>flags</i>] <b>enter</b> <i>CTID</i>[<b>--exec&nbsp;</b><i>command&nbsp;</i>[<i>arg&nbsp;</i>...]]</p> </td></tr><tr valign="top" align="margin-left:17"><td width="11%;">Disables output. Note that</td>scripts run by vzctl are still able to produce someoutput.</ptd width="7%">
<p style="margin-left:11%;"><b>--verbosevzctl</b></p></td><td width="2%"></td><td width="80%">
<p style="margin-left:17%;">Increments logging level upfrom the default. Can be used multiple times. Default valueis set to the value of [<i>flags</i>] <b>VERBOSErunscript</b> parameter in theglobal configuration file [[Man<i>CTID script</vz.conf.5|i><b/p>vz.conf</btd>(5)]], or to <b/tr>0</btr valign="top" align="left">if not set by <btd width="11%">VERBOSE</btd> parameter.</ptd width="7%">
<p><b>vzctl</b></p></td><td width="2%"></td><td width== Setting container parameters ==="80%">
<p style="margin-left:11%;"><b>set--help</b> | <ib>CTIDparameters--version</i> [<b>--save</bp>] [<b/td>--force</btr>]</ptable>
<p style="margin-left:17%;">This command sets variouscontainer parameters. If a <b>--save</b> flag is given,parameters are saved in container configuration file[[Man/ctid.conf.5|<b>ctid.conf</b>(5)]]. Use <b>--force</b> to save theparameters even if the current kernel doesn&rsquo;t supportOpenVZ. If the container is currently running, <b>vzctl</b>applies these parameters to the container.</p>= DESCRIPTION ==
<p style="margin-left:1711%; margin-top: 1em">The followingUtilityparameters can be used with <b>setvzctl</b> commandruns on the host system (otherwise known asHardware Node, or HN) and performs direct manipulations withcontainers (CTs).</p>
<p style="margin-left:11%; margin-top: 1em">Containers canbe referred to by either numeric <i>CTID</i> or by name (see<b>--name</b> option). Note that CT ID &lt;=== Miscellaneous ====100 arereserved for OpenVZ internal purposes. A numeric ID shouldnot be more than <b>2147483644</b>.</p>
<p style="margin-left:11%;"><b>--onboot yes</b> |<b>no</b></p>= OPTIONS ==
<p style="margin-left:17%;">Sets whether the container willbe started during system boot. The container will not beauto-started unless this parameter is set to <b>yes</b>.</p>== Flags ===
<p style="margin-lefttop:11%;1em"><b>--bootorder</b>These flags come before acommand, and can be used with any command. They affectlogging to console (terminal) only, and do not affect<i>number</i>logging to a log file.</p>
<p style="margin-left:1711%;">Sets the boot order priorityfor this CT. The higher the <i>number</i> is, the earlier inthe boot process this container starts. By default thisparameter is unset, which is considered to be the lowestpriority, so containers with unset <b>bootorder--quiet</b> willstart last.</p>
<p style="margin-left:1117%;"><b>--root</b> <i>path</i>Disables output. Note thatscripts run by vzctl are still able to produce someoutput.</p>
<p style="margin-left:1711%;">Sets the path to root directory(<b>VE_ROOT--verbose</b>) for this container. This is essentially amount point for container&rsquo;s root directory. Argumentcan contain literal string <b>$VEID</b>, which will besubstituted with the numeric CT ID.</p>
<p style="margin-left:1117%;">Increments logging level upfrom the default. Can be used multiple times. Default valueis set to the value of <b>VERBOSE</b> parameter in theglobal configuration file [[Man/vz.conf.5|<b>vz.conf</b>(5)]], or to <b>--private0</b>if not set by <ib>pathVERBOSE</ib>parameter.</p>
<p style="margin-left:17%;">Sets the path to privatedirectory (<b>VE_PRIVATE</b>) for this == Setting container. This is adirectory in which all the container&rsquo;s files arestored. Argument can contain literal string <b>$VEID</b>,which will be substituted with the numeric CT ID.</p>parameters ===
<p styletable width="margin-left:11100%;" border="0" rules="none" frame="void" cellspacing="0" cellpadding="0"><b>--userpasswd</btr valign="top" align="left"><itd width="11%">user</itd>:<i>password</i></ptd width="4%">
<p style="margin-lefttop:17%;1em">Sets password for the givenuser in a container, creating the user if it does notexists. Note that this option is not saved in configurationfile at all (so <b>--saveset</b> flag is useless), it isapplied to the container (by modifying its </etcp></passwd andtd><td width="2%"></etc/shadow files).td></ptd width="83%">
<p style="margin-left:17%; margin-top: 1em">In case<i>CTID</i>[<b>--onboot&nbsp;yes</b>|<b>no</b>][<b>--bootorder&nbsp;</b><i>number</i>]container [<b>--root filesystem is not mounted, it is&nbsp;</b><i>path</i>][<b>--private&nbsp;</b><i>path</i>]automatically mounted, then all the appropriate file changes[<b>--mount_opts&nbsp;</b><i>options</i>]are applied, then it is unmounted.[<b>--userpasswd&nbsp;</b><i>user</i>:<i>pass</pi>][<b>--disabled&nbsp;yes</b>|<b>no</b>][<p style="marginb>--left:17%name&nbsp; margin</b><i>name</i>][<b>--top: 1em"description&nbsp;</b><i>string</i>Note that]container should be created before using this option.[<b>--ostemplate&nbsp;</b><i>string</pi>][<b>--stop-timeout&nbsp;</b><i>seconds</i>][<p style="marginb>--left:11%ipadd&nbsp;"</b><i>addr</i>][<b>--disabled yesipdel&nbsp;</b><i>addr</i> |<b>all</b>][<b>--hostname&nbsp;</b><i>name</i>][<b>no--nameserver&nbsp;</b><i>addr</pi>][<b>--searchdomain&nbsp;</b><i>name</i>][<p style="marginb>--left:17%netif_add&nbsp;"</b><i>dev</i>[,<i>params</i>Disable container start. To..]]force the start of a disabled container, use [<b>--netif_del&nbsp;</b><i>dev</i>|<b>all</b>][<b>--ifname</b>vzctl start<i>dev</i>[<b>--forcemac&nbsp;</b>.<i>hwaddr</pi>][<b>--host_ifname&nbsp;</b><i>dev</i>][<p style="marginb>--left:11%host_mac&nbsp;"</b><i>hwaddr</i>][<b>--namebridge&nbsp;</b> <i>name</i>][<b>--mac_filter&nbsp;on</b>|<b>off</pb>]][<b>--numproc&nbsp;</b><i>items</i>][<p style="marginb>--left:17%numtcpsock&nbsp;"</b><i>items</i>Add a name for a container. The][<b>--numothersock&nbsp;</b><i>nameitems</i> can later be used in subsequent calls to][<b>vzctl--vmguarpages&nbsp;</b> in place of <i>CTIDpages</i>][<b>--kmemsize&nbsp;</b><i>.bytes</pi>][<b>--tcpsndbuf&nbsp;</b><i>bytes</i>][<p style="marginb>--left:11%tcprcvbuf&nbsp;"</b><i>bytes</i>][<b>--descriptionothersockbuf&nbsp;</b><i>bytes</i>][<b>--dgramrcvbuf&nbsp;</b><i>bytes</i>string][<b>--oomguarpages&nbsp;</b><i>pages</pi>][<b>--lockedpages&nbsp;</b><i>pages</i>][<p style="marginb>--left:17%privvmpages&nbsp;"</b><i>pages</i>Add a textual description for a]container.[<b>--shmpages&nbsp;</b><i>pages</pi>][<b>--numfile&nbsp;</b><i>items</i>][<p style="marginb>--left:11%numflock&nbsp;"</b><i>items</i>][<b>--setmodenumpty&nbsp;</b><i>items</i>]restart[<b>--numsiginfo&nbsp;</b>|<i>items</i>][<b>ignore--dcachesize&nbsp;</b><i>bytes</pi>][<b>--numiptent&nbsp;</b><i>num</i>][<p style="marginb>--physpages&nbsp;</b><i>pages</i>][<b>--left:17%swappages&nbsp;"</b><i>pages</i>Whether to restart a container]after applying parameters that require the container to be[<b>--ram&nbsp;</b><i>bytes</i>]restarted in order to take effect.[<b>--swap&nbsp;</b><i>bytes</pi>][<b>--vm_overcommit&nbsp;</b><i>float</i>]==== Networking ====[<b>--cpuunits&nbsp;</b><i>num</i>][<b>--cpulimit&nbsp;</b><i>num</i>][<p style="marginb>--left:11%cpus&nbsp;"</b><i>num</i>][<b>--ipaddcpumask&nbsp;</b> <i>addrcpus</i>|<b>auto</pb>|<b>all</b>][<b>--nodemask&nbsp;</b><i>nodes</i>|<b>all</b>][<p style="marginb>--leftmeminfo&nbsp;none</b>|<i>mode</i>:17%<i>value</i>][<b>--iptables&nbsp;"</b><i>name</i>[<b>,</b>Adds IP address to a given...]]container. Note that this option is incremental, so[<b>--netfilter&nbsp;disabled</b>|<b>stateless</b>|<b>stateful</b>|<b>full</b>][<b>--netdev_add&nbsp;</b><i>ifname</i>addr][<b>--netdev_del&nbsp;</b><i> are added to already existing ones.ifname</pi>][<b>--diskquota&nbsp;yes</b>|<b>no</b>][<p style="marginb>--left:11%diskspace&nbsp;"</b><i>num</i>][<b>--ipdeldiskinodes&nbsp;</b> <i>addrnum</i> |][<b>all--quotatime&nbsp;</b><i>seconds</pi>][<b>--quotaugidlimit&nbsp;</b><i>num</i>][<p style="marginb>--left:17%capability&nbsp;"</b>Removes IP address <i>addrcapname</i>from a container:<b>on</b>|<b>off</b>[<b>,</b>... If you want to remove all the addresses,]]use [<b>--ipdel alldevnodes&nbsp;</b>.<i>param</pi>][<b>--devices&nbsp;</b><i>param</i>][<p style="marginb>--left:11%pci_add&nbsp;"</b><i>dev</i>][<b>--hostnamepci_del&nbsp;</b><i>dev</i>][<b>--features&nbsp;</b><i>name</i>:<b>on</b>|<b>off</b>[<b>,</b>...]][<b>--applyconfig&nbsp;</b><i>name</pi>][<b>--applyconfig_map&nbsp;</b><i>group</i>][<p style="marginb>--left:17%ioprio&nbsp;"</b><i>num</i>Sets container hostname.][<b>vzctl--iolimit&nbsp;</b> writes it to the appropriate file inside a<i>mbps</i>]container (distribution[<b>--iopslimit&nbsp;</b><i>iops</i>] [<b>--dependent).save</pb>][<b>--force</b>] [<b>--reset_ub</b>][<b>--setmode&nbsp;restart</b>|<b>ignore</b>]</p style> </td></tr><tr valign="top" align="margin-left:"><td width="11%;"></td><td width="4%"></td><td width="2%"></td><td width="83%"> <p>This command sets various container parameters. If thecontainer is currently running, <b>--nameservervzctl</b>applies theseparameters to the container. The following options can beused with <ib>addrset</ib>command.</p></td></tr></table> ==== Flags ====
<p style="margin-left:1711%;">Sets DNS server IP address fora container. If you want to set several nameservers, youshould do it at once, so use <b>--nameserversave</b> optionmultiple times in one call to <b>vzctl</b>, as all the nameserver values set in previous calls to <b>vzctl</b> areoverwritten.</p>
<p style="margin-left:1117%;">If this flag is given,parameters are saved in container configuration file[[Man/ctid.conf.5|<b>--searchdomainctid.conf</b><i>name</i>(5)]].</p>
<p style="margin-left:1711%;">Sets DNS search domains for acontainer. If you want to set several search domains, youshould do it at once, so use <b>--searchdomainforce</b> optionmultiple times in one call to <b>vzctl</b>, as all thesearch domain values set in previous calls to <b>vzctl</b>are overwritten.</p>
<p style="margin-left:1117%;">If this flag is given togetherwith <b>--netif_addsave</b>, parameters are saved even if the currentkernel doesn&rsquo;t support OpenVZ. Note this flag does notmake sense without <ib>ifname[--save</ib>,so <ib>mac--save</i>,<i>host_ifname</i>,<i>host_mac</i>,<i>bridge]</ib>isrequired.</p>
<p style="margin-left:1711%;">Adds a virtual Ethernet device(veth) to a given container. Here <ib>ifname--reset_ub</ib> is theEthernet device name in the container, <i>mac</i> is its MACaddress, <i>host_ifname</i> is the Ethernet device name onthe host, and <i>host_mac</i> is its MAC address. MACaddresses should be in the format like XX:XX:XX:XX:XX:XX.<i>bridge</i> is an optional parameter which can be used incustom network start scripts to automatically add theinterface to a bridge. All parameters except <i>ifname</i>are optional and are automatically generated if notspecified.</p>
<p style="margin-left:1117%;">If this flag is given,<b>--netif_delvzctl</b>applies all User Beancounter parameters from<the configuration file to a running container. This ishelpful in case configuration file is modified manually.Please note this flag is exclusive, i>dev_name</i> | <b>all</b>.e. it can not becombined with any other options or flags.</p>
<p style="margin-left:1711%;">Removes virtual Ethernet devicefrom a container. If you want to remove all devices, use<b>--setmode restart</b> |<b>allignore</b>.</p>
<p style==== veth interface configuration ===="margin-left:17%;">A few parameters can only beapplied by restarting the container. By default,<b>vzctl</b> prints a warning if such parameters aresupplied and a container is running. Use <b>--setmoderestart</b> together with <b>--save</b> flag to restart acontainer in such a case, or <b>--setmode ignore</b> tosuppress the warning.</p>
<p style="margin-left:11%; margin-top: 1em">The followingoptions can be used to reconfigure the already-createdvirtual Ethernet interface. To select the interface toconfigure, use <b>--ifname</b> <i>name</i> option. <b><br>--mac</b> <i>XX:XX:XX:XX:XX:XX</i></p>=== Miscellaneous ====
<p style="margin-left:2211%;">MAC address of interface inside<b>--onboot yes</b> |a container.<b>no</b></p>
<p style="margin-left:1117%;">Sets whether the container willbe started during system boot. The container will be startedon boot by <b>vz</b> initscript if either this parameter isset to <b>--host_ifnameyes</b>, or the container was running just beforelast reboot, and this parameter is not set to <ib>nameno</ib>.Default value is unset, meaning the container will bestarted if it was running before the last reboot.</p>
<p style="margin-left:2211%;">interface name for virtual<b>--bootorder</b>interface in the host system.<i>number</i></p>
<p style="margin-left:1117%;">Sets the boot order priorityfor this CT. The higher the <bi>--host_macnumber</bi>is, the earlier inthe boot process this container starts. By default thisparameter is unset, which is considered to be the lowestpriority, so containers with unset <ib>XX:XX:XX:XX:XX:XXbootorder</ib>willstart last.</p>
<p style="margin-left:2211%;">MAC address of interface in thehost system.<b>--root</b> <i>path</i></p>
<p style="margin-left:1117%;">Sets the path to root directory(<b>--bridgeVE_ROOT</b> ) for this container. This is essentially amount point for container&rsquo;s root directory. Argumentcan contain literal string <ib>name$VEID</ib>, which will besubstituted with the numeric CT ID.</p>
<p style="margin-left:2211%;">Bridge name. Custom network<b>--private</b>start scripts can use this value to automatically add theinterface to a bridge.<i>path</i></p>
<p style="margin-left:1117%;">Sets the path to privatedirectory (<b>--mac_filter onVE_PRIVATE</b> |) for this container. This is adirectory in which all the container&rsquo;s files arestored. Argument can contain literal string <b>off$VEID</b>,which will be substituted with the numeric CT ID.</p>
<p style="margin-left:2211%;">Enables<b>--mount_opts</disables MAC addressb>filtering for the Container veth device and the possibilityof configuring the MAC address of this device from insidethe Container. If the filtering is turned on: <bri>option</i>[<b>,</b><i>&bull; the veth device accepts only those packets that havea MAC address in their headers corresponding to that of thisdevice (excluding all broadcast and multicast packets); option<br/i>&bull; it is impossible to modify the veth MAC address frominside the Container...]</p>
<p style="margin-left:2217%; margin-top: 1em">By default,Sets additional mount optionsthis functionality is enabled for all veth devices existingcontainer file system. Only applicable for <b>ploop</b>inside the Containerlayout, ignored otherwise.</p>
<p style==== Resource limits ===="margin-left:11%;"><b>--userpasswd</b><i>user</i>:<i>password</i></p>
<p style="margin-left:1117%; margin-top: 1em">The followingSets password for the givenoptions sets barrier and limit for various userin a container, creating the user if it does notbeancountersexists. Each Note that this option requires one or two arguments. Inis not saved in configurationcase of one argument, file at all (so <b>vzctl--save</b> sets barrier and limit flag is useless), it isapplied directly tothe same value. In case of two colon-separated argumentscontainer,by runningdistribution-specific programs inside the first is a barrier, and the second container. It is a limit. Eachargument is either a number, a number not recommended to combine this option with a suffix, or aany otherspecial value <b>unlimited</b>options.</p>
<p style="margin-left:1117%; margin-top: 1em">Arguments areIn casein itemscontainer was not running, pages or bytes. Note that page size it isautomatically started thenarchitecture-specificall the appropriate changes are applied, then it is 4096 bytes on x86 and x86_64platformsstopped.</p>
<p style="margin-left:1117%; margin-top: 1em">You can alsoNote thatspecify different suffixes for <b>set</b> parameters (exceptfor the parameters which names start with <b>num</b>). Forexample, <b>vzctl set</b> <i>CTID</i> <b>--privvmpages5M:6M</b> container should set <b>privvmpages</b>&rsquo; barrier to 5megabytes and its limit to 6 megabytesbe created before using this option.</p>
<p style="margin-left:11%; margin"><b>-top: 1em"-disabled yes</b>Available|suffixes are:<b>no</b></p>
<table widthp style="100margin-left:17%" border="0" rules="none" frame="void" cellspacing="0" cellpadding="0;">Disable container start. Toforce the start of a disabled container, use <tr valign="top" align="left"b>vzctl start--force<td width="11%"/b>.</td><td width="6%"p>
<pstyle="margin-left:11%;"><b>T--name</b>, <bi>tname</bi></p></td><td width="5%"></td><td width="44%">
<pstyle="margin-left:17%;">terabytes;Add a name for a container. The</pi>name</tdi>can later be used in subsequent calls to<td width="34%"b>vzctl</tdb>in place of </tri>CTID<tr valign="top" align="left"/i>. Note this option cannot be used without <td width="11%"b>--save</tdb>.<td width="6%"/p>
<pstyle="margin-left:11%;"><b>G--description</b>, <bi>gstring</bi></p></td><td width="5%"></td><td width="44%">
<p>gigabytes;</p></td><td widthstyle="34margin-left:17%;">Add a textual description for acontainer.</td></tr><tr valign="top" align="left"><td width="11%"></td><td width="6%"p>
<pstyle="margin-left:11%;"><b>M--ostemplate</b>, <bi>mstring</bi></p></td><td width="5%"></td><td width="44%">
<p>megabytes;</p></td><td widthstyle="34margin-left:17%;">Sets a new value of</tdb>OSTEMPLATE</trb>parameter in container configuration file[[Man/ctid.conf.5|<b>ctid.conf<tr valign="top" align="left"/b>(5)]]. Requires <td width="11%"b>--save</tdb>flag. Usefulafter a change/upgrade of a distribution running insidecontainer, as vzctl uses the value of OSTEMPLATE to rundistribution-specific scripts.<td width="6%"/p>
<pstyle="margin-left:11%;"><b>K--stop-timeout</b>, <bi>kseconds</bi></p></td><td width="5%"></td><td width="44%">
<p>kilobytes;</p></td><td widthstyle="34margin-left:17%;">Sets a time to wait forcontainer to stop on </tdb>vzctl stop</trb>before forcibly<tr valign="top" align="left">killing it, in seconds. Note this option can not be usedwithout <td width="11%"b>--save</tdb>flag.<td width="6%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Special valueof <b>P</b>, <b>p0</b>means to use compiled-in default.</p></td><td width="5%"></td><td width="44%">
<p>memory pages (arch-specific).</p></td><td width="34%"></td></tr></table>=== Networking ====
<p style="margin-left:11%; margin-top: 1em">You can alsospecify the literal word <b>unlimited</b> in place of anumber. In that case the corresponding value will be set to<b>LONG_MAX</b>, i. e. the maximum possible value. <b><br>--numprocipadd</b> <i>items</i>[:<i>itemsaddr</i>]</p>
<p style="margin-left:2217%;">Maximum number of processes andAdds an IP address <i>addr</i>kernel-level threadsto a given container. Setting Address can optionally have a netmaskspecified in the barrier and the limit CIDR notation (e.g. <b>10.1.2.3/25</b>).Note that this option is incremental, so <i>addr</i> areadded todifferent values does not make practical sensealready existing ones.</p>
<p style="margin-left:11%;"><b>--numtcpsockipdel</b><i>itemsaddr</i>[:|<ib>itemsall</ib>]</p>
<p style="margin-left:2217%;">Maximum number of TCP socketsRemoves IP address <i>addr</i>from a container.This parameter limits If you want to remove all the number of TCP connections andaddresses,thus, the number of clients the server application canhandle in parallel. Setting the barrier and the limit todifferent values does not make practical senseuse <b>--ipdel all</b>.</p>
<p style="margin-left:11%;"><b>--numothersockhostname</b><i>itemsname</i>[:<i>items</i>]</p>
<p style="margin-left:2217%;">Maximum number of non-TCPsockets (local sockets, UDP and other types of sockets)Sets container hostname.Setting <b>vzctl</b> writes it to the barrier and the limit to different values doesappropriate file inside anot make practical sensecontainer (distribution-dependent).</p>
<p style="margin-left:11%;"><b>--vmguarpagesnameserver</b><i>pagesaddr</i>[:<i>pages</i>]</p>
<p style="margin-left:2217%;">Memory allocation guarantee.Sets DNS server IP address forThis parameter controls how much memory is available to acontainer. The barrier is the amount of memory thatIf you want to set several nameservers, youshould do it at once, so use <b>--nameserver</b> optioncontainer&rsquo;s applications are guaranteed multiple times in one call to be able toallocate. The meaning of <b>vzctl</b>, as all the limit is currently unspecified;nameit should be server values set in previous calls to <b>unlimitedvzctl</b>areoverwritten.</p>
<p style="margin-left:1117%;margin-top: 1em">A special valueof <b>--kmemsizeinherit</b>can be used to auto-propagate nameservervalue(s) from the host system&rsquo;s<ib>bytes</i>[:<i>bytesetc/resolv.conf</ib>]file.</p>
<p style="margin-left:2211%;">Maximum amount of kernel memoryused. This parameter is related to <b>--numprocsearchdomain</b>. Eachprocess consumes certain amount of kernel memory - 16 KB atleast, 30-50 KB typically. Very large processes may consumea bit more. It is important to have a certain safety gapbetween the barrier and the limit of this parameter: equalbarrier and limit may lead to the situation where the kernelwill need to kill container&rsquo;s applications to keep the<bi>kmemsizename</bi> usage under the limit.</p>
<p style="margin-left:1117%;">Sets DNS search domains for acontainer. If you want to set several search domains, youshould do it at once, so use <b>--tcpsndbufsearchdomain</b>optionmultiple times in one call to <ib>bytesvzctl</ib>[:, as all thesearch domain values set in previous calls to <ib>bytesvzctl</ib>]are overwritten.</p>
<p style="margin-left:2217%;margin-top: 1em">Maximum size A special valueof TCP sendbuffers. Barrier should <b>inherit</b> can be not less than 64 KB, anddifference between barrier and limit should be equal used to orauto-propagate searchmore than domain value of (s) from the host system&rsquo;s<b>numtcpsock/etc/resolv.conf</b> multiplied by 2.5KBfile.</p>
<p style="margin-left:11%;"><b>--tcprcvbufnetif_add</b><i>bytesifname[</i>,<i>mac</i>[,<i>host_ifname</i>,<i>host_mac</i>,<i>bridge]</i></p> <p style="margin-left:17%;">Adds a virtual Ethernet device(veth) to a given container. Here <i>ifname</i> is theEthernet device name in the container, <i>mac</i> is its MACaddress, <i>host_ifname</i> is the Ethernet device name onthe host, and <i>host_mac</i> is its MAC address. MACaddresses should be in the format like XX:XX:XX:XX:XX:XX.<i>bridge</i>bytesis an optional parameter which can be used incustom network start scripts to automatically add theinterface to a bridge. All parameters except <i>ifname</i>]are optional and are automatically generated if notspecified.</p>
<p style="margin-left:2211%;">Maximum size of TCP receive<b>--netif_del</b>buffers. Barrier should be not less than 64 KB, anddifference between barrier and limit should be equal to ormore than value of <i>dev_name</i> | <b>numtcpsockall</b> multiplied by 2.5KB.</p>
<p style="margin-left:1117%;">Removes virtual Ethernet devicefrom a container. If you want to remove all devices, use<b>--othersockbufall</b><i>bytes</i>[:<i>bytes</i>].</p>
==== veth interface configuration ==== <p style="margin-left:2211%;margin-top: 1em">Maximum size of other (nonThe followingoptions can be used to reconfigure the already-TCP)createdsocket send buffersvirtual Ethernet interface. If container&rsquo;s processes needs To select the interface tosend very large datagramsconfigure, the barrier should be setaccordinglyuse <b>--ifname</b> <i>name</i> option. Increased limit is necessary for high<b><br>performance of communications through local (UNIX-domain)sockets.-mac</b> <i>XX:XX:XX:XX:XX:XX</i></p>
<p style="margin-left:1122%;"><b>--dgramrcvbuf</b>MAC address of interface inside<i>bytes</i>[:<i>bytes</i>]a container.</p>
<p style="margin-left:2211%;">Maximum size of other (non<b>-TCP)-host_ifname</b>socket receive buffers. If container&rsquo;s processes needsto receive very large datagrams, the barrier should be setaccordingly. The difference between the barrier and thelimit is not needed.<i>name</i></p>
<p style="margin-left:1122%;"><b>--oomguarpages</b>interface name for virtual<i>pages</i>[:<i>pages</i>]interface in the host system.</p>
<p style="margin-left:2211%;">Guarantees against OOM kill.Under this beancounter the kernel accounts the total amountof memory and swap space used by the container&rsquo;sprocesses. The barrier of this parameter is theout-of-memory guarantee. If the <b>oomguarpages--host_mac</b> usage isbelow the barrier, processes of this container areguaranteed not to be killed in out-of-memory situations. Themeaning of limit is currently unspecified; it should be setto <bi>unlimitedXX:XX:XX:XX:XX:XX</bi>.</p>
<p style="margin-left:1122%;"><b>--lockedpages</b>MAC address of interface in the<i>pages</i>[:<i>pages</i>]host system.</p>
<p style="margin-left:22%;margin-top: 1em">Maximum number of pagesIf you want anindependent communication with the Container through thebridge, you should specify a multicast MAC address hereacquired by <b>mlock</b>(2FE:FF:FF:FF:FF:FF).</p>
<p style="margin-left:11%;"><b>--privvmpagesbridge</b><i>pagesname</i>[:<i>pages</i>]</p>
<p style="margin-left:22%;">Allows controlling the amountof memory allocated by the applicationsBridge name. For shared (mappedas <b>MAP_SHARED</b>) pages, each container really using aCustom networkmemory page is charged for start scripts can use this value to automatically add the fraction of the page(depending on the number of others using it). For&quot;potentially private&quot; pages (mapped as<b>MAP_PRIVATE</b>), container is charged either for interface to afraction of the size or for the full size if the allocatedaddress space. In the latter case, the physical pagesassociated with the allocated address space may be inmemory, in swap or not physically allocated yetbridge.</p>
<p style="margin-left:2211%; "><b>--mac_filter on</b> |<b>off</b></p> <p style="margin-topleft: 1em22%;">The barrier Enables/disables MAC addressfiltering for the Container veth device andthe possibilityof configuring the limit MAC address of this parameter control device from insidethe upper boundary ofContainer. If the filtering is turned on: <br>&bull; the total size veth device accepts only those packets that havea MAC address in their headers corresponding to that of allocated memory. Note that this upperboundary does not guarantee that container will be able todevice (excluding all broadcast and multicast packets); <br>allocate that much memory. The primary mechanism &bull; it is impossible to controlmodify the veth MAC address frommemory allocation is inside the <b>--vmguarpages</b> guaranteeContainer.</p>
<p style="margin-left:1122%;margin-top: 1em"><b>--shmpages</b>By default,this functionality is enabled for all veth devices existing<i>pages</i>[:<i>pages</i>]inside the Container.</p>
<p style="margin-left:22%;">Maximum IPC SHM segment size.Setting the barrier and the limit to different values doesnot make practical sense.</p>=== VSwap limits ====
<p style="margin-left:11%;margin-top: 1em"><b>The followingoptions sets memory and swap limits for VSwap--numfile</b>enabled<i>items</i>[:<i>items</i>]kernels (kernel version 042stab042 or greater).</p>
<p style="margin-left:2211%;margin-top: 1em">Maximum number of open filesArgument is inbytes, unless otherwise specified by an optional suffix.In most cases the barrier and the limit should be set to theAvailable suffixes are:</p> <p style="margin-left:11%; margin-top: 1em">&bull;<b>T</b>, <b>t</b> - terabytes; <br>&bull; <b>G</b>, <b>g</b> - gigabytes; <br>&bull; <b>M</b>, <b>m</b> - megabytes; <br>same value. Setting the barrier to &bull; <b>K</b>, <b>0k</b> effectively- kilobytes; <br>disables pre&bull; <b>P</b>, <b>p</b> - memory pages (arch-charging optimization for this beancounter inspecific,usually 4KB); <br>the kernel&bull; <b>B</b>, which leads to <b>b</b> - bytes (this is the held value being precise butdefault).<b><br>could slightly degrade file open performance.--ram</b> <i>bytes</i></p>
<p style="margin-left:1122%;">Sets physical memory (RAM)available to a container. Actually, the option is a shortcutfor setting <b>--numflockphyspages</b>limit (the barrier is set to<i>items</i>[:<i>items</i>]0).</p>
<p style="margin-left:2211%;">Maximum number of file locks.Safety gap should be between barrier and limit.<b>--swap</b> <i>bytes</i></p>
<p style="margin-left:1122%;">Set swap space available to acontainer. Actually, the option is a shortcut for setting<b>--numptyswappages</b><i>items</i>[:<i>items</i>]limit (the barrier is set to 0).</p>
<p style="margin-left:2211%;">Number of pseudo<b>--terminalsvm_overcommit</b>(PTY). Note that in OpenVZ each container can have not morethan 255 PTYs. Setting the barrier and the limit todifferent values does not make practical sense.<i>float</i></p>
<p style="margin-left:1122%;">Set VM overcommitment value to<bi>--numsiginfofloat</bi>. If set, it is used to calculate<ib>itemsprivmmpages</ib>[:parameter in case it is not setexplicitly (see below). Default value is <ib>items0</ib>], meaningunlimited privvmpages.</p>
<p style="margin-left:2211%;margin-top: 1em">Number of siginfo structures.<b>vzctl</b>Setting the barrier checks if running kernel is VSwap capable, and the limit refuses to different values doesnot make practical senseuse these parameters otherwise. This behavior can beoverriden by using <b>--force</b> flag beforeparameters.</p>
<p style="margin-left:11%;margin-top: 1em"><b>--dcachesize</b>In VSwap mode,all beancounters other than RAM and swap become optional.Note though that if some optional beancounters are not set,they are calculated and set by vzctl implicitly, using the<i>bytes</i>[following formulae:<i>bytes</i>]</p>
<p style="margin-left:2211%;margin-top: 1em">Maximum size offilesystem-related caches, such as directory entry and inode<b>&bull;cacheslockedpages. Exists as a separate parameter to impose a limitcausing file operations to sense memory shortage and returnan errno to applications, protecting from memory shortagesduring critical operations that should not failbarrier = oomguarpages. Safety gapshould be between barrier and limit.= ram</b></p>
<p style="margin-left:11%;margin-top: 1em"><b>--numiptent&bull;lockedpages.limit = oomguarpages.limit = unlimited</b><i>num</i>[:<i>num</i>]</p>
<p style="margin-left:2211%;margin-top: 1em">Number of iptables (netfilter)<b>&bull;entriesvmguarpages. Setting the barrier and the = vmguarpages.limit to differentvalues does not make practical sense.= ram + swap</b></p>
<p style="margin-left:11%;margin-top: 1em"><b>--physpages&bull;privvmpages.barrier = privvmpages.limit = (ram + swap) *vm_overcommit</b><i>pages</i>[:<i>pages</i>]</p>
<p style="margin-left:2211%;margin-top: 1em">On VSwap-enabled kernels, thislimits the amount of physical memory (RAM) available to aifcontainer. The barrier should be set to <b>vm_overcommit</b> is <b>0</b>or not set, and thelimit <b>privvmpages</b> is set to a total size of RAM that can be used used by acontainer.&quot;unlimited&quot;)</p>
<p style="margin-left:2211%; margin-top: 1em">For olderkernels, this Here is an accounting-only parameter, showing theusage example of RAM by this setting container. Barrier should be set 777 tohave 512 megabytes of<b>0</b>, RAM and limit should be set to <b>unlimited</b>.1 gigabyte of swap:</p>
<p pre style="margin-left:11%;"><b> vzctl set 777 --ram 512M --swap 1G --swappages</b><i>pages</i>[:<i>pages</i>]save</ppre>
<p style="margin-left:22%;">The limit, if set, is used toshow a total amount of swap space available inside thecontainer. The barrier of this parameter is currentlyignored. The default value is <b>unlimited</b>, meaningtotal swap will be reported as 0.</p>=== User Beancounter limits ====
<p style="margin-left:2211%; margin-top: 1em">Note that inThe followingorder options sets barrier and limit for the value to be shown as total swap space,various user<b>--meminfo</b> parameter should be set to value other than<b>none</b>beancounters.</p>
<p style==== CPU fair scheduler parameters ===="margin-left:11%; margin-top: 1em">Note that forVSwap-enabled kernels (version 042stab042 or greater) theselimits are optional, you must only set <b>--ram</b> and<b>--swap</b> (see above). For older kernels, these limitsare obligatory.</p>
<p style="margin-left:11%; margin-top: 1em">TheseEach optionparameters control CPU usage by containerrequires one or two arguments. In case of one argument,<b>vzctl<br/b>sets barrier and limit to the same value. Incase of two colon--cpuunitsseparated arguments, the first is abarrier, and the second is a limit. Each argument is eithera number, a number with a suffix, or a special value</b> <i>numunlimited</ib>.</p>
<p style="margin-left:2211%;margin-top: 1em">CPU weight for a container.Arguments areArgument is positive non-zero numberin items, passed to and used inthe kernel fair schedulerpages or bytes. The larger the number Note that page size is, themore CPU time this container gets. Maximum value is 500000architecture-specific,minimal it is 8. Number is relative to weights of all the otherrunning containers. If <b>cpuunits</b> are not specified,4096 bytes on x86 and x86_64default value of 1000 is usedplatforms.</p>
<p style="margin-left:2211%; margin-top: 1em">You can set CPUalsoweight specify different suffixes for CT0 User Beancounter parameters(host system itselfexcept for those which names start with <b>num</b>) as well (use . Forexample, <b>vzctlset 0 --cpuunits</b> <i>numCTID</i>). Usually, OpenVZ initscript<b>--privvmpages(5M:6M</b> should set <b>/etc/init.d/vzprivvmpages</b>) takes care of setting this&rsquo; barrier to 5megabytes and its limit to 6 megabytes.</p>
<p style="margin-left:11%;margin-top: 1em"><b>--cpulimit</b>Available<i>num</i>[<b>%</b>]suffixes are:</p>
<p style="margin-left:2211%;margin-top: 1em">Limit of CPU usage for the&bull;container<b>T</b>, in per cent. Note if the computer has 2 CPUs<b>t</b> - terabytes; <br>&bull; <b>G</b>, it<b>g</b> - gigabytes; <br>has total of 200% CPU time. Default CPU limit is &bull; <b>M</b>, <b>m</b> - megabytes; <br>&bull; <b>K</b>, <b>0k</b> - kilobytes; <br>&bull; <b>P</b>, <b>p</b> - memory pages (no CPU limitarch-specific,usually 4KB); <br>&bull; <b>B</b>, <b>b</b> - bytes.</p>
<p style="margin-left:11%;margin-top: 1em">You can alsospecify the literal word <b>unlimited</b> in place of anumber. In that case the corresponding value will be set to<b>LONG_MAX</b>, i. e. the maximum possible value. <b><br>--cpusnumproc</b> <i>numitems</i>[:<i>items</i>]</p>
<p style="margin-left:22%;">sets Maximum number of CPUs availableprocesses andin kernel-level threads. Setting the containerbarrier and the limit todifferent values does not make practical sense.</p>
<p style="margin-left:11%;"><b>--cpumasknumtcpsock</b> <i>cpusitems</i> |[:<bi>allitems</bi>]</p>
<p style="margin-left:22%;">sets list Maximum number of allowed CPUs forTCP sockets.This parameter limits the container. Input format is a comma-separated list number ofdecimal numbers TCP connections and ranges. Consecutively set bits are shown,as two hyphen-separated decimal numbersthus, the smallest andnumber of clients the server application canlargest bit numbers set handle in parallel. Setting the range. For example, if youwant barrier and the container limit to execute on CPUs 0, 1, 2, 7, you shouldpass <b>0-2,7</b>. Default value is <b>all</b> (thecontainer can execute on any CPU)different values does not make practical sense.</p>
<p style==== Memory output parameters ===="margin-left:11%;"><b>--numothersock</b><i>items</i>[:<i>items</i>]</p>
<p style="margin-left:1122%; margin-top: 1em">This parameterMaximum number of non-TCPcontrol output sockets (local sockets, UDP and other types of /proc/meminfo inside a containersockets). <b><br>--meminfo none</b>Setting the barrier and the limit to different values doesnot make practical sense.</p>
<p style="margin-left:2211%;">No <b>--vmguarpages</procb><i>pages</meminfo virtualization(the same as on host system).i>[:<i>pages</i>]</p>
<p style="margin-left:1122%;">Memory allocation guarantee.This parameter controls how much memory is available to acontainer. The barrier is the amount of memory thatcontainer&rsquo;s applications are guaranteed to be able toallocate. The meaning of the limit is currently unspecified;it should be set to <b>--meminfounlimited</b><i>mode</i>:<i>value</i>.</p>
<p style="margin-left:2211%;">Configure total memory outputin a container. Reported free memory is evaluatedaccordingly to the mode being set. Reported swap isevaluated according to the settings of <b>--swappageskmemsize</b>parameter.<i>bytes</i>[:<i>bytes</i>]</p>
<p style="margin-left:22%; margin-top: 1em">You can use theMaximum amount of kernel memoryfollowing modes for <i>mode</i>: <br>&bull; used. This parameter is related to <b>pages--numproc</b>. Eachprocess consumes certain amount of kernel memory - 16 KB atleast, 30-50 KB typically. Very large processes may consumea bit more. It is important to have a certain safety gapbetween the barrier and the limit of this parameter:<i>value</i> - sets total memory inequalpages; <br>barrier and limit may lead to the situation where the kernelwill need to kill container&bullrsquo; <b>privvmpages</b>:<i>value</i> - sets total memorys applications to keep theas <b>privvmpageskmemsize</b> * <i>value</i>usage under the limit.</p>
<p style="margin-left:2211%; margin"><b>-top: 1em"-tcpsndbuf</b>Default is<bi>bytes</i>privvmpages[:1<i>bytes</bi>.]</p>
<p style="margin-left:22%; margin-top: 1em">Note that ifMaximum size of TCP send<b>--physpages</b> is set on a VSwap-enabled kernelbuffers. Barrier should be not less than 64 KB, itanddifference between barrier and limit should be equal to ortakes a precedence over more than value of <b>--meminfonumtcpsock</b>, imultiplied by 2.e. setting5<b>--meminfo</b> does not take any effectKB.</p>
<p style==== iptables control parameters ===="margin-left:11%;"><b>--tcprcvbuf</b><i>bytes</i>[:<i>bytes</i>]</p>
<p style="margin-left:22%;">Maximum size of TCP receivebuffers. Barrier should be not less than 64 KB, anddifference between barrier and limit should be equal to ormore than value of <b>numtcpsock</b> multiplied by 2.5KB.</p> <p style="margin-left:11%;"><b>--iptablesothersockbuf</b><i>namebytes</i>[:<i>bytes</i>]</p>
<p style="margin-left:22%;">Allow Maximum size of other (non-TCP)socket send buffers. If container&rsquo;s processes needs to use send very large datagrams, the functionalitybarrier should be setof <i>name</i> iptables module inside the containeraccordingly. Tospecify multiple <i>name</i>s, repeat --iptables Increased limit is necessary for each,highor use spaceperformance of communications through local (UNIX-separated list as an argument (enclosed indomain)single or double quotes to protect spaces)sockets.</p>
<p style="margin-left:2211%; margin-top: 1em">The defaultlist of enabled iptables modules is specified by the<b>IPTABLES--dgramrcvbuf</b> variable in <i>bytes</i>[[Man/vz.conf.5|:<bi>vz.confbytes</bi>(5)]].</p>
<p style="margin-left:22%; margin-top: 1em">You can use theMaximum size of other (non-TCP)following values for <i>name</i>: <b>iptable_filter</b>,socket receive buffers. If container&rsquo;s processes needs<b>iptable_mangle</b>, <b>ipt_limit</b>to receive very large datagrams,the barrier should be set<b>ipt_multiport</b>, <b>ipt_tos</b>, <b>ipt_TOS</b>,<b>ipt_REJECT</b>, <b>ipt_TCPMSS</b>, <b>ipt_tcpmss</b>,accordingly. The difference between the barrier and the<b>ipt_ttl</b>, <b>ipt_LOG</b>, <b>ipt_length</b>,<b>ip_conntrack</b>, <b>ip_conntrack_ftp</b>,<b>ip_conntrack_irc</b>, <b>ipt_conntrack</b>,<b>ipt_state</b>, <b>ipt_helper</b>, <b>iptable_nat</b>,<b>ip_nat_ftp</b>, <b>ip_nat_irc</b>, <b>ipt_REDIRECT</b>,<b>xt_mac</b>, <b>ipt_recent</b>, <b>ipt_owner</b>limit is not needed.</p>
<p style==== Network devices control parameters ===="margin-left:11%;"><b>--oomguarpages</b><i>pages</i>[:<i>pages</i>]</p>
<p style="margin-left:1122%;">Guarantees against OOM kill.Under this beancounter the kernel accounts the total amountof memory and swap space used by the container&rsquo;sprocesses. The barrier of this parameter is theout-of-memory guarantee. If the <b>--netdev_addoomguarpages</b>usage isbelow the barrier, processes of this container areguaranteed not to be killed in out-of-memory situations. Themeaning of limit is currently unspecified; it should be setto <ib>nameunlimited</ib>.</p>
<p style="margin-left:2211%;">move network device from the<b>--lockedpages</b>host system to a specified container<i>pages</i>[:<i>pages</i>]</p>
<p style="margin-left:1122%;">Maximum number of pagesacquired by <b>--netdev_delmlock</b><i>name</i>(2).</p>
<p style="margin-left:2211%;">delete network device from a<b>--privvmpages</b>specified container<i>pages</i>[:<i>pages</i>]</p>
<p style==== Disk quota parameters ===="margin-left:22%;">Allows controlling the amountof memory allocated by the applications. For shared (mappedas <b>MAP_SHARED</b>) pages, each container really using amemory page is charged for the fraction of the page(depending on the number of others using it). For&quot;potentially private&quot; pages (mapped as<b>MAP_PRIVATE</b>), container is charged either for afraction of the size or for the full size if the allocatedaddress space. In the latter case, the physical pagesassociated with the allocated address space may be inmemory, in swap or not physically allocated yet.</p>
<p style="margin-left:1122%;margin-top: 1em">The barrier andthe limit of this parameter control the upper boundary ofthe total size of allocated memory. Note that this upperboundary does not guarantee that container will be able toallocate that much memory. The primary mechanism to controlmemory allocation is the <b>--diskquota yes</b> |<b>novmguarpages</b>guarantee.</p>
<p style="margin-left:2211%;">allows to enable or disabledisk quota for a container. By default, a global value(<b>DISK_QUOTA--shmpages</b>) from <i>pages</i>[[Man/vz.conf.5|:<bi>vz.confpages</bi>(5)]] is used.</p>
<p style="margin-left:1122%;"><b>--diskspace</b>Maximum IPC SHM segment size.Setting the barrier and the limit to different values does<i>num</i>[:<i>num</i>]not make practical sense.</p>
<p style="margin-left:2211%;">sets soft and hard disk quotalimits, in blocks. First parameter is soft limit, second ishard limit. One block is currently equal to 1Kb. Suffixes<b>G--numfile</b>, <bi>Mitems</bi>, [:<bi>Kitems</bi> can also be specified (see<b>Resource limits</b> section for more info onsuffixes).]</p>
<p style="margin-left:1122%;">Maximum number of open files.In most cases the barrier and the limit should be set to thesame value. Setting the barrier to <b>--diskinodes0</b>effectively<i>num</i>[:<i>num</i>]disables pre-charging optimization for this beancounter inthe kernel, which leads to the held value being precise butcould slightly degrade file open performance.</p>
<p style="margin-left:2211%;">sets soft and hard disk quota<b>--numflock</b>limits, in <i-nodes. First parameter is soft limit, second ishard limit.>items</i>[:<i>items</i>]</p>
<p style="margin-left:1122%;"><b>--quotatime</b>Maximum number of file locks.<i>seconds</i>Safety gap should be between barrier and limit.</p>
<p style="margin-left:2211%;">sets quota grace period.<b>--numpty</b>Container is permitted to exceed its soft limits for thegrace period, but once it has expired, the soft limit isenforced as a hard limit.<i>items</i>[:<i>items</i>]</p>
<p style="margin-left:1122%;"><b>Number of pseudo--quotaugidlimit</b>terminals(PTY). Note that in OpenVZ each container can have not morethan 255 PTYs. Setting the barrier and the limit to<i>num</i>different values does not make practical sense.</p>
<p style="margin-left:2211%;">sets maximum number ofuser/group IDs in a container for which disk quota insidethe container will be accounted. If this value is set to<b>0--numsiginfo</b>, user and group quotas inside the container willnot be accounted.<i>items</i>[:<i>items</i>]</p>
<p style="margin-left:22%; margin-top: 1em">Note that ifNumber of siginfo structures.you have previously set value of this parameter Setting the barrier and the limit to <b>0</b>,different values doeschanging it while the container is running will not takeeffectmake practical sense.</p>
<p style==== Mount option ===="margin-left:11%;"><b>--dcachesize</b><i>bytes</i>[:<i>bytes</i>]</p>
<p style="margin-left:1122%;"><b>Maximum size offilesystem--noatime yes</b> |related caches, such as directory entry and inodecaches. Exists as a separate parameter to impose a limitcausing file operations to sense memory shortage and returnan errno to applications, protecting from memory shortagesduring critical operations that should not fail. Safety gap<b>no</b>should be between barrier and limit.</p>
<p style="margin-left:2211%;">Sets noatime flag (do not<b>--numiptent</b>update inode access times) on filesystem.<i>num</i>[:<i>num</i>]</p>
<p style==== Capability option ===="margin-left:22%;">Number of iptables (netfilter)entries. Setting the barrier and the limit to differentvalues does not make practical sense.</p>
<p style="margin-left:11%;"><b>--capabilityphyspages</b><i>capnamepages</i>[:<bi>onpages</b>|<b>off</bi>]</p>
<p style="margin-left:22%;">Sets a capability for On VSwap-enabled kernels, thislimits the amount of physical memory (RAM) available to acontainer. Note that setting capability when The barrier should be set to <b>0</b>, and the containeris running does not take immediate effect; restart thecontainer in order for the changes limit to take effect. Note a total size of RAM that can be used used by acontainer has default set of capabilities, thus anyoperation on capabilities is &quot;logical and&quot; withthe default capability mask.</p>
<p style="margin-left:22%; margin-top: 1em">You can use theFor olderfollowing values for <i>capname</i>: <b>chown</b>kernels,<b>dac_override</b>, <b>dac_read_search</b>, <b>fowner</b>this is an accounting-only parameter,showing the<b>fsetid</b>, <b>kill</b>, <b>setgid</b>, <b>setuid</b>,<b>setpcap</b>, <b>linux_immutable</b>,<b>net_bind_service</b>, <b>net_broadcast</b>,<b>net_admin</b>, <b>net_raw</b>, <b>ipc_lock</b>,usage of RAM by this container. Barrier should be set to<b>ipc_owner0</b>, and limit should be set to <b>sys_module</b>, <b>sys_rawio</b>,<b>sys_chroot</b>, <b>sys_ptrace</b>, <b>sys_pacct</b>,<b>sys_admin</b>, <b>sys_boot</b>, <b>sys_nice</b>,<b>sys_resource</b>, <b>sys_time</b>, <b>sys_tty_config</b>,<b>mknod</b>, <b>lease</b>, <b>setveid</b>, <b>ve_admin</b>.For detailed description, see <b>capabilitiesunlimited</b>(7).</p>
<p style="margin-left:2211%; margin-top: 1em"><b>WARNING--swappages</b>:setting some of those capabilities may have far reachingsecurity implications, so do not do it unless you know whatyou are doing. Also note that setting <bi>pages</i>setpcap[:on<i>pages</bi> fora container will most probably lead to inability to startit.]</p>
<p style==== Device access management ===="margin-left:22%;">For VSwap-enabled kernels(042stab042 or greater), this parameter limits the amount ofswap space available to a container. The barrier should beset to <b>0</b>, and the limit to a total size of swap thatcan be used by a container.</p>
<p style="margin-left:1122%;margin-top: 1em"><b>For older(pre--devnodes</b>VSwap) kernels, the limit is used to show a totalamount of swap space available inside the container. Thebarrier of this parameter is ignored. The default value is<i>device</i>:[<b>r</b>][<b>w</b>][<b>q</b>]|<b>noneunlimited</b>, meaning total swap will be reported as0.</p>
<p style="margin-left:22%;">Give the container an access(<b>r</b> - read, <b>w</b> - write, <b>q</b> - disk quotamanagement, <b>none</b> - no access) to a device designatedby the special file /dev/<i>device</i>. Device file iscreated in a container by <b>vzctl</b>. Example: <b>vzctlset 777 --devnodes sdb:rwq</b>.</p>=== CPU fair scheduler parameters ====
<p style="margin-left:11%;margin-top: 1em"><b>--devicesThesebparameters control CPU usage by container. </b>|<bbr>c--cpuunits</b>:<i>majornum</i>:<i>minor</i>|<b>all</b>:[<b>r</b>][<b>w</b>][<b>q</b>]|<b>none</b></p>
<p style="margin-left:22%;">Give CPU weight for a container.Argument is positive non-zero number, passed to and used inthe kernel fair scheduler. The larger the number is, the more CPU time this container an access gets. Maximum value is 500000,minimal is 8. Number is relative toweights of all the othera running containers. If <b>bcpuunits</b>lock or <b>c</b>haracter device designated by its<i>major</i> and <i>minor</i> numbers. Device file have toare not specified,be created manuallydefault value of 1000 is used.</p>
<p style==== PCI device management ===="margin-left:22%; margin-top: 1em">You can set CPUweight for CT0 (host system itself) as well (use <b>vzctlset 0 --cpuunits</b> <i>num</i>). Usually, OpenVZ initscript(<b>/etc/init.d/vz</b>) takes care of setting this.</p>
<p style="margin-left:11%;"><b>--pci_addcpulimit</b>[<i>domainnum</i>:][<ib>bus%</i>:<i>slot</i>.<i>func</ib>]</p>
<p style="margin-left:22%;">Give Limit of CPU usage for the container an access to, in per cent. Note if the computer has 2 CPUs, ita specified PCI devicehas total of 200% CPU time. All numbers are hexadecimal (asprinted by Default CPU limit is <b>lspci0</b>(8) in the first columnno CPU limit).</p>
<p style="margin-left:11%;"><b>--pci_delcpus</b>[<i>domain</i>:]<i>bus</i>:<i>slot</i>.<i>funcnum</i></p>
<p style="margin-left:22%;">Delete a PCI device from sets number of CPUs availablein thecontainer.</p>
<p style="margin-left:2211%; margin-top: 1em">Note that<b>vps-pci-cpumask</b> configuration script is executed by<i>cpus</i> |<b>vzctlauto</b> then configuring PCI devices. The script isusually located at | <b>/usr/lib[64]/vzctl/scripts/all</b>.</p>
<p style==== Features management ===="margin-left:22%;">Sets list of allowed CPUs forthe container. Input format is a comma-separated list ofdecimal numbers and/or ranges. Consecutively set bits areshown as two hyphen-separated decimal numbers, the smallestand largest bit numbers set in the range. For example, ifyou want the container to execute on CPUs 0, 1, 2, 7, youshould pass <b>0-2,7</b>. Default value is <b>all</b> (thecontainer can execute on any CPU). If used with the<b>--nodemask</b> option, value of <b>auto</b> assigns allCPUs from the specified NUMA node to a container.</p>
<p style="margin-left:11%;"><b>--featuresnodemask</b><i>namenodes</i>:<b>on</b>|<b>offall</b></p>
<p style="margin-left:22%;">Enable or disable a specificSets list of allowed NUMA nodesfor the container feature. Known features are: <b>sysfs</b>,Input format is the same as for<b>nfs--cpumask</b>, <b>sit</b>, <b>ipip. Note that </b>, <b>ppp--nodemask</b>,must be usedwith the <b>ipgre</b>, <b>bridge</b>, <b>nfsd--cpumask</b>option.</p>
==== Apply config Memory output parameters ====
<p style="margin-left:11%;margin-top: 1em">ForVSwap-enabled kernels (042stab042 or greater), thisparameter is ignored. For older kernels, it controls theoutput of /proc/meminfo inside a container. <b><br>--applyconfigmeminfo none</b><i>name</i></p>
<p style="margin-left:22%;">Read container parameters fromthe container sample configuration file<tt>/etc/vz/conf/ve-</tt><i>name</i><tt>.conf-sample<No /tt>,and apply them, if <b>--save<proc/b> option specified save tomeminfo virtualization(the container config file. The following parameters are notchanged: <b>HOSTNAME</b>, <b>IP_ADDRESS</b>,<b>OSTEMPLATE</b>, <b>VE_ROOT</b>, and<b>VE_PRIVATE</b>same as on host system).</p>
<p style="margin-left:11%;"><b>--applyconfig_mapmeminfo</b><i>groupmode</i>:<i>value</i></p>
<p style="margin-left:22%;">Apply Configure total memory outputin a container config. Reported free memory is evaluatedaccordingly to the mode being set. Reported swap isparameters selected by evaluated according to the settings of <ib>group--swappages</ib>parameter. Now </p> <p style="margin-left:22%; margin-top: 1em">You can use the only possiblevalue following modes for <i>groupmode</i> is : <br>&bull; <b>namepages</b>: to restore container<i>value</i> - sets total memory inpages; <br>name based on &bull; <b>NAMEprivvmpages</b> variable in container:<i>value</i> - sets total memoryconfiguration fileas <b>privvmpages</b> * <i>value</i>.</p>
<p style==== I"margin-left:22%; margin-top: 1em">Default is<b>privvmpages:1</b>.</O priority management ====p>
<p style="margin-left:11%;"><b>--ioprio</b><i>priority</i></p>=== Netfilter (iptables) control parameters ====
<p style="margin-left:2211%;">Assigns I/O priority tocontainer. <i>Priority</i> range is <b>0-7-netfilter&nbsp;disabled</b>. The greater|<ib>prioritystateless</ib> is, the more time for I/O activity containerhas. By default each container has |<ib>prioritystateful</ib> of|<b>4full</b>.</p>
<p style=== Checkpointing and restore ==="margin-left:22%;">Restrict access tonetfilter/iptables modules for a container. This optionreplaces obsoleted <b>--iptables</b>.</p>
<p style="margin-left:22%; margin-top: 1em">Checkpointing is a feature ofNote thatOpenVZ kernel which allows to save a complete state of arunning changing this parameter requires containerrestart, and to restore it latersoconsider using <b>--setmode</b> option.</p>
<p style="margin-left:1122%;margin-top: 1em">The followingarguments can be used: <b>chkpnt</b> <i>CTID</ibr>[<b>--dumpfile&bull; disabled</b> <i>name</i>]</p>
<p style="margin-left:1732%;">This command saves a completestate of a running container to a dump file, and stops thecontainer. If an option <b>--dumpfile</b> is not set,default dump file name <b>/vz/dump/Dump.</b><i>CTID</i> isused.no modules are allowed</p>
<p style="margin-left:1122%;"><b>restore</b> <i>CTID</i>[<b>--dumpfile&bull; stateless</b> <i>name</i>]</p>
<p style="margin-left:1732%;">This command restores aall modules except NAT andcontainer from conntracks are allowed (i.e. filter and mangle); this is the dump file created by the <b>chkpnt</b>command.default</p>
<p style=== Performing container actions ==="margin-left:22%;"><b>&bull; stateful</b></p>
<p style="margin-left:1132%;"><b>create</b> <i>CTID</i>[<b>--ostemplate</b> <i>name</i>] [<b>--config</b><i>name</i>] [<b>--private</b> <i>path</i>] <br>[<b>--root</b> <i>path</i>] [<b>--ipadd</b> <i>addr</i>]all modules except NAT are[<b>--hostname</b> <i>name</i>]allowed</p>
<p styletable width="margin-left:17100%;" border="0" rules="none" frame="void" cellspacing="0" cellpadding="0">Creates a new container area.This operation should be done once, before the first start<tr valign="top" align="left">of the container.<td width="22%"></ptd><td width="9%">
<p style="margin-left:17%; margin-top: 1em">If the<b>--config&bull; full</b> option is specified, values from exampleconfiguration file<b>/etc/vz/conf/ve-</bp><i>name</itd><btd width="1%">.conf-sample</btd> areput into the container configuration file. If this containerconfiguration file already exists, it will be removed.</ptd width="36%">
<p style="margin-left:17%; margin-top: 1em">You can use<b>--rootall modules are allowed</b> <ip>path</itd> option to sets the path to themount point for the container root directory (default is<btd width="32%">VE_ROOT</btd> specified in [[Man/vz.conf.5|<b>vz.conf</btr>(5)]] file).Argument can contain literal string <b>$VEID</b>, which willbe substituted with the numeric CT ID.</ptable>
<p style="margin-left:1711%; margin-top: 1em">You can use<b>--privateiptables</b> <i>pathname</i> option to set the path todirectory in which all the files and directories specific tothis very container are stored (default is [<b>VE_PRIVATE,</b>specified in [[Man/vz.conf.5|<b>vz.conf</b>(5)]] file). Argument can containliteral string <b>$VEID</b>, which will be substituted withthe numeric CT ID.</p>
<p style="margin-left:1722%; margin-top: 1em">You can use<b>--ipaddNote</b> this option isobsoleted, <ib>addr--netfilter</ib> option to assign an IP address toa container. Note that this option can should be used multipletimesinstead.</p>
<p style="margin-left:1722%; margin-top: 1em">You can Allow to usethe functionality of <bi>--hostnamename</bi> iptables module inside thecontainer. Multiple comma-separated <i>name</i> option to set a host name fors can bea containerspecified.</p>
<p style="margin-left:1122%;margin-top: 1em">The defaultlist of enabled iptables modules is defined by the<b>destroyIPTABLES</b> variable in [[Man/vz.conf.5|<b>deletevz.conf</b>(5)]].</p>
<p style="margin-left:1722%;margin-top: 1em">Removes a container privateYou can use thefollowing values for <i>name</i>: <b>iptable_filter</b>,<b>iptable_mangle</b>, <b>ipt_limit</b>,area by deleting all files<b>ipt_multiport</b>, <b>ipt_tos</b>, <b>ipt_TOS</b>,<b>ipt_REJECT</b>, <b>ipt_TCPMSS</b>, <b>ipt_tcpmss</b>,<b>ipt_ttl</b>, <b>ipt_LOG</b>, <b>ipt_length</b>,<b>ip_conntrack</b>, <b>ip_conntrack_ftp</b>,<b>ip_conntrack_irc</b>, <b>ipt_conntrack</b>,<b>ipt_state</b>, <b>ipt_helper</b>, <b>iptable_nat</b>,<b>ip_nat_ftp</b>, <b>ip_nat_irc</b>, <b>ipt_REDIRECT</b>, directories and theconfiguration file of this container<b>xt_mac</b>, <b>ipt_recent</b>, <b>ipt_owner</b>.</p>
<p style="margin-left:11%;"><b>start</b> [<b>--wait</b>][<b>--force</b>]</p>=== Network devices control parameters ====
<p style="margin-left:1711%;">Mounts (if necessary) andstarts a container. Unless <b>--waitnetdev_add</b> option isspecified, <bi>vzctlname</b> will return immediately; otherwisean attempt to wait till the default runlevel is reached willbe made by <b>vzctl</bi>.</p>
<p style="margin-left:1722%; margin-top: 1em">Specifymove network device from the<b>--force</b> if you want host system to start a specified container which isdisabled (see <b>--disabled</b>).</p>
<p style="margin-left:1711%; margin-top: 1em">Note that thiscommand can lead to execution of <b>premount--netdev_del</b>,<bi>mountname</b> and <b>start</b> action scripts (see <b>ACTIONSCRIPTS</bi> below).</p>
<p style="margin-left:1122%;"><b>stop</b> [<b>--fast</b>]delete network device from aspecified container</p>
<p style="margin-left:17%;">Stops and unmounts a container.Normally, <b>halt</b>(8) is executed inside a container;option <b>--fast</b> makes <b>vzctl</b> use <b>reboot</b>(2)syscall instead which is faster but can lead to uncleancontainer shutdown.</p>=== Disk quota parameters ====
<p style="margin-left:1711%; margin-top: 1em">Note that thiscommand can lead to execution of <b>stop</b>, <b>umount--diskquota yes</b>|and <b>postumount</b> action scripts (see <b>ACTIONSCRIPTSno</b> below).</p>
<p style="margin-left:1122%;">allows to enable or disabledisk quota for a container. By default, a global value(<b>restartDISK_QUOTA</b> ) from [<b>--wait<[Man/b>][vz.conf.5|<b>--forcevz.conf</b>(5)] [<b>--fast</b>]is used.</p>
<p style="margin-left:1722%;margin-top: 1em">Restarts a container, i.e.Note that thisstops it if it parameter is running, and starts again. Accepts all the<b>start</b> and ignored for <b>stopploop</b> optionslayout.</p>
<p style="margin-left:1711%; margin-top: 1em">Note that thiscommand can lead to execution of some action scripts (see<b>ACTION SCRIPTS--diskspace</b> below).<i>num</i>[:<i>num</i>]</p>
<p style="margin-left:1122%;">For <b>statussimfs</b>layout, setssoft and hard disk quota limits. First parameter is softlimit, second is hard limit.</p>
<p style="margin-left:1722%;margin-top: 1em">Shows a container statusFor<b>ploop</b> layout, initiates the procedure of resizing theploop image file to the new size. ThisSince there is nosoft/hard limit concept in ploop, second <i>num</i>, ifspecified, is a line with five or six words, separated by spacesignored.</p>
<p style="margin-left:1722%; margin-top: 1em">First word By default,ploop resize isdone online, i.e. on a mounted ploop. Thisis a preferred way of doing resize. Although, in a rare casea container was using lots of disk space and should now beresized to a much smaller size, an offline resize might bemore appropriate. In this case, make sure the container isstopped and unmounted and use additionalliterally <b>CTID--offline-resize</b>.option</p>
<p style="margin-left:1722%; margin-top: 1em">Second word Note that ploopresize isNOT performed on container start, so forthe numeric consistency <b>--diskspace<i/b>CT IDmust be used together with<b>--save</ib>flag.</p>
<p style="margin-left:1722%; margin-top: 1em">Third word isSuffixesshowing whether this container exists or not<b>G</b>, <b>M</b>, it can beeither <b>existK</b> or can also be specified (see<b>deletedResource limits</b>section for more info on suffixes).If suffix is not specified, value is in kilobytes.</p>
<p style="margin-left:1711%; margin-top: 1em">Fourth word isshowing the status of the container filesystem, it can beeither <b>mounted--diskinodes</b> or <bi>num</i>[:<i>unmountednum</bi>.]</p>
<p style="margin-left:1722%; margin-top: 1em">Fifth wordsets soft and hard disk quotashows if the container limits, in i-nodes. First parameter is runningsoft limit, it can be eithersecond is<b>running</b> or <b>down</b>hard limit.</p>
<p style="margin-left:1722%; margin-top: 1em">Sixth word, ifNote that thisexists, parameter is ignored for <b>suspendedploop</b>. It appears if both a containerand its dump file exist (see <b>chkpnt</b>)layout.</p>
<p style="margin-left:1711%; margin"><b>-top: 1em"-quotatime</b>This commandcan also be usable from scripts.<i>seconds</i></p>
<p style="margin-left:1122%;"><b>mount</b>sets quota grace period.Container is permitted to exceed its soft limits for thegrace period, but once it has expired, the soft limit isenforced as a hard limit.</p>
<p style="margin-left:1722%;margin-top: 1em">Mounts container private area.Note that this command can lead to execution of<b>premount</b> and <b>mount</b> action scripts (seeparameter is ignored for <b>ACTION SCRIPTSploop</b> below)layout.</p>
<p style="margin-left:11%;"><b>umount--quotaugidlimit</b><i>num</i></p>
<p style="margin-left:1722%;">Unmounts Enables or disablesin-container privateper-user and per-group disk quotas. If thearea. Note that this command can lead value is set to execution of<b>umount0</b> or not set, disk quotas inside thecontainer is disabled and <b>postumount</b> action scripts (see<b>ACTION SCRIPTS</b> below)not accounted.</p>
<p style="margin-left:1722%; margin-top: 1em">Note thatFor<b>stopsimfs</b> does <b>umount<layout containers, non-zero value sets maximumnumber of user/b> automaticallygroup IDs for which disk quota isaccounted.</p>
<p style="margin-left:1122%;margin-top: 1em">For<b>quotaonploop</b> <i>ctid<layout containers, any non-zero value enablesdisk quota inside the container; the number of user/i>groupIDs used by disk quota is not limited by OpenVZ.</p>
<p style="margin-left:1722%;margin-top: 1em">Turn Note thatenabling or disabling in-container disk quota on. Not thatquotas requirescontainer restart, so consider using <b>mount--setmode</b> and <b>start</b> does that automaticallyoption.</p>
<p style="margin-left:11%;"><b>quotaoff</b> <i>ctid</i></p>=== Capability option ====
<p style="margin-left:1711%;">Turn disk quota off. Not that<b>--capability</b><i>capname</i>:<b>on</b>|<b>umountoff</b> and [<b>stop,</b> does that automatically...]</p>
<p style="margin-left:1122%;"><b>quotainit</b>Sets a capability for acontainer. Multiple comma-separated capabilities can be<i>ctid</i>specified.</p>
<p style="margin-left:1722%;margin-top: 1em">Initialize disk quota (i.e. runNote that<b>vzquota init</b>) with setting a capability when the parameters taken from container is running does nottake immediate effect; restart the CTcontainer in order forconfiguration file [[Man/ctid.conf.5|the changes to take effect (consider using <b>ctid.conf--setmode</b>(5option)]].</p>
<p style="margin-left:1122%;margin-top: 1em"><b>exec</b> <i>CTIDA container hasthe default set of capabilities, thus any operation oncapabilities is &quot;logical AND&quot; with the defaultcommand</i>capability mask.</p>
<p style="margin-left:1722%;margin-top: 1em">Executes You can use thefollowing values for <i>commandcapname</i> in a: <b>chown</b>,<b>dac_override</b>, <b>dac_read_search</b>, <b>fowner</b>,<b>fsetid</b>, <b>kill</b>, <b>setgid</b>, <b>setuid</b>,<b>setpcap</b>, <b>linux_immutable</b>,<b>net_bind_service</b>, <b>net_broadcast</b>,<b>net_admin</b>, <b>net_raw</b>, <b>ipc_lock</b>,<b>ipc_owner</b>, <b>sys_module</b>, <b>sys_rawio</b>,<b>sys_chroot</b>, <b>sys_ptrace</b>, <b>sys_pacct</b>,container. Environment variables are not set inside the<b>sys_admin</b>, <b>sys_boot</b>, <b>sys_nice</b>,container. Signal handlers may differ from default settings.<b>sys_resource</b>, <b>sys_time</b>, <b>sys_tty_config</b>,If <ib>mknod</b>, <b>commandlease</ib> is , <b>-setveid</b>, commands are read from<b>ve_admin</b>.stdinFor detailed description, see <b>capabilities</b>(7).</p> <p style="margin-left:1122%;margin-top: 1em"><b>exec2WARNING</b> :setting some of those capabilities may have far reachingsecurity implications, so do not do it unless you know whatyou are doing. Also note that setting <ib>CTIDcommandsetpcap:on</ib>fora container will most probably lead to inability to startit.</p>
<p style="margin-left:17%;">The same as <b>exec</b>, butreturn code is that of <i>command</i>.</p>=== Device access management ====
<p style="margin-left:11%;"><b>runscript--devnodes</b> <i>CTIDscriptdevice</i>:[<b>r</b>][<b>w</b>][<b>q</b>]|<b>none</b></p>
<p style="margin-left:1722%;">Run specified shell script inGive the container. Argument an access(<ib>scriptr</ib> is a file on the hostsystem which contents is - read by vzctl and executed in thecontext of the container. For a running container, thecommand jumps into the container and executes the script.For a stopped container<b>w</b> - write, it enters the container, mountscontainer&rsquo;s root filesystem, executes the script, and<b>q</b> - disk quotaunmounts CT root. In the latter casemanagement, the container is notreally started, no file systems other than root (such as<b>/procnone</b>- no access) are mounted, no startup scripts are executedto a device designatedetcby the special file /dev/<i>device</i>. Thus the environment in which the script is running Device file isfar from normal and is only usable for very basicoperationscreated in a container by <b>vzctl</b>.Example:</p>
<p pre style="margin-left:1122%;"><b>enter</b> [<b> vzctl set 777 --exec</b><i>command</i> [<i>arg</i> ...]]devnodes sdb:rwq</ppre>
<p style="margin-left:1711%;">Enters into a container (givinga container&rsquo;s root shell). This option is a back<b>--doordevicesfor host root only. The proper way to have CT root shell isto use b</b>|<b>c</b>:<i>major</i>:<i>minor</i>|<b>all</b>:[<b>r</b>][<b>w</b>][<b>q</b>]|<b>sshnone</b>(1).</p>
<p style="margin-left:1722%; margin-top: 1em">OptionGive the container an access toa <b>--execb</b> is used to run lock or <ib>commandc</ib> with argumentsharacter device designated by itsafter entering into container. This is useful if command tobe run requires a terminal (so <bi>vzctl execmajor</bi> can not beused) and for some reason you can not use <bi>sshminor</bi>(1)numbers. Device file have tobe created manually.</p>
<p style="margin-left:17%; margin-top: 1em">You need to logout manually from the shell to finish session (even if youspecified <b>--exec</b>).</p>=== PCI device management ====
<p style=== Other options ==="margin-left:11%;"><b>--pci_add</b>[<i>domain</i>:]<i>bus</i>:<i>slot</i>.<i>func</i></p>
<p style="margin-left:1122%;">Give the container an access toa specified PCI device. All numbers are hexadecimal (asprinted by <b>--helplspci</b>(8) in the first column).</p>
<p style="margin-left:1711%;">Prints help message with a<b>--pci_del</b>brief list of possible options[<i>domain</i>:]<i>bus</i>:<i>slot</i>.<i>func</i></p>
<p style="margin-left:1122%;"><b>--version</b>Delete a PCI device from thecontainer.</p>
<p style="margin-left:1722%;margin-top: 1em">Prints Note that<b>vps-pci</b> configuration script is executed by<b>vzctl</b>then configuring PCI devices. The script isversionusually located at <b>/usr/libexec/vzctl/scripts/</b>.</p>
== ACTION SCRIPTS == Features management ====
<p style="margin-left:11%; margin-top: 1em"><b>vzctl</b>has an ability to execute user-defined scripts when aspecific <b>vzctl-features</b> command is run for a container. Thefollowing <bi>vzctlname</bi> commands can trigger execution ofaction scripts: <b>starton</b>, |<b>stopoff</b>, [<b>restart</b>,<b>mount</b> and <b>umount</b>...]</p>
<p style="margin-left:1122%; margin-top: 1em">Action scriptsEnable or disable a specificcontainer feature. Known features are located in the : <b>sysfs</etcb>,<b>nfs</vzb>, <b>sit</confb>, <b>ipip</b>, <b>ppp</b> directory. There are,global and per-CT scripts. Global scripts have a literalprefix of <b>vps.ipgre</b>, <b>bridge</b> and are executed for all containers.Per-CT scripts have a , <ib>CTIDnfsd</ib> numeric prefix and are. A few features canexecuted for the given container onlybe specified at once, comma-separated.</p>
<p style="margin-left:11%; margin-top: 1em">Please notescripts are executed in a host system (CT0) context, withthe exception of <b>.start</b> and <b>.stop</b> scripts,which are executed in a container context.</p>=== Apply config ====
<p style="margin-left:11%; margin-top: 1em">The followingaction scripts are currently defined: <b><br>vps.premount--applyconfig</b>, <i>CTIDname</i><b>.premount</b></p>
<p style="margin-left:22%;">Global Read container parameters fromthe container sample configuration file<tt>/etc/vz/conf/ve-</tt><i>name</i><tt>.conf-sample</tt>,and perapply them, if <b>--CT mount scriptssave</b> option specified save towhich are executed for a the container before it is mountedconfig file.The following parameters are notScripts are executed in the host system contextchanged: <b>HOSTNAME</b>, <b>IP_ADDRESS</b>, while a CTis not yet mounted or running. Global script<b>OSTEMPLATE</b>, if exists<b>VE_ROOT</b>, isandexecuted first<b>VE_PRIVATE</b>.</p>
<p style="margin-left:11%;"><b>vps.mount--applyconfig_map</b>,<i>CTIDgroup</i></p> <p style="margin-left:22%;">Apply container configparameters selected by <i>group</i>. Now the only possiblevalue for <i>group</i> is <b>name</b>.mount: to restore containername based on <b>NAME</b>variable in containerconfiguration file.</p> ==== I/O scheduling ====
<p style="margin-left:2211%;">Global and per-CT mount scriptswhich are executed for a container right after it ismounted. Otherwise they are the same as <b>.premount--ioprio</b>scripts.<i>priority</i></p>
<p style="margin-left:1122%;">Assigns disk I/O priority tocontainer. <i>CTIDPriority</i>range is <b>0-7</b>. The greater<i>priority</i> is, the more time for I/O activity containerhas.startBy default each container has <i>priority</i> of<b>4</b>.</p>
<p style="margin-left:2211%;">Right after <b>vzctl--iolimit</b> hasstarted a container, it executes this script in a containercontext.<i>limit</i>[<b>B</b>|<b>K</b>|<b>M</b>|<b>G</b>]</p>
<p style="margin-left:1122%;">Assigns disk I/O bandwidthlimit for a container. Value is either a number with anoptional suffix, or a literal string <ib>CTIDunlimited</ib>. Valueof <b>.stop0</b>means &quot;unlimited&quot;. By default acontainer has no I/O limit. Maximum allowed limit is 2gigabytes per second; values exceeding the limit aretruncated.</p>
<p style="margin-left:22%;margin-top: 1em">Right before If no suffix isprovided, the <i>limit</i> is assumed to be in megabytes persecond. Available suffixes are: <br>&bull; <b>b</b>, <b>B</b> -- bytes per second; <br>&bull; <b>k</b>, <b>vzctlK</b> has-- kilobytes per second; <br>stopped a container&bull; <b>m</b>, it executes this script in a container<b>M</b> -- megabytes per second (default);<br>context.&bull; <b>g</b>, <b>G</b> -- gigabytes per second;</p>
<p style="margin-left:11%;"><b>vps.umount--iopslimit</b>,<i>CTIDiops</i><b>.umount</b></p>
<p style="margin-left:22%;">Global and per-CT umountscripts which are executed Assigns IOPS limit for a container before it , in number of input/output operations per second.Value isa number or a literal string <b>unlimited</b>.unmountedValue of <b>0</b> means &quot;unlimited&quot;. Scripts are executed in the host system context,while By default a CT is mounted. Global script, if exists, is executedfirstcontainer has no IOPS limit.</p>
<p style="margin-left:11%;"><b>vps.postumount</b>,<i>CTID</i><b>.postumount</b></p>== Suspending and resuming ===
<p style="margin-lefttop:22%;1em">Global and perCheckpointing is a feature ofOpenVZ kernel which allows to save a complete in-CT umountkernelscripts which are executed for state of a running container right after , and to restore it isunmounted. Otherwise they are the same as <b>.umount</b>scriptslater.</p>
<p style="margin-left:11%; margin-top: 1em">The environmentpassed to all the <b>*mountsuspend</b> scripts is the standardenvironment of the parent (i.e. |<b>vzctlchkpnt</b>) with twoadditional variables: <bi>$VEIDCTID</bi> and [<b>$VE_CONFFILE--dumpfile</b>.The first one holds the ID of the container, and the secondone holds the full path to the container configuration file.If the script needs to get other CT configurationparameters, such as <bi>$VE_ROOTname</bi>, it needs to get thosefrom global and per-CT configuration files.]</p>
<p style="margin-left:1117%; margin-top: 1em">Here is anexample of This command suspends a mount script, which makes host system&rsquo;s/mnt/disk available container to container(s). Script name can eitherbe a dump file If an option <b>/etc/vz/conf/vps.mount--dumpfile</b> orisnot set, default dump file name<b>/etc/vz/confdump/Dump.</b><i>CTID</i><b>.mount</b>is used.</p>
<pre p style="margin-left:11%; margin-top: 1em"> # If one of these files does not exist then something # is really broken [ -f <b>resume</etcb>|<b>restore</sysconfigb><i>CTID</vz ] || exit 1 i> [ <b>-f $VE_CONFFILE ] || exit 1 # Source both files. Note the order is important. . /etc/vz/vz.conf . $VE_CONFFILE mount -n --bind dumpfile</mntb> <i>name</disk $VE_ROOT/mnt/diski>]</prep>
<p style="margin-left:17%;">This command restores acontainer from the dump file created by the <b>suspend</b>command.</p> === Snapshotting = EXIT STATUS ==
<p style="margin-left:11%; margin-top: 1em">Returns 0 uponSnapshotting is a feature basedsuccesson checkpointing and ploop shapshots. It allows to save acomplete state of container file system. Plus, or an appropriate error code if thecontainer is running, it&rsquo;s in-memory state (as in case of anerror:checkpointing). Note that snapshot functionality is onlyworking for containers on ploop device.</p>
<table widthp style="100margin-left:11%;" border="0" rules="none" frame="void"><b>snapshot</b> <i>CTID</i> cellspacing="0" cellpadding="0"[<b>--id</b> <i>uuid</i>] [<b>--name</b> <i>name</i>][<b>--description</b> <i>desc</i>] <tr valign="top" align="left"br>[<b>--skip-suspend<td width="11%"/b>] [<b>--skip-config</tdb>]<td width="4%"/p>
<p>1</p></td><td widthstyle="7margin-left:17%;">Creates a container snapshot,i.e. saves the current container state, including its filesystem state, running processes state, and configurationfile.</td><td width="78%"p>
<p>Failed to set a UBC parameter</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">If a containeris running, and <td width="11%"b>--skip-suspend</tdb>option is notspecified, a container is checkpointed and then restored,and CT memory dump becomes the part of snapshot.<td width="4%"/p>
<p>2</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">Unless<b>--skip-config</tdb>option is given, containerconfiguration file is saved to the snapshot.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Failed to set a fair scheduler parameterIf <i>uuid</pi>is not specified, it is auto-generated. Options<b>--name</tdb>and <b>--description</trb>can be used to<tr valign="top" align="left">specify the snapshot name and description, respectively.Name is displayed by <td width="11%"b>snapshot-list</tdb>.<td width="4%"/p>
<pstyle="margin-left:11%;">3<b>snapshot-switch</pb><i>CTID</i> [<b>--skip-resume</b> | <b>--must-resume</tdb>][<td width="7%"b>--skip-config</tdb>] <b><br>--id<td width="78%"/b> <i>uuid</i></p>
<pstyle="margin-left:17%;">Generic system errorSwitches the container to asnapshot identified by </pi>uuid</tdi>, restoring its filesystem state, configuration (if available) and its runningstate (if available).</trp> <tr valignp style="margin-left:17%; margin-top" align="left: 1em"><td width="11%"b>Note thatthe current state of a container (including its file systemstate and its configuration file) is lost!</tdb><td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">5Option</pb>--skip-resume</tdb>is used to ignore a CT memory dump filein a snapshot, as a result the container will end up beingin a stopped state (same as if a snapshot has been takenwith <td width="7%"b>--skip-suspend</tdb>).<td width="78%"/p>
<p>The running kernel is not an OpenVZ kernel (or someOpenVZ modules are not loaded)</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">If option<td width="11%"b>--must-resume</tdb>is set, absense of a memory dump istreated as an error, and the inability to restore from thememory dump is treated as an error rather than warning.<td width="4%"/p>
<p>6</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">Option option<b>--skip-config</tdb>is used to ignore the CT configurationfile in a snapshot, i.e. the current configuration file willbe left as is.<td width="78%"/p>
<pstyle="margin-left:11%;"><b>Not enough system resourcessnapshot-delete</pb><i>CTID</tdi></trb>--id<tr valign="top" align="left"/b><td width="11%"i>uuid</tdi><td width="4%"/p>
<p>7</p></td><td widthstyle="7margin-left:17%;">Removes a specifiedsnapshot.</td><td width="78%"p>
<pstyle="margin-left:11%;"><b>ENV_CREATEsnapshot-mount</b> ioctl failed<i>CTID</pi> <b>--id</tdb> <i>uuid</tri><tr valign="top" align="left"b>--target</b><td width="11%"i>directory</tdi><td width="4%"/p>
<pstyle="margin-left:17%;">8Mounts a snapshot specified by</pi>uuid</tdi>to a <td width="7%"i>directory</tdi>. Note this mount isread-only.<td width="78%"/p>
<pstyle="margin-left:11%;">Command executed by <b>vzctl execsnapshot-umount</b> returned non<i>CTID</i> <b>-zeroexit code-id</pb> <i>uuid</tdi></trp> <tr valign="top" alignp style="margin-left:17%;">Unmounts a specifiedsnapshot.<td width/p> <p style="margin-left:11%;"><b>snapshot-list</tdb><td widthi>CTID</i> [<b>-H</b>] [<b>-o</b><i>field</i>[,<i>field</i>...] [<b>--id</b> <i>uuid</i>]</p> <p style="4margin-left:17%;">List container&rsquo;ssnapshots.</p>
<p>9</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">You cansuppress displaying header using <b>-H</tdb>option.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Container is locked by another You can use the<b>vzctl-o</b>option to display only the specifiedinvocation</p> </tdi>field</tri>(s). List of available fields can be obtainedusing <tr valign="top" align="left"b>-L<td width="11%"/b>option.</td><td width="4%"p>
<p>10</p></td><td width="7%"></td><td width="78%">= Performing container actions ===
<p>Global OpenVZ configuration file [[Man/vz.conf.5|<b>vz.conf</b>(5)]] nottable width="100%" border="0" rules="none" frame="void"found</p> </td></tr cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="49%">
<pstyle="margin-top: 1em"><b>create</b>11</p></td><td width="72%"></td>
<td width="78%">
<pstyle="margin-top: 1em"><i>CTID</i>[<b>--ostemplate&nbsp;</b><i>name</i>][<b>--config&nbsp;</b><i>name</i>][<b>--layout&nbsp;simfs</b>|<b>ploop</b>[<b>:</b>{<b>expanded</b>|<b>plain</b>|<b>raw</b>}]][<b>--diskspace&nbsp;</b><i>kbytes</i>][<b>--diskinodes&nbsp;</b><i>num</i>][<b>--private&nbsp;</b><i>path</i>][<b>--root&nbsp;</b><i>path</i>][<b>--ipadd&nbsp;</b><i>A vzctl helper script file not foundaddr</pi>][<b>--hostname&nbsp;</b><i>name</i>][<b>--name&nbsp;</tdb><i>name</tri>][<tr valign="top" align="left"b>--local_uid&nbsp;</b><i>uid</i>][<b>--local_gid&nbsp;</b><i>gid</i>]</p> </td width="11%"></tdtr><td width/table> <p style="4margin-left:17%; margin-top: 1em">Creates a newcontainer area. This operation should be done once, beforethe first start of the container.</p>
<pstyle="margin-left:17%; margin-top: 1em">By default, anOS template denoted by <b>12DEF_OSTEMPLATE</pb> parameter of[[Man/vz.conf.5|<b>vz.conf</tdb>(5)]] is used to create a container. This can beoverwritten by <td width="7%"b>--ostemplate</tdb>option.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Permission denied</p>By default, anew container configuration file is created from a sampleconfiguration denoted by value of </tdb>CONFIGFILE</tr><tr valign="top" align="left"b>parameter of [[Man/vz.conf.5|<td width="11%"b>vz.conf</tdb>(5)]]. If the containerconfiguration file already exists, it will not bemodified.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">13The value of<b>CONFIGFILE</pb> can be overwritten by using the<b>--config</tdb><td width="7%"i>name</tdi>option. This option can not beused if the container configuration file already exists.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">A new containercan either be created using <b>simfs</b> filesystem or on a<b>ploop</b> device. The default is set by value of<b>VE_LAYOUT</b> parameter of [[Man/vz.conf.5|<b>Capability setting failedvz.conf</pb>(5)]] and can beoverwritten by <b>--layout</tdb>option. In case <b>ploop</trb>is used, one can additionally specify ploop disk imageformat after a colon. Possible ploop formats are<tr valign="top" align="left"b>expanded</b>, <b>plain</b> and <b>raw</b>. Default is<td width="11%"b>expanded</b>. Using value other than <b>expanded</tdb>isnot recommended and is currently not supported.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">14You can use<b>--diskspace</pb> and <b>--diskinodes</tdb>options tospecify container file system size. Note that for<td width="7%"b>ploop</tdb>layout, you will not be able to change inodesvalue later.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">If<b>Container DISKSPACE</b> is not specified either in the sampleconfiguration file used for creation or in globalconfiguration file [[Man/ctidvz.conf.5|<b>ctidvz.conf</b>(5)]] notfound, </pb> --diskspace</td></trb>parameter is required for <tr valign="top" align="left"b>ploop<td width="11%"/b>layout.</td><td width="4%"p>
<pstyle="margin-left:17%; margin-top: 1em">15Suffixes<b>G</pb>, <b>M</b>, <b>K</tdb>can also be specified (see<td width="7%"b>Resource limits</tdb>section for more info onsuffixes).<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Timeout on You can use<b>vzctl exec--root</b><i>path</pi> option to sets the path to themount point for the container root directory (default is<b>VE_ROOT</tdb>specified in [[Man/vz.conf.5|</trb>vz.conf<tr valign="top" align="left"/b>(5)]] file).Argument can contain literal string <td width="11%"b>$VEID</tdb>, which willbe substituted with the numeric CT ID.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">You can use<b>--private</b> <i>path</i> option to set the path todirectory in which all the files and directories specific tothis very container are stored (default is <b>16VE_PRIVATE</pb>specified in [[Man/vz.conf.5|<b>vz.conf</tdb>(5)]] file). Argument can containliteral string <td width="7%"b>$VEID</tdb>, which will be substituted withthe numeric CT ID.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Error during You can use<b>vzctl chkpnt--ipadd</b></pi>addr</tdi>option to assign an IP address toa container. Note that this option can be used multipletimes.</trp> <tr valignp style="margin-left:17%; margin-top" align="left: 1em">You can use<td width="11%"b>--hostname</b> <i>name</tdi>option to set a host name fora container.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">When runningwith an upstream Linux Kernel that supports user namespaces(&gt;= 3.8), the parameters <b>--local_uid</b> and<b>--local_gid</b> can be used to select which <i>uid</i>and <i>gid</i>17respectively will be used as a base user inthe host system. Note that user namespaces provide a 1:1mapping between container users and host users. If theseoptions are not specified, the values <b>LOCAL_UID</pb> and<b>LOCAL_GID</tdb>from global configuration file[[Man/vz.conf.5|<b>vz.conf</b>(5)]] are used. An explicit <td width="7%"b>--local_uid</tdb>value of 0 will disable user namespace support, and run thecontainer as a privileged user. In this case,<b>--local_gid<td width="78%"/b> is ignored.</p>
<pstyle="margin-left:17%; margin-top: 1em">Error during <b>vzctl restoreWarning:</b>use <b>--local_uid</pb>and </tdb>--local_gid</trb>with care,specially when migrating containers. In all situations, the<tr valign="top" align="left">container&rsquo;s files in the filesystem needs to be<td width="11%">correctly owned by the host-side users.</td><td width="4%"p>
<pstyle="margin-left:11%;"><b>18destroy</pb> | <b>delete</tdb><td width="7%"i>CTID</tdi><td width="78%"/p>
<p>Error from <b>setluid()</b> syscall</p></td></tr><tr valign="top" alignstyle="margin-left:17%;">Removes a container private<td width="11%">area by deleting all files, directories and theconfiguration file of this container.</td><td width="4%"p>
<pstyle="margin-left:11%;">20<b>start</pb> <i>CTID</tdi>[<b>--wait</b>] [<b>--force</b>] [<td width="7%"b>--skip-fsck</tdb>][<b>--skip-remount<td width="78%"/b>]</p>
<pstyle="margin-left:17%;">Mounts (if necessary) andstarts a container. Unless <b>Invalid command line parameter--wait</pb>option isspecified, </tdb>vzctl</trb>will return immediately; otherwise<tr valign="top" align="left">an attempt to wait till the default runlevel is reached willbe made by <td width="11%"b>vzctl</tdb>.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">21Specify</pb>--force</tdb>if you want to start a container which isdisabled (see <td width="7%"b>--disabled</tdb>).<td width="78%"/p>
<p>Invalid value for command line parameter</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">Specify<td width="11%"b>--skip-fsck</tdb>to skip fsck for ploop-based containerfilesystem (this option is used by vz initscript).<td width="4%"/p>
<p>22</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">By default, ifa container to be started happens to be already mounted, itis unmounted and mounted again. This behavior can be turnedoff by using <b>--skip-remount</tdb>flag.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Container root directory (Note that thiscommand can lead to execution of <b>VE_ROOTpremount</b>) not set,<b>mount</pb>and </tdb>start</trb>action scripts (see <tr valign="top" align="left"b>ACTIONSCRIPTS<td width="11%"/b>below).</td><td width="4%"p>
<pstyle="margin-left:11%;">23<b>stop</pb> <i>CTID</tdi>[<b>--fast<td width="7%"/b>] [<b>--skip-umount</tdb>]<td width="78%"/p>
<pstyle="margin-left:17%;">Container private directory Stops a container and unmountsit (unless <b>VE_PRIVATE--skip-umount</b>is given) not. Normally,set<b>halt</pb>(8) is executed inside a container; option<b> --fast</tdb>makes </trb>vzctl<tr valign="top" align="left"/b>use <td width="11%"b>reboot</tdb>(2)syscall instead which is faster but can lead to uncleancontainer shutdown.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Note that<b>24vzctl stop</pb> is not asyncronous, in other words vzctlwaits for container&rsquo;s init to exit (unless<b>--fast</b> is given), which can take up to a few minutes.Default wait timeout is 120 seconds; it can be changedglobally, by setting <b>STOP_TIMEOUT</tdb>in[[Man/vz.conf.5|<b>vz.conf</b>(5)]], or per container (<td width="7%"b>STOP_TIMEOUT</tdb>in[[Man/ctid.conf.5|<b>ctid.conf<td width="78%"/b>(5)]], see <b>--stop-timeout</b>).</p>
<pstyle="margin-left:17%; margin-top: 1em">Container template directory (Note that thiscommand can lead to execution of <b>TEMPLATEstop</b>) notset, <b>umount</pb> and </tdb>postumount</trb>action scripts (see <tr valign="top" align="left"b>ACTIONSCRIPTS<td width="11%"/b>below).</td><td width="4%"p>
<pstyle="margin-left:11%;">28<b>restart</pb> <i>CTID</tdi>[<b>--wait</b>] [<b>--force</b>] [<td width="7%"b>--fast</tdb>][<b>--skip-fsck<td width="78%"/b>]</p>
<pstyle="margin-left:17%;">Not Restarts a container, i.e.stops it if it is running, and starts again. Accepts all required UBC parameters are set, unable to startthecontainer</pb> start</tdb>and </trb>stop<tr valign="top" align="left"><td width="11%"/b>options.</td><td width="4%"p>
<p>29</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">Note that thiscommand can lead to execution of some action scripts (see<b>ACTION SCRIPTS</tdb>below).<td width="78%"/p>
<pstyle="margin-left:11%;">OS template is not specified, unable to createcontainer</pb> status</tdb></tri>CTID<tr valign="top" align="left"><td width="11%"/i></td><td width="4%"p>
<p>31</p></td><td widthstyle="7margin-left:17%;">Shows a container status. Thisis a line with five or six words, separated by spaces.</td><td width="78%"p>
<p>Container not running</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">First word isliterally <td width="11%"b>CTID</tdb>.<td width="4%"/p>
<p>32</p></td><td widthstyle="7margin-left:17%; margin-top: 1em">Second word isthe numeric <i>CT ID</tdi>.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Container already runningThird word isshowing whether this container exists or not, it can beeither </pb>exist</tdb>or </trb>deleted<tr valign="top" align="left"><td width="11%"/b>.</td><td width="4%"p>
<pstyle="margin-left:17%; margin-top: 1em">33Fourth word isshowing the status of the container filesystem, it can beeither </pb>mounted</tdb>or <td width="7%"b>unmounted</tdb>.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Unable to stop Fifth wordshows if the containeris running, it can be either</pb>running</tdb>or </trb>down<tr valign="top" align="left"><td width="11%"/b>.</td><td width="4%"p>
<pstyle="margin-left:17%; margin-top: 1em">34Sixth word, ifexists, is </pb>suspended</tdb>. It appears if a dump fileexists for a stopped container (see <td width="7%"b>suspend</tdb>).<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Unable to add IP address to containerThis commandcan also be usable from scripts.</p></td></tr> <tr valign="top" alignp style="margin-left:11%;"><td width="11%"b>mount</b> <i>CTID</tdi><td width="4%"/p>
<pstyle="margin-left:17%;">40Mounts container private area.Note that this command can lead to execution of<b>premount</pb> and <b>mount</tdb>action scripts (see<td width="7%"b>ACTION SCRIPTS</tdb>below).<td width="78%"/p>
<pstyle="margin-left:11%;">Container not mounted</pb>umount</tdb></tri>CTID<tr valign="top" align="left"><td width="11%"/i></td><td width="4%"p>
<pstyle="margin-left:17%;">41Unmounts container privatearea. Note that this command can lead to execution of<b>umount</pb> and <b>postumount</tdb>action scripts (see<td width="7%"b>ACTION SCRIPTS</tdb>below).<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">Container already mountedNote that</pb>stop</tdb>does </trb>umount<tr valign="top" align="left"><td width="11%"/b>automatically.</td><td width="4%"p>
<pstyle="margin-left:11%;">43<b>convert</pb> <i>CTID</tdi>[<td width="7%"b>--layoutploop</b>[<b>:</b>{<b>expanded</b>|<b>plain</b>|<b>raw</tdb>}]]<td width="78%"/p>
<p>Container private area not found</p></td></tr><tr valign="top" alignstyle="margin-left:17%;">Convert CT private area toreside on a ploop device (available in kernel version042stab052.8 and greater). Conversion should be performedwhen a container is stopped, plus disk space quota should be<td width="11%">set.</td><td width="4%"p>
<pstyle="margin-left:11%;">44</pb>compact</tdb><td width="7%"i>CTID</tdi><td width="78%"/p>
<p>Container private area already exists</p></td></tr><tr valign="top" alignstyle="margin-left:17%;">Compact container image. This<td width="11%">only makes sense for ploop layout.</td><td width="4%"p>
<pstyle="margin-left:11%;">46</pb>quotaon</tdb><td width="7%"i>CTID</tdi><td width="78%"/p>
<pstyle="margin-left:17%;">Turn disk quota on. Not enough disk spacethat</pb>mount</tdb>and </trb>start<tr valign="top" align="left"><td width="11%"/b>does that automatically.</td><td width="4%"p>
<pstyle="margin-left:11%;">47</pb>quotaoff</tdb><td width="7%"i>CTID</tdi><td width="78%"/p>
<pstyle="margin-left:17%;">Bad/broken container (Turn disk quota off. Not that<b>/sbin/initumount</b> orand <b>/bin/shstop</b> not found)does that automatically.</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%">
<pstyle="margin-left:11%;">48</pb>quotainit</tdb><td width="7%"i>CTID</tdi><td width="78%"/p>
<pstyle="margin-left:17%;">Unable to create a new container private areaInitialize disk quota (i.e. run</pb>vzquota init</tdb><) with the parameters taken from the CTconfiguration file [[Man/tr>ctid.conf.5|<tr valign="top" align="left"b>ctid.conf<td width="11%"/b>(5)]].</td><td width="4%"p>
<pstyle="margin-left:11%;">49</pb>exec</tdb><td width="7%"i>CTIDcommand</tdi><td width="78%"/p>
<pstyle="margin-left:17%;">Unable to create a new container root areaExecutes </pi>command</tdi>in acontainer. Environment variables are not set inside thecontainer. Signal handlers may differ from default settings.If </tri>command<tr valign="top" align="left"/i>is <td width="11%"b>-</tdb>, commands are read fromstdin.<td width="4%"/p>
<pstyle="margin-left:11%;">50</pb>exec2</tdb><td width="7%"i>CTIDcommand</tdi><td width="78%"/p>
<pstyle="margin-left:17%;">Unable to mount containerThe same as <b>exec</pb>, butreturn code is that of <i>command</tdi>.</trp> <tr valign="top" alignp style="margin-left:11%;"><td width="11%"b>runscript</tdb> <i>CTIDscript<td width="4%"/i></p>
<pstyle="margin-left:17%;">51Run specified shell script inthe container. Argument </pi>script</tdi>is a file on the hostsystem which contents is read by vzctl and executed in thecontext of the container. For a running container, thecommand jumps into the container and executes the script.For a stopped container, it enters the container, mountscontainer&rsquo;s root filesystem, executes the script, andunmounts CT root. In the latter case, the container is notreally started, no file systems other than root (such as<td width="7%"b>/proc</tdb>) are mounted, no startup scripts are executedetc. Thus the environment in which the script is running isfar from normal and is only usable for very basicoperations.<td width="78%"/p>
<pstyle="margin-left:11%;">Unable to unmount container<b>enter</pb> <i>CTID</tdi>[<b>--exec</trb><tr valign="top" align="left"i>command</i>[<td width="11%"i>arg</tdi>...]]<td width="4%"/p>
<pstyle="margin-left:17%;">Enters into a container (givinga container&rsquo;s root shell). This option is a back-doorfor host root only. The proper way to have CT root shell isto use <b>52ssh</pb>(1).</tdp> <td widthp style="7margin-left:17%; margin-top: 1em">Option<b>--exec</tdb>is used to run <i>command</i> with argumentsafter entering into container. This is useful if command tobe run requires a terminal (so <b>vzctl exec</b> can not beused) and for some reason you can not use <td width="78%"b>ssh</b>(1).</p>
<p>Unable to delete a container</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">You need to logout manually from the shell to finish session (even if youspecified <td width="11%"b>--exec</tdb>).<td width="4%"/p>
<pstyle="margin-left:11%;"><b>53console</pb> <i>CTID</tdi>[<td width="7%"i>ttynum</tdi>]<td width="78%"/p>
<pstyle="margin-left:17%;">Container private area not existAttach to a container console.Optional <i>ttynum</pi> argument is tty number (such as<b>4</tdb> for <b>tty4</trb>), default is <b>1<tr valign="top" align="left"/b>which is usedfor container&rsquo;s <td width="11%"b>/dev/console</tdb>.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">60Note theconsoles are persistent, meaning that: </pbr>&bull; it can be attached to even if the container is notrunning; </tdbr>&bull; there is no automatic detachment upon the containerstop; <td width="7%"br>&bull; detaching from the console leaves anything running inthis console as is.</td><td width="78%"p>
<p><b>vzquota on</b> failed</p></td></tr><tr valignstyle="margin-left:17%; margin-top" align="left: 1em">The followingescape sequences are recognized by <td width="11%"b>vzctl console</tdb>.Note that these sequences are only recognized at thebeginning of a line.<td width="4%"/p>
<pstyle="margin-left:17%; margin-top: 1em">61&bull;</pb>Esc</tdb>then <td width="7%"b>.</tdb>to detach from the console.<td width="78%"/p>
<pstyle="margin-left:17%; margin-top: 1em">&bull;<b>vzquota initEsc</b> failedthen </pb>!</td></trb>to kill anything running on the<tr valign="top" align="left">console (SAK). This is helpful when one expects a login<td width="11%">prompt but there isn&rsquo;t one.</td><td width="4%"p>
<p>62</p></td><td width="7%"></td><td width="78%">= Other options ===
<pstyle="margin-left:11%;"><b>vzquota setlimit--help</b> failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%">
<p>63</p></td><td widthstyle="7margin-left:17%;">Prints help message with abrief list of possible options.</td><td width="78%"p>
<pstyle="margin-left:11%;">Parameter <b>DISKSPACE--version</b> not set</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%">
<p>64</p></td><td widthstyle="7margin-left:17%;">Prints <b>vzctl</tdb>version.<td width="78%"/p>
<p>Parameter <b>DISKINODES</b> not set</p></td></tr><tr valign="top" align="left"><td widthACTION SCRIPTS ="11%"></td><td width="4%">
<pstyle="margin-left:11%; margin-top: 1em"><b>vzctl</b>has an ability to execute user-defined scripts when aspecific <b>66vzctl</pb> command is run for a container. Thefollowing <b>vzctl</tdb>commands can trigger execution ofaction scripts: <b>start</b>, <td width="7%"b>stop</b>, <b>restart</tdb>,<td width="78%"b>mount</b> and <b>umount</b>.</p>
<pstyle="margin-left:11%; margin-top: 1em">Action scriptsare located in the <b>vzquota off/etc/vz/conf/</b> faileddirectory. There areglobal and per-CT scripts. Global scripts have a literalprefix of </pb>vps.</tdb>and are executed for all containers.Per-CT scripts have a </tri>CTID<tr valign="top" align="left"/i><td width="11%"b>.</tdb>numeric prefix andare executed for the given container only.<td width="4%"/p>
<pstyle="margin-left:11%; margin-top: 1em">67Please notescripts are executed in a host system (CT0) context, withthe exception of </pb>.start</tdb>and <td width="7%"b>.stop</tdb>scripts,which are executed in a container context.<td width="78%"/p>
<pstyle="margin-left:11%; margin-top: 1em">ugid quota not initializedThe followingaction scripts are currently defined: </pb><br>vps.premount</tdb>, </tri>CTID<tr valign="top" align="left"/i><td width="11%"b>.premount</tdb><td width="4%"/p>
<p>71</p></td><td widthstyle="7margin-left:22%;">Global and per-CT mount scriptswhich are executed for a container before it is mounted.Scripts are executed in the host system context, while a CTis not yet mounted or running. Global script, if exists, isexecuted first.</td><td width="78%"p>
<pstyle="margin-left:11%;">Incorrect IP address format</pb>vps.mount</tdb>,</tri>CTID<tr valign="top" align="left"/i><td width="11%"b>.mount</tdb><td width="4%"/p>
<p style="margin-left:22%;">Global and per-CT mount scriptswhich are executed for a container right after it ismounted. Otherwise they are the same as <b>.premount</b>scripts.</p> <p style="margin-left:11%;"><i>CTID</i><b>.start</b></p> <p style="margin-left:22%;">Right after <b>vzctl</b> hasstarted a container, it executes this script in a containercontext.</p> <p style="margin-left:11%;"><i>CTID</i><b>.stop</b></p> <p style="margin-left:22%;">Right before <b>vzctl</b> hasstopped a container, it executes this script in a containercontext.</p> <p style="margin-left:11%;"><b>vps.umount</b>,<i>CTID</i><b>.umount</b></p> <p style="margin-left:22%;">Global and per-CT umountscripts which are executed for a container before it isunmounted. Scripts are executed in the host system context,while a CT is mounted. Global script, if exists, is executedfirst.</p> <p style="margin-left:11%;"><b>vps.postumount</b>,<i>CTID</i><b>.postumount</b></p> <p style="margin-left:22%;">Global and per-CT umountscripts which are executed for a container right after it isunmounted. Otherwise they are the same as <b>.umount</b>scripts.</p> <p style="margin-left:11%; margin-top: 1em">The environmentpassed to all the <b>*mount</b> scripts is the standardenvironment of the parent (i.e. <b>vzctl</b>) with twoadditional variables: <b>$VEID</b> and <b>$VE_CONFFILE</b>.The first one holds the ID of the container, and the secondone holds the full path to the container configuration file.If the script needs to get other CT configurationparameters, such as <b>$VE_ROOT</b>, it needs to get thosefrom global and per-CT configuration files.</p> <p style="margin-left:11%; margin-top: 1em">Here is anexample of a mount script, which makes host system&rsquo;s/mnt/disk available to container(s). Script name can eitherbe <b>/etc/vz/conf/vps.mount</b> or<b>/etc/vz/conf/</b><i>CTID</i><b>.mount</b>.</p> <pre style="margin-left:11%; margin-top: 1em"> # If one of these files does not exist then something # is really broken [ -f /etc/vz/vz.conf ] || exit 1 [ -f $VE_CONFFILE ] || exit 1 # Source both files. Note the order is important. . /etc/vz/vz.conf . $VE_CONFFILE SRC=/mnt/disk DST=/mnt/disk mount -n -t simfs $SRC ${VE_ROOT}${DST} -o $SRC</pre> == EXIT STATUS == <p style="margin-left:11%; margin-top: 1em">Returns 0 uponsuccess, or an appropriate error code in case of anerror:</p> <table width="100%" border="0" rules="none" frame="void" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>1</p></td><td width="7%"></td><td width="78%"> <p>Failed to set a UBC parameter</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>2</p></td><td width="7%"></td><td width="78%"> <p>Failed to set a fair scheduler parameter</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>3</p></td><td width="7%"></td><td width="78%"> <p>Generic system error</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>5</p></td><td width="7%"></td><td width="78%"> <p>The running kernel is not an OpenVZ kernel (or someOpenVZ modules are not loaded)</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>6</p></td><td width="7%"></td><td width="78%"> <p>Not enough system resources</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>7</p></td><td width="7%"></td><td width="78%"> <p><b>ENV_CREATE</b> ioctl failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>8</p></td><td width="7%"></td><td width="78%"> <p>Command executed by <b>vzctl exec</b> returned non-zeroexit code</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>9</p></td><td width="7%"></td><td width="78%"> <p>Container is locked by another <b>vzctl</b>invocation</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>10</p></td><td width="7%"></td><td width="78%"> <p>Global OpenVZ configuration file [[Man/vz.conf.5|<b>vz.conf</b>(5)]] notfound</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>11</p></td><td width="7%"></td><td width="78%"> <p>A vzctl helper script file not found</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>12</p></td><td width="7%"></td><td width="78%"> <p>Permission denied</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>13</p></td><td width="7%"></td><td width="78%"> <p>Capability setting failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>14</p></td><td width="7%"></td><td width="78%"> <p>Container configuration file [[Man/ctid.conf.5|<b>ctid.conf</b>(5)]] notfound</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>15</p></td><td width="7%"></td><td width="78%"> <p>Timeout on <b>vzctl exec</b></p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>16</p></td><td width="7%"></td><td width="78%"> <p>Error during <b>vzctl suspend</b></p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>17</p></td><td width="7%"></td><td width="78%"> <p>Error during <b>vzctl resume</b></p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>18</p></td><td width="7%"></td><td width="78%"> <p>Error from <b>setluid()</b> syscall</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>20</p></td><td width="7%"></td><td width="78%"> <p>Invalid command line parameter</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>21</p></td><td width="7%"></td><td width="78%"> <p>Invalid value for command line parameter</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>22</p></td><td width="7%"></td><td width="78%"> <p>Container root directory (<b>VE_ROOT</b>) not set</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>23</p></td><td width="7%"></td><td width="78%"> <p>Container private directory (<b>VE_PRIVATE</b>) notset</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>24</p></td><td width="7%"></td><td width="78%"> <p>Container template directory (<b>TEMPLATE</b>) notset</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>28</p></td><td width="7%"></td><td width="78%"> <p>Not all required UBC parameters are set, unable to startcontainer</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>29</p></td><td width="7%"></td><td width="78%"> <p>OS template is not specified, unable to createcontainer</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>31</p></td><td width="7%"></td><td width="78%"> <p>Container not running</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>32</p></td><td width="7%"></td><td width="78%"> <p>Container already running</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>33</p></td><td width="7%"></td><td width="78%"> <p>Unable to stop container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>34</p></td><td width="7%"></td><td width="78%"> <p>Unable to add IP address to container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>40</p></td><td width="7%"></td><td width="78%"> <p>Container not mounted</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>41</p></td><td width="7%"></td><td width="78%"> <p>Container already mounted</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>43</p></td><td width="7%"></td><td width="78%"> <p>Container private area not found</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>44</p></td><td width="7%"></td><td width="78%"> <p>Container private area already exists</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>46</p></td><td width="7%"></td><td width="78%"> <p>Not enough disk space</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>47</p></td><td width="7%"></td><td width="78%"> <p>Bad/broken container (<b>/sbin/init</b> or<b>/bin/sh</b> not found)</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>48</p></td><td width="7%"></td><td width="78%"> <p>Unable to create a new container private area</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>49</p></td><td width="7%"></td><td width="78%"> <p>Unable to create a new container root area</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>50</p></td><td width="7%"></td><td width="78%"> <p>Unable to mount container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>51</p></td><td width="7%"></td><td width="78%"> <p>Unable to unmount container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>52</p></td><td width="7%"></td><td width="78%"> <p>Unable to delete a container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>53</p></td><td width="7%"></td><td width="78%"> <p>Container private area not exist</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>60</p></td><td width="7%"></td><td width="78%"> <p><b>vzquota on</b> failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>61</p></td><td width="7%"></td><td width="78%"> <p><b>vzquota init</b> failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>62</p></td><td width="7%"></td><td width="78%"> <p><b>vzquota setlimit</b> failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>63</p></td><td width="7%"></td><td width="78%"> <p>Parameter <b>DISKSPACE</b> not set</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>64</p></td><td width="7%"></td><td width="78%"> <p>Parameter <b>DISKINODES</b> not set</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>65</p></td><td width="7%"></td><td width="78%"> <p>Error setting in-container disk quotas</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>66</p></td><td width="7%"></td><td width="78%"> <p><b>vzquota off</b> failed</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>67</p></td><td width="7%"></td><td width="78%"> <p>ugid quota not initialized</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>71</p></td><td width="7%"></td><td width="78%"> <p>Incorrect IP address format</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>74</p></td><td width="7%"></td><td width="78%"> <p>Error changing password</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>78</p></td><td width="7%"></td><td width="78%"> <p>IP address already in use</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>79</p></td><td width="7%"></td><td width="78%"> <p>Container action script returned an error</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>82</p></td><td width="7%"></td><td width="78%"> <p>Config file copying error</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>86</p></td><td width="7%"></td><td width="78%"> <p>Error setting devices (<b>--devices</b> or<b>--devnodes</b>)</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>89</p></td><td width="7%"></td><td width="78%"> <p>IP address not available</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>91</p></td><td width="7%"></td><td width="78%"> <p>OS template not found</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>99</p></td><td width="7%"></td><td width="78%"> <p>Ploop is not supported by either the running kernel orvzctl.</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>100</p></td><td width="7%"></td><td width="78%"> <p>Unable to find container IP address</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>104</p></td><td width="7%"></td><td width="78%"> <p><b>VE_NETDEV</b> ioctl error</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>105</p></td><td width="7%"></td><td width="78%"> <p>Container start disabled</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>106</p></td><td width="7%"></td><td width="78%"> <p>Unable to set iptables on a running container</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>107</p></td><td width="7%"></td><td width="78%"> <p>Distribution-specific configuration file not found</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>109</p></td><td width="7%"></td><td width="78%"> <p>Unable to apply a config</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>129</p></td><td width="7%"></td><td width="78%"> <p>Unable to set meminfo parameter</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>130</p></td><td width="7%"></td><td width="78%"> <p>Error setting veth interface</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>131</p></td><td width="7%"></td><td width="78%"> <p>Error setting container name</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>133</p></td>
<td width="7%"></td>
<td width="78%">
<p>IP address already in useWaiting for container start failed</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>79139</p></td>
<td width="7%"></td>
<td width="78%">
<p>Container action script returned an errorError saving container configuration file</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>82148</p></td>
<td width="7%"></td>
<td width="78%">
<p>Config file copying error</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>86</p></td><td width="7%"></td><td width="78%"> <p>Error setting devices container IO parameters (<b>--devices</b> or<b>--devnodes</b>ioprio)</p> </td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>89</p></td><td width="7%"></td><td width="78%"> <p>IP address not available</p></td></tr><tr valign="top" align="left"><td width="11%"></td><td width="4%"> <p>91</p></td><td width="7%"></td><td width="78%"> <p>OS template not found</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>100150</p></td>
<td width="7%"></td>
<td width="78%">
<p>Unable to find container IP addressPloop image file not found</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>104151</p></td>
<td width="7%"></td>
<td width="78%">
<p><b>VE_NETDEV</b> ioctl errorError creating ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>105152</p></td>
<td width="7%"></td>
<td width="78%">
<p>Container start disabledError mounting ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>106153</p></td>
<td width="7%"></td>
<td width="78%">
<p>Unable to set iptables on a running containerError unmounting ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>107154</p></td>
<td width="7%"></td>
<td width="78%">
<p>Distribution-specific configuration file not foundError resizing ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>109155</p></td>
<td width="7%"></td>
<td width="78%">
<p>Unable Error converting container to apply a configploop layout</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>129156</p></td>
<td width="7%"></td>
<td width="78%">
<p>Unable to set meminfo parameterError creating ploop snapshot</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>130157</p></td>
<td width="7%"></td>
<td width="78%">
<p>Error setting veth interfacemerging ploop snapshot</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>131158</p></td>
<td width="7%"></td>
<td width="78%">
<p>Error setting container namedeleting ploop snapshot</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>133159</p></td>
<td width="7%"></td>
<td width="78%">
<p>Waiting for container start failedError switching ploop snapshot</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>139166</p></td>
<td width="7%"></td>
<td width="78%">
<p>Error saving container configuration filecompacting ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>148167</p></td>
<td width="7%"></td>
<td width="78%">
<p>Error setting container IO parameters (ioprio)listing ploop snapsots</p></td></tr>
</table>
<p style="margin-left:11%; margin-top: 1em">Copyright (C)
2000-20112013, Parallels, Inc. Licensed under GNU GPL.</p>
2,253
edits

Navigation menu