Adding a VTEP binding

Use this command to bridge the port-VLAN pair on a VTEP to a specified Neutron network.

Syntax

vtep <vtep-alias> add binding physical-port <port-name> vlan <vlan-id> network-id <neutron-network-id>

where neutron-network-id is the UUID of the network to which the port-VLAN assignment is to be made.

Result

If the command is successful, the result is a description of the Neutron network, VTEP physical port and VLAN ID tuple:

physical-port swp1 vlan 0 network-id 4659a6ab-fcd2-4744-bfbb-6a331164881e

When creating the first binding to a network, MidoNet will create a new port on the corresponding virtual bridge called a 'VXLAN port'. This port represents the Neutron network’s wiring to the VTEP. The same VXLAN port is used for subsequent port-VLAN pairs bound to the same Neutron network.

The command will fail in these conditions:

  • the hardware VTEP does not have a physical port with the specified name (code 401)
  • the hardware VTEP is not configured (code 503).
  • the Neutron network does not exist (code 400).

Example

Successful command:

midonet> vtep vtep0 add binding physical-port swp1 vlan 0 network-id 4659a6ab-fcd2-4744-bfbb-6a331164881e
physical-port swp1 vlan 0 network-id 4659a6ab-fcd2-4744-bfbb-6a331164881e

Unsuccessful command:

midonet> vtep vtep0 add binding physical-port swp10 vlan 0 network-id 4659a6ab-fcd2-4744-bfbb-6a331164881e
Internal error: {"message":"The VTEP at 192.168.2.10:6632 does not have a port named swp10.","code":401}
midonet> vtep vtep0 add binding physical-port swp10 vlan 0 network-id 4659a6ab-fcd2-4744-bfbb-6a331164881e
Internal error: {"message":"Cannot add binding to VTEP 192.168.2.10:6632 because the physical switch is not configured.","code":503}
midonet> vtep vtep0 add binding physical-port swp10 vlan 0 network-id f00f00f0-0f00-f00f-00f0-0f00f00f00f0
Internal error: {"message":"There is no Network with ID f00f00f0-0f00-f00f-00f0-0f00f00f00f0.","code":400}
Questions? Discuss on Mailing Lists or Chat.
Found an error? Report a bug.


loading table of contents...