VIC Container Fails with "Parsing network alias" when Using --link option
search cancel

VIC Container Fails with "Parsing network alias" when Using --link option


Article ID: 340130


Updated On:


VMware vSphere ESXi



Attempting to link a container to already existing container fails with message "Error response from daemon: Server error from portlayer: Parsing network alias".

Example of reproduction below.

# docker -H VCH_IP:2376 --tls run -itd --name WebProxy -p 1111:80 nginx
# docker  -H VCH_IP:2376 --tls run -itd --name jumpshell --link WebProxy busybox
docker: Error response from daemon: Server error from portlayer: Parsing network alias WebProxy failed.


VMware vSphere Integrated Containers 1.x


The method of using "--link destination_container" is a deprecated docker behavior.


In VIC "--link container_name" linking is already configured by default for containers on the same bridge network to connect to each other. Use "docker network ls" and "docker network inspect <network_name>" to see the networks and which containers are attached to the network. Try removing the "--link" option entirely from the create/run command for the container. This will connect to the container services.

Note: docker container hosts have the same behavior for additional docker networks created on the bridge. The out of the box configuration does not auto map on the default bridge network. For this reason, docker will not allow connection by default as --net is not specified to a user created docker network.

Example usage for the  "--link"option usage:

The mapping of an alias to a container is similar looking in that this command also starts with "--link" and supported by VIC. The difference between container linking and alias mapping is where the error is found. This is useful for situations when the container name is different than what the application requires. If the container is "WebProxy", but the application is hardcoded to connect to the name "NickName" then "--link WebProxy:NickName" can be used to make a connection to specific only to the container configured with the link. All other containers would not map NickName. This allows multiple container applications requiring to connect to the name "NickName" to map to a different service per container with a single VCH and bridge network configuration.