The source command sets an IP address for the source VTEP.
The undo source command deletes the IP address configured for the source VTEP.
| Parameter | Description | Value |
|---|---|---|
ip-address |
Specifies the IP address of the source VTEP. |
The IP address is in dotted decimal notation. |
By default, VTEPs do not have IP addresses.
Application Scenarios
VTEPs are ends of VXLAN tunnels. They are encapsulated in NVEs to encapsulate and decapsulate VXLAN packets.
When configuring a VXLAN tunnel, you must run the source command to configure an IP address for the source VTEP. The IP address of the source VTEP is the source IP address of a VXLAN packet. The IP address of the peer VTEP is the destination IP address of a VXLAN packet. A pair of VTEP addresses identifies a VXLAN tunnel.
Precautions
The IP address of the source VTEP can be the address of a physical interface or the loopback interface. Using the loopback interface address is recommended. Do not use the IP address of a virtual system. Otherwise, the tunnel cannot be established.
# Configure the IP address of the source VTEP in the NVE interface view.
<sysname> system-view [sysname] interface Nve 1 [sysname-Nve1] source 192.168.1.2
# Delete the IP address of the source VTEP in the NVE interface view.
<sysname> system-view [sysname] interface Nve 1 [sysname-Nve1] undo source 192.168.1.2
# Delete the IP address of the source VTEP without specifying the IP address in the NVE interface view.
<sysname> system-view [sysname] interface Nve 1 [sysname-Nve1] undo source