User`s guide

Managing Parallels Server Bare Metal Network 148
Creating and Deleting veth Network Adapters
By default, any Container on the Parallels server starts functioning in the venet0 mode right
after its creation. However, at any time you can create additional virtual adapters for your
Container and set them to work in the veth mode. This can be done by using the --
netif_add option of the pctl set command.
Let us assume that you wish to create a new virtual adapter with the name of eth1 inside
Container 101 and make it function in the veth mode. To do this, you can execute the
following command :
# pctl set 101 --netif_add eth1 --save
Saved parameters for Container 101
The settings of the newly created virtual adapter are saved as the value of the NETIF parameter
in the configuration file of Container 101 (/etc/vz/conf/101.conf). So, you can use the
following command to display the parameters assigned to the veth network adapter inside
Container 101:
# grep NETIF /etc/vz/conf/101.conf
NETIF="ifname=eth1,mac=00:10:41:F0:AA:B6,host_mac=00:18:51:A0:8A:D7"
As you can see, the parameters set for the veth virtual network adapter during its creation are
the following:
ifname: the name set for the veth Ethernet interface inside Container 101. You specified
this name when creating the Container virtual network adapter. Usually, names of Ethernet
interfaces inside Containers are set in the form of ethAd_N where Ad_N denotes the index
number of the created adapter (e.g. eth0 or eth1); however, you can choose any other
name you like and specify it during the virtual adapter creation.
mac: the MAC address assigned to the veth Ethernet interface inside Container 101.
host_mac: the MAC address assigned to the veth Ethernet interface on the Parallels
server.
ifname is the only mandatory parameter that should be indicated when creating a Container
virtual network adapter. All the other parameters are optional and generated by Parallels Server
Bare Metal automatically, if not specified.
At any time, you can remove the veth virtual network adapter inside Container 101 by
executing the following command:
# pctl set 101 --netif_del eth1 --save
Saved parameters for Container 101
# grep NETIF /etc/vz/conf/101.conf
NETIF=""