Vyatta NOS documentation

Learn how to install, configure, and operate Vyatta Network Operating System (Vyatta NOS), which helps to drive our virtual networking and physical platforms portfolio.

Configure SPOKE1

The second step is to configure SPOKE1.

In this example, you create the tunnel interface and the tunnel endpoint on SPOKE1.

  • The tunnel interface tun0 on HUB is assigned the IP address 200.0.0.1 on subnet 200.0.0.0/24.
  • The source IP address of the tunnel endpoint (the local-ip ) is the same as the address associated with the local Ethernet interface in this example (192.0.2.1/24).
  • A static route is created to specify how to get to the remote LANs through the tunnel.
Table 1. Creating a multipoint GRE endpoint on SPOKE1

Step

Command

Create the tunnel interface, and specify the IP address to be associated with it.


vyatta@SPOKE1# set interfaces tunnel tun0 address 200.0.0.1/24

Specify the encapsulation mode for the tunnel.


vyatta@SPOKE1# set interfaces tunnel tun0 encapsulation gre-multipoint

Specify the source IP address for the tunnel. This address is the IP address of the physical interface for the tunnel endpoint.


vyatta@SPOKE1# set interfaces tunnel tun0 local-ip 192.0.2.1

Allow multicast protocols (for example, routing protocols) to be carried over the tunnel.


vyatta@SPOKE1# set interfaces tunnel tun0 multicast enable

Specify an authentication key for the NHRP network.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp authentication pre-shared-secret NET123

Map the IP address of the tunnel interface of the Hub to its physical IP address.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp map 200.0.0.99/24 nbma-address 192.0.2.99

Specify that this spoke should register itself automatically on startup.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp map 200.0.0.99/24 register

Specify that multicast packets are to be repeated to each statically configured next hop.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp multicast parameters nhs

Specify that Cisco-style NHRP Traffic Indication packets are to be sent.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp redirect

Specify that shortcut routes can be created.


vyatta@SPOKE1# set interfaces tunnel tun0 nhrp shortcut

Specify an authentication key for the tunnel.


vyatta@SPOKE1# set interfaces tunnel tun0 parameters ip key 1

Commit the configuration.


vyatta@SPOKE1# commit

View the configuration.


vyatta@SPOKE1# show interfaces tunnel
 tun0 {
     address 200.0.0.1/24
     encapsulation gre-multipoint
     local-ip 192.0.2.1
     multicast enable
     nhrp {
         authentication NET123
         map 200.0.0.99/24 {
             nbma-address 192.0.2.99
             register
         }
         multicast {
             parameters nhs
         }
         redirect
         shortcut
     }
     parameters {
         ip {
             key 1
         }
     }
 }

Create a static route to access the remote LAN behind HUB through the tunnel.


vyatta@WEST# set protocols static route 192.168.99.0/24 next-hop 200.0.0.99

Create a static route to access the remote LAN behind SPOKE2 through the tunnel.


vyatta@WEST# set protocols static route 192.168.2.0/24 next-hop 200.0.0.2

Commit the configuration.


vyatta@WEST# commit

View the configuration.


vyatta@WEST# show protocols
	static {
		route 192.168.99.0/24 {
			next-hop 200.0.0.99 {
			}
		}
		route 192.168.2.0/24 {
			next-hop 200.0.0.2 {
			}
		}
	}