The following sections describe how to configure network
interfaces and FRRouting for a two-leaf/two-spine Cumulus VX network
topology:
To configure CumulusVX-leaf1:
Follow these steps for each of the four VMs.
- Two spine VMs that represent two spine (aggregation layer) switches on the network.
- Two leaf VMs that represent two leaf (access layer) switches on the network.
These
instructions assume that you have installed the relevant images and
hypervisors, created four VMs with appropriate names, and that the VMs
are running. Refer to the Getting Started chapter of this guide for more information on setting up the VMs.
Contents
Configure CumulusVX-leaf1
You can configure each of the VMs using the Network Command Line Utility (NCLU) or by editing the/etc/network/interfaces and /etc/frr/frr.conf files as the sudo user.
The
following configuration uses unnumbered IP addressing, where you use
the same /32 IPv4 address on multiple ports. OSPF unnumbered doesn't
have an equivalent to RFC-5549, so you need to use an IPv4 address to
bring up the adjacent OSPF neighbors, allowing you to reuse the same IP
address. You can see some example unnumbered OSPF configurations in the knowledge base.
- Log into the CumulusVX-leaf1 VM using the default credentials:
- username: cumulus
- password: CumulusLinux!
- As the sudo user, edit the
/etc/frr/daemonsfile in a text editor. Setzebra,bgpd, andospfdto yes, and save the file.
zebra=yesbgpd=yesospfd=yes... - Run the following commands to configure the switch:
These commands configure bothcumulus@switch:~$ net add loopback lo ip address 10.2.1.1/32cumulus@switch:~$ net add interface swp1 ip address 10.2.1.1/32cumulus@switch:~$ net add interface swp2 ip address 10.2.1.1/32cumulus@switch:~$ net add interface swp3 ip address 10.4.1.1/24cumulus@switch:~$ net add interface swp1 ospf network point-to-pointcumulus@switch:~$ net add interface swp2 ospf network point-to-pointcumulus@switch:~$ net add ospf router-id 10.2.1.1cumulus@switch:~$ net add ospf network 10.2.1.1/32 area 0.0.0.0cumulus@switch:~$ net add ospf network 10.4.1.0/24 area 0.0.0.0cumulus@switch:~$ net pendingcumulus@switch:~$ net commit/etc/network/interfacesand/etc/frr/frr.conf. The output of each file is shown below.
To edit the configuration files directly as the sudo user, copy the configurations below./etc/network/interfaces# The loopback network interfaceauto loiface lo inet loopbackaddress 10.2.1.1/32# The primary network interfaceauto eth0iface eth0 inet dhcpauto swp1iface swp1address 10.2.1.1/32auto swp2iface swp2address 10.2.1.1/32auto swp3iface swp3address 10.4.1.1/24/etc/frr/frr.confservice integrated-vtysh-configinterface swp1ip ospf network point-to-pointinterface swp2ip ospf network point-to-pointrouter-id 10.2.1.1router ospfospf router-id 10.2.1.1network 10.2.1.1/32 area 0.0.0.0network 10.4.1.0/24 area 0.0.0.0 - Restart the networking service:
cumulus@switch:~$ sudo systemctl restart networking - Restart FRRouting:
cumulus@switch:~$ sudo systemctl restart frr.service
Configure the Remaining VMs
The configuration steps for CumulusVX-leaf2, CumulusVX-spine1, and CumulusVX-spine2 are the same as CumulusVX-leaf1; however, the file configurations are different. Listed below are the configurations for each additional VM:- CumulusVX-leaf2:
/etc/network/interfaces# The loopback network interfaceauto loiface lo inet loopbackaddress 10.2.1.2/32# The primary network interfaceauto eth0iface eth0 inet dhcpauto swp1iface swp1address 10.2.1.2/32auto swp2iface swp2address 10.2.1.2/32auto swp3iface swp3address 10.4.2.1/24/etc/frr/frr.confservice integrated-vtysh-configinterface swp1ip ospf network point-to-pointinterface swp2ip ospf network point-to-pointrouter-id 10.2.1.2router ospfospf router-id 10.2.1.2network 10.2.1.2/32 area 0.0.0.0network 10.4.2.0/24 area 0.0.0.0 - CumulusVX-spine1:
/etc/network/interfaces# The loopback network interfaceauto loiface lo inet loopbackaddress 10.2.1.3/32# The primary network interfaceauto eth0iface eth0 inet dhcpauto swp1iface swp1address 10.2.1.3/32auto swp2iface swp2address 10.2.1.3/32auto swp3iface swp3/etc/frr/frr.confservice integrated-vtysh-configinterface swp1ip ospf network point-to-pointinterface swp2ip ospf network point-to-pointrouter-id 10.2.1.3router ospfospf router-id 10.2.1.3network 10.2.1.3/32 area 0.0.0.0 - CumulusVX-spine2:
/etc/network/interfaces# The loopback network interfaceauto loiface lo inet loopbackaddress 10.2.1.4/32# The primary network interfaceauto eth0iface eth0 inet dhcpauto swp1iface swp1address 10.2.1.4/32auto swp2iface swp2address 10.2.1.4/32auto swp3iface swp3/etc/frr/frr.confservice integrated-vtysh-configinterface swp1ip ospf network point-to-pointinterface swp2ip ospf network point-to-pointrouter-id 10.2.1.4router ospfospf router-id 10.2.1.4network 10.2.1.4/32 area 0.0.0.0
Restart the networking and FRRouting services on all VMs before continuing.
Create Point-to-Point Connections Between VMs
To use the two-leaf/two-spine Cumulus VX network topology you configured above, you need to configure the network adapter settings for each VM to create point-to-point connections. The following example shows how to create point-to-point connections between each VM in VirtualBox. If you are not using VirtualBox, refer to your hypervisor documentation to configure network adapter settings.Follow these steps for each of the four VMs.
Make sure that the VM is powered off.
- In the VirtualBox Manager window, select the VM.
- Click Settings, then click Network.
- Click Adapter 2.
- Click the Enable Network Adapter check box.
- From the Attached to list, select Internal Network.
- In the Name field, type a name for the internal network, then click OK.
The internal network name must match the internal network name on the corresponding network adapter on the VM to be connected to this VM. For example, in the two-leaf/two-spine Cumulus VX network topology, Adapter 2 (swp1) on CumulusVX-leaf1 is connected to Adapter 2 (swp1) on CumulusVX-spine1; the name must be the same for Adapter 2 on both VMs. Use the internal network names and the connections shown in the illustration and table below. - Click Adapter 3 and repeat steps 4 thru 6. Use the internal network names and the connections shown in the illustration and table below.
| CumulusVX-leaf1 | Adapter 1 | NAT | ||
| swp1 | Adapter 2 | Internal | Intnet-1 | |
| swp2 | Adapter 3 | Internal | Intnet-3 | |
| swp3 | Adapter 4 | Internal | Intnet-5 | |
| CumulusVX-leaf2 | Adapter 1 | NAT | ||
| swp1 | Adapter 2 | Internal | Intnet-2 | |
| swp2 | Adapter 3 | Internal | Intnet-4 | |
| swp3 | Adapter 4 | Internal | Intnet-6 | |
| CumulusVX-spine1 | Adapter 1 | NAT | ||
| swp1 | Adapter 2 | Internal | Intnet-1 | |
| swp2 | Adapter 3 | Internal | Intnet-2 | |
| swp3 | Adapter 4 (disabled) | |||
| CumulusVX-spine2 | Adapter 1 | NAT | ||
| swp1 | Adapter 2 | Internal | Intnet-3 | |
| swp2 | Adapter 3 | Internal | Intnet-4 | |
| swp3 | Adapter 4 (disabled) |
Test the Network Topology Connections
After you restart the VMs, ping across VMs to test the connections:- Run the following commands from CumulusVX-leaf1:
- Ping CumulusVX-leaf2:
cumulus@CumulusVX-leaf1:~$ ping 10.2.1.2 - Ping CumulusVX-spine1:
cumulus@CumulusVX-leaf1:~$ ping 10.2.1.3 - Ping CumulusVX-spine2:
cumulus@CumulusVX-leaf1:~$ ping 10.2.1.4
- Ping CumulusVX-leaf2:


