Changes

Jump to: navigation, search

Man/vzctl.8

2,982 bytes added, 01:51, 3 May 2013
Automated import of articles *** existing text overwritten ***
<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>snapshot</b> <i>CTID</i>
[<b>--id&nbsp;</b><i>uuid</i>]
[<b>--name&nbsp;</b><i>name</i>]
[<b>--description&nbsp;</b><i>desc</i>]
[<b>--skip-suspend</b>] [<b>--skip-config</b>]</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<p>[<i>flags</i>] <b>snapshot-switch</b> |
<b>snapshot-delete </b> <i>CTID</i> <b>--id</b> <i>uuid</i></p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="80%">
<p>[<i>flags</i>] <b>snapshot-mount</b> <i>CTID</i><b>--id</b> <i>uuid</i> <b>--target</b> <i>dir</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>flags</i>] <b>snapshot-umount</b> <i>CTID</i><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>flags</i>] <b>snapshot-list</b><i>CTID</i>[<b>-H</b>] [<b>-o</b> <i>field</i>[,<i>field</i>...][<b>--id</b> <i>uuid</i>]</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<p>[<i>flags</i>] <b>set</b> <i>CTID --parameter value</i>
[...] [<b>--save</b>] [<b>--force</b>] [<b>--reset_ub</b>]
[<b>--setmode&nbsp;restart</b>|<b>ignore</b>]</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>flags</i>] <b>set</b> <i>CTID</i>
<b>--reset_ub</b></p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<p style="margin-left:17%;">If this flag is given together
with <b>--save</b>, parameters are saved even if the current
kernel doesn&rsquo;t support OpenVZ. Note this flag does notmake sense without <b>--save</b>, so <b>--save</b> isrequired.</p>
<p style="margin-left:11%;"><b>--reset_ub</b></p>
the configuration file to a running container. This is
helpful in case configuration file is modified manually.
Please note this flag is exclusive, i.e. it can not compatible with <b>--save</b>,beand it is usually a bad idea to combine it combined with any otheroptionsor flags.</p>
<p style="margin-left:11%;"><b>--setmode restart</b> |
<p style="margin-left:17%;">A few parameters can only be
applied by restarting the container. By default,
<b>vzctl</b> warns prints a warning if such parameters are present supplied and acontainer is running. Use <b>--setmode restart</b> together with <b>--save</b> flag torestart a container in such a case, or <b>--setmodeignore</b> to suppress the above mentioned warning.</p>
==== Miscellaneous ====
<p style="margin-left:17%;">Sets whether the container will
be started during system boot. The container will not bestartedauto-started unless on boot by <b>vz</b> initscript if either this parameter is set to <b>yes</b>, or the container was running just beforelast reboot, and this parameter is not set to <b>no</b>.Default value is unset, meaning the container will bestarted if it was running before the last reboot.</p>
<p style="margin-left:11%;"><b>--bootorder</b>
exists. Note that this option is not saved in configuration
file at all (so <b>--save</b> flag is useless), it is
applied directly to the container (, by modifying its /etc/passwd andrunning/etc/shadow files)distribution-specific programs inside the container. It isnot recommended to combine this option with any otheroptions.</p>
<p style="margin-left:17%; margin-top: 1em">In case
container root filesystem is was not mountedrunning, it isautomatically mounted, started then all the appropriate file changesare applied, then it is unmountedstopped.</p>
<p style="margin-left:17%; margin-top: 1em">Note that
<p style="margin-left:17%;">Add a name for a container. The
<i>name</i> can later be used in subsequent calls to
<b>vzctl</b> in place of <i>CTID</i>. Note this option cannot be used without <b>--save</b>.</p>
<p style="margin-left:11%;"><b>--description</b>
<p style="margin-left:22%;">For <b>simfs</b> layout, sets
soft and hard disk quota limits, in blocks. First parameteris soft limit, second is hard limit. One block is currentlyequal to 1Kb.</p>
<p style="margin-left:22%; margin-top: 1em">For
<b>ploop</b> layout, sets initiates the size procedure of resizing the ploop image fileto the new size. Since there is nosoft/hard limit concept in ploop, second <i>num</i>, ifspecified,is ignored. Note that such resize is NOTin kilobytesperformed on container start, so for consistency<b>--diskspace</b> must be used together with <b>--save</b>flag.</p>
<p style="margin-left:22%; margin-top: 1em">Suffixes
<b>G</b>, <b>M</b>, <b>K</b> can also be specified (see
<b>Resource limits</b> section for more info onsuffixes).If suffix is not specified, value is in kilobytes.</p>
<p style="margin-left:11%;"><b>--diskinodes</b>
<b>vps-pci</b> configuration script is executed by
<b>vzctl</b> then configuring PCI devices. The script is
usually located at <b>/usr/lib[64]libexec/vzctl/scripts/</b>.</p>
==== Features management ====
<b>4</b>.</p>
=== Checkpointing Suspending and restore resuming ===
<p style="margin-top: 1em">Checkpointing is a feature of
OpenVZ kernel which allows to save a complete in-kernelstate of arunning container, and to restore it later.</p>
<p style="margin-left:11%;"><b>suspend</b>|<b>chkpnt</b> <i>CTID</i>[<b>--dumpfile</b> <i>name</i>]</p>
<p style="margin-left:17%;">This command saves suspends 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.</p>
<p style="margin-left:11%;"><b>resume</b>|<b>restore</b> <i>CTID</i>[<b>--dumpfile</b> <i>name</i>]</p>
<p style="margin-left:17%;">This command restores a
container from the dump file created by the <b>chkpntsuspend</b>
command.</p>
[<b>--id</b> <i>uuid</i>] [<b>--name</b> <i>name</i>]
[<b>--description</b> <i>desc</i>] <br>
[<b>--skip-suspend</b>] [<b>--skip-config</b>]</p>
<p style="margin-left:17%;">Creates a container snapshot,i.e. saves the current container state, including its fileIf <i>uuid</i> is not specifiedsystem state, running processes state, it is auto-generatedand configurationfile.</p>
<p style="margin-left:17%; margin-top: 1em">If a container
is running, and <b>--skip-suspend</b> option is not
specified, a container is checkpointed and then restored,
and CT memory dump becomes the part of snapshot. Otherwise</p> <p style="margin-left:17%; margin-top: 1em">Unless<b>--skip-config</b> option is given,containeronly configuration file system state is savedto the snapshot.</p>
<p style="margin-left:17%; margin-top: 1em">If <i>uuid</i>is not specified, it is auto-generated. Options
<b>--name</b> and <b>--description</b> can be used to
specify the snapshot name and description, respectively.
container state and its file system state is lost! If given
snapshot contains CT memory dump, it is restored, otherwise
it container is stopped.</p>
<p style="margin-left:11%;"><b>snapshot-delete</b>
<p style="margin-left:17%;">Removes a specified
snapshot.</p>
 
<p style="margin-left:11%;"><b>snapshot-mount</b>
<i>CTID</i> <b>--id</b> <i>uuid</i> <b>--target</b>
<i>directory</i></p>
 
<p style="margin-left:17%;">Mounts a snapshot specified by
<i>uuid</i> to a <i>directory</i>. Note this mount is
read-only.</p>
 
<p style="margin-left:11%;"><b>snapshot-umount</b>
<i>CTID</i> <b>--id</b> <i>uuid</i></p>
 
<p style="margin-left:17%;">Unmounts a specified
snapshot.</p>
<p style="margin-left:11%;"><b>snapshot-list</b>
<i>CTID</i>[<b>-H</b>] [<b>-o</b><i>field</i>[,<i>field</i>...] [<b>--id</b> <i>uuid</i>]</p> <p style="margin-left:17%;">List container&rsquo;ssnapshots.</p> <p style="margin-left:17%; margin-top: 1em">You cansuppress displaying header using <b>-H</b> option.</p>
<p style="margin-left:17%;margin-top: 1em">Lists all snapshotsYou can use the<b>-o</b> option to display only the specified<i>field</i>(s). ActiveList of available fields can be obtainedsnapshot is marked with using <b>*-L</b> signoption.</p>
=== Performing container actions ===
format after a colon. Possible ploop formats are
<b>expanded</b>, <b>plain</b> and <b>raw</b>. Default is
<b>expanded</b>. Using value other than <b>rawexpanded</b> is not recommended and iscurrently not supported.</p>
<p style="margin-left:17%; margin-top: 1em">You can use
<b>--diskspace</b> option to specify container file system
size. If DISKSPACE is not specified either in the sampleconfiguration file used or in global configuration file[[Man/vz.conf.5|<b>vz.conf</b>(5)]], this parameter is required for<b>ploop</b> layout.</p> <p style="margin-left:17%; margin-top: 1em">Suffixes <b>G</b>, <b>M</b>, <b>K</b> can also bespecified (see <b>Resource limits</b> section for more infoonon suffixes).</p>
<p style="margin-left:17%; margin-top: 1em">You can use
<p style="margin-left:17%; margin-top: 1em">Sixth word, if
exists, is <b>suspended</b>. It appears if a dump file
exists for a stopped container (see <b>chkpntsuspend</b>).</p>
<p style="margin-left:17%; margin-top: 1em">This command
<p style="margin-left:17%; margin-top: 1em">The following
escape sequences are recognized by <b>vzctl console</b>.
Note that these sequences are only recognized afterat the<b>Enter</b>beginning of a line.</p>
<p style="margin-left:17%; margin-top: 1em">&bull;
<td width="78%">
<p>Error during <b>vzctl chkpntsuspend</b></p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="78%">
<p>Error during <b>vzctl restoreresume</b></p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
<p>161166</p></td>
<td width="7%"></td>
<td width="78%">
<p>Error compacting ploop image</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="4%">
 
<p>167</p></td>
<td width="7%"></td>
<td width="78%">
 
<p>Error 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