blob: cba74fc83cd81f3b74e4a4f7ee8e0970252bf6ce [file] [log] [blame] [raw]
.TH vz.conf 5 "5 Dec 2012" "OpenVZ" "Containers"
.SH NAME
vz.conf \- global OpenVZ configuration file
.SH SYNOPSIS
.B /etc/vz/vz.conf
.SH DESCRIPTION
This is the global configuration file for OpenVZ.
It consists of lines in the form
.PP
\fBPARAMETER\fR="\fIvalue\fR"
.PP
All parameter names and values are case-sensitive.
Quotes surrounding \fIvalue\fR are required if value contains spaces, and
are optional otherwise. Extra spaces are not allowed. All unrecognized lines
will be ignored.
.SS Global parameters
.IP \fBVIRTUOZZO\fR=\fByes\fR|\fBno\fR
This parameter can be set to \fByes\fR or \fBno\fR, and used by
the \fBvz\fR init script. In case it is not
set to \fByes\fR, nothing will be done to boot up OpenVZ on this node.
.IP "\fBLOCKDIR\fR=\fIdirectory\fR"
Set the directory to put lock files to.
.IP \fBVE0CPUUNITS\fR=\fInumber\fR
Value of this parameter sets \fBcpuunits\fR for CT0 (host system).
.IP "\fBLOGGING\fR=\fByes\fR|\fBno\fR"
Enables or disables logging. This parameter can be set to \fByes\fR or
\fBno\fR, default is \fByes\fR.
.IP \fBLOGFILE\fR=\fIfile\fR
Set location of log file, default is \f(CR/var/log/vzctl.log\fR.
.IP "\fBLOG_LEVEL\fR=\fInumber\fR"
Set the logging level for the log file (does not affect console output).
The greater the \fInumber\fR is, the more information will be logged
to the \fBLOGFILE\fR. Default is \fB0\fR, which means to log normal messages
and errors. If set to \fB-1\fR, only errors will be logged.
.IP "\fBVERBOSE\fR=\fInumber\fR"
Set the logging level for console/terminal output (does not affect log file).
Default is \fB0\fR, which means to log normal messages and errors.
Increasing the \fBnumber\fR makes \fBvzctl\fR(8) more verbose.
.IP "\fBMODULES_DISABLED\fR=\fByes\fR|\fBno\fR"
If the value of this parameter is set to \fByes\fR, no attempt to load
kernel modules is made by the \fBvz\fR initscript. This is helpful
on systems which have OpenVZ-specific features compiled into the kernel
(i. e. not as modules).
.IP \fBIPTABLES_MODULES\fR="\fImodule\ module\ ...\fR"
List of iptables kernel modules to be loaded by \fBvz\fR initscript
before loading OpenVZ modules (which is required for iptables
to work inside containers). If not set, value of \fBIPTABLES\fR is used.
.IP \fBVZFASTBOOT\fR=\fByes\fR|\fBno\fR
If the value of this parameter is set to \fByes\fR, \fBvz\fR initscript called
with \fBstart\fR argument will start the containers with uncleanly
shutdown quota state without performing quota reinitialization
(which is usually a time-consuming process). After all the containers are
started, the initscript when restarts those containers with unclean quota
in a normal way (to recalculate/fix quotas).
.IP \fBVE_STOP_MODE\fR=\fBsuspend\fR|\fBstop\fR
If the value of this parameter is set to \fBsuspend\fR or not set at all,
\fBvz\fR initscript called with \fBstop\fR argument will try to suspend
the running containers, instead of stopping them. Suspended containers when
will be restored on \fBvz start\fR. This feature usually helps to decrease
the reboot time. If a container fails to suspend, it will be stopped anyway.
.IP \fBTEMPLATE\fR=\fIdirectory\fR
Value of this parameter is a directory in which all container template data are
stored.
.SS Network interface parameters
.IP \fBVE_ROUTE_SRC_DEV\fR="\fIdevice\fR"
This parameter specifies the network device name which IP address will be
used as the source IP. This is helpful in case more than one network
interface is configured on HN and there is a need to specify the source
IP address. Default is the first device in the network device list.
.IP \fBNEIGHBOUR_DEVS\fR="\fBdetect\fR"
Controls on which interfaces to add/remove ARP records for a container IP, also
which interfaces to use to query/announce ARP. If this is set to \fBdetect\fR,
the right network interface (the one which is in the same subnet as a CT IP)
will be chosen automatically. Any other value restores old (as of vzctl 3.0.19
or older) behavior, when all the possible interfaces were used.
.IP \fBERROR_ON_ARPFAIL\fR=\fByes\fR|\fBno\fR
In case the value of this parameter is set to \fByes\fR, vzctl will fail to
start a container if there is another host with the same IP in the subnet.
The value of \fBno\fR makes vzctl to only print the warning.
.SS Defaults for vzctl create
These parameters are defaults for \fBvzctl create\fR and can be overwritten
by its appropriate command line options.
.IP \fBDEF_OSTEMPLATE\fR=\fIname\fR
Default OS template to create a container from. Corresponds to
\fB--ostemplate\fR option of \fBvzctl create\fR.
.IP \fBCONFIGFILE\fR=\fIname\fR
Default configuration file
(\f(CW\fB/etc/vz/conf/ve-\fIname\fR\f(CW\fB.conf-sample\fR)
used to create a new container. Corresponds to \fB--config\fR
option of \fBvzctl create\fR.
.IP \fBVE_LAYOUT\fR=\fBsimfs\fR|\fBploop\fR[\fB:\fR{\fBplain\fR|\fBexpanded\fR|\fBraw\fR}]
Default CT filesystem layout for a new container, can either be
\fBploop\fR or \fBsimfs\fR. In case \fBploop\fR is used, one can
additionally specify ploop disk image format after a colon.
Possible ploop formats are \fBexpanded\fR, \fBplain\fR and \fBraw\fR.
Default is \fBexpanded\fR. Using \fBraw\fR is not recommended and is
not supported.
Corresponds to \fB--layout\fR option of \fBvzctl create\fR.
.SS Defaults for containers
Below parameters are defaults for containers, and can be overwritten by
parameters in \fBctid.conf\fR(5) per-container configuration file.
.IP \fBDISK_QUOTA\fR=\fByes\fR|\fBno\fR
In case the value of this parameter is set to \fBno\fR, all disk
quota operations are disabled.
.IP \fBVE_ROOT\fR=\fIdirectory\fR
Value of this parameter is the \fIdirectory\fR which serves as container root
mount point. Value must contain literal string \fB$VEID\fR, which will be
substituted with the actual numeric CT ID.
.IP \fBVE_PRIVATE\fR=\fIdirectory\fR
Value of this parameter is the \fIdirectory\fR in which all the
files and directories specific to that container are stored. Value must contain
literal string \fB$VEID\fR, which will be substituted with the actual
numeric CT ID.
.IP \fBIPTABLES\fR="\fImodule\ module\ ...\fR"
List of iptables modules to be enabled for containers, corresponds
to \fB--iptables\fR option.
.IP \fBSTOP_TIMEOUT\fR="\fInumber\fR"
Time to wait for a container to shut down on \fBvzctl stop\fR,
before forcibly killing it, in seconds. Hardcoded to 120 if not set.
.IP \fBNAMESERVER\fR="\fIip\fR\ [\fIip\fR\ ...]"
Default value for containers nameserver(s). Several name server addresses
are divided by spaces. If set to \fBinherit\fR, values from host system's
\fB/etc/resolv.conf\fR are used.
.IP \fBSEARCHDOMAIN\fR="\fIdomain\fR\ [\fIdomain\fR\ ...]"
Default value for containers search domains. Several search domains
are divided by spaces. If set to \fBinherit\fR, values from host system's
\fB/etc/resolv.conf\fR are used.
.PP
Most of the other parameters that appear in per-container configuration files
\fBctid.conf\fR(5) can be also set here. Still, it is recommended to keep
\fBTEMPLATE\fR, \fBVE_PRIVATE\fR and \fBVE_ROOT\fR in this configuration
file, and all the other container related parameters in per-container
configuration files.
.SH SEE ALSO
.BR vzctl (8),
.BR ctid.conf (5).
.SH LICENSE
Copyright (C) 2000-2011, Parallels, Inc. Licensed under GNU GPL.