1. Overview

Cumulus linux is linux distribution based on debian that focusing in networking. Cumulus linux provide standard networking function such as bridging, routing, VLANs, MLAGs, IPv4/IPv6, OSPF/BGP, access control, VRF, and VxLAN overlays.
Figure 1.1 - Cumulus VX in Unetlab



Cumulus linux, using native kernel model and networking packages from debian. Networking favourite tools can implemented with apt-get. It makes cumulus linux fit in to many networking framework for configuration management, authentication, monitoring, logging, and automation.

Figure 1.2 - Cumulus Architecture

1.1 Cumulus VX

Cumulus VX is kind product of Cumulus Network running on Virtual Appliances. It has a lot of similarity with Cumulus Linux and Cumulus RMP. But doesn’t have an actual ASIC or NPU for line rate performance. So for the reason, switchd is not running in Cumulus VX, no upgrade allowed. But we can still use networking tool from cumulus or debian-specific repository. Cumulus VX capability that described in table below:
Figure 1.3 - Cumulus VX Capability table

2. Playing Cumulus VX with Unified Networking Lab (UNETLAB)

2.1 Adding Cumulus VX in Unetlab Testing Ecosystem

For this test-case, we use cumulus VX 3.0.0, the latest cumulus VX version

  1. Download Cumulus VX from web, make sure KVM version is downloadable.
    Figure 2.1 - Cumulux VX Download Page
  2. Go to download Folder, then rename the file to hda.qcow2
    Figure 2.2 - Download File
    Figure 2.3 - Result after renaming file
  3. 3. Access unetlab server using ssh, then create file named cumulus-3.0.0 under directory /opt/unetlab/addons/qemu
    root@achyarnurandidotnet:~# mkdir /opt/unetlab/addons/qemu/cumulus-3.0.0
    root@achyarnurandidotnet:~#
    
  4. Using ftp client to send file to server, in this case I use win-scp. Access unetlab server then send file to under directory /opt/unetlab/addons/qemu/cumulus-3.0.0
    Figure 2.4 - Upload file to server using winscp
    Figure 2.5 - After verification after upload
  5. Fix wrapping the change configuration
    # /opt/unetlab/wrappers/unl_wrapper -a fixpermissions
  6. Check php function template for cumulus network, like below and save it in /opt/unetlab/html/template, make sure is working with your cumulus
    root@achyarnurandidotnet:~# cat /opt/unetlab/html/templates/cumulus.php
    <?php
    # vim: syntax=php tabstop=4 softtabstop=0 noexpandtab laststatus=1 ruler
    
    /**
     * html/templates/cumulus.php
     *
     * Cumulus template for UNetLab.
     *
     * LICENSE:
     *
     * This file is part of UNetLab (Unified Networking Lab).
     *
     * UNetLab is free software: you can redistribute it and/or modify
     * it under the terms of the GNU General Public License as published by
     * the Free Software Foundation, either version 3 of the License, or
     * (at your option) any later version.
     *
     * UNetLab is distributed in the hope that it will be useful,
     * but WITHOUT ANY WARRANTY; without even the implied warranty of
     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
     * GNU General Public License for more details.
     *
     * You should have received a copy of the GNU General Public License
     * along with UNetLab. If not, see <http://www.gnu.org/licenses/>.
     *
     * @author Andrea Dainese <andrea.dainese@gmail.com>
     * @copyright 2014-2016 Andrea Dainese
     * @license http://www.gnu.org/licenses/gpl.html
     * @link http://www.unetlab.com/
     * @version 20151116
     */
    
    $p['type'] = 'qemu';
    $p['name'] = 'cumulus';
    $p['icon'] = 'Router.png';
    $p['cpu'] = 1;
    $p['ram'] = 256;
    $p['ethernet'] = 3;
    $p['console'] = 'vnc';
    $p['qemu_arch'] = 'x86_64';
    $p['qemu_nic'] = 'virtio-net-pci';
    $p['qemu_options'] = '-machine type=pc-1.0,accel=kvm -nographic -rtc base=utc';
    ?>
    root@achyarnurandidotnet:~#
  7. Then done, you can access the unetlab using WEB UI, and build the lab
    Figure 2.6 - Unetlab dashboard when adding cumulus VX
For first boot up cumulus VX, you may need to access using ssh gateway from your console terminal.

2.2 Simple Switch Testing Functionality

2.2.1 Topology

Below the topology that using in Lab
Figure 2.7 - Simple Switch Topology Using Cumulus VX
There are 2 server in one rack, and want to communicate with different server in another rack. Each server has privilege communication and it isolates using VLAN.

2.2.2 Configuration  

Configuration at CMLS-SW-1
auto swp1
iface swp1

auto swp2
iface swp2
        bridge-access 100

auto swp3
iface swp3
        bridge-access 200

auto swp4
iface swp4

auto br-cmls-sw1
iface br-cmls-sw1
        bridge-vlan-aware yes
        bridge-ports swp1 swp2 swp3
        bridge-vids 100 200
Configuration at CMLS-SW-2
auto swp1
iface swp1

auto swp2
iface swp2
        bridge-access 100

auto swp3
iface swp3
        bridge-access 200

auto swp4
iface swp4

auto br-cmls-sw2
iface br-cmls-sw2
        bridge-vlan-aware yes
        bridge-ports swp1 swp2 swp3
        bridge-vids 100 200

2.2.3 Validation

MAC Forwarding Database in each switch:
CMLS-SW-1
root@CMLS-SW-1:~# brctl show br-cmls-sw1
bridge name     bridge id               STP enabled     interfaces
br-cmls-sw1             8000.500000010001       yes             swp1
                                                        swp2
                                                        swp3
root@CMLS-SW-1:~# brctl showmacs br-cmls-sw1
port name mac addr              vlan    is local?       ageing timer
swp1      50:00:00:01:00:01     0       yes                0.00
swp2      50:00:00:01:00:02     0       yes                0.00
swp3      50:00:00:01:00:03     0       yes                0.00
swp1      50:00:00:02:00:01     1       no                 8.92
swp2      50:00:00:03:00:00     100     no                29.15
swp3      50:00:00:04:00:00     200     no                 0.30
swp1      50:00:00:05:00:00     200     no                 0.31
swp1      50:00:00:06:00:00     100     no                29.15
root@CMLS-SW-1:~#
CMLS-SW-2
root@CMLS-SW-2:~# brctl show br-cmls-sw2
bridge name     bridge id               STP enabled     interfaces
br-cmls-sw2             8000.500000020001       yes             swp1
                                                        swp2
                                                        swp3
root@CMLS-SW-2:~# brctl showmacs br-cmls-sw2
port name mac addr              vlan    is local?       ageing timer
swp1      50:00:00:01:00:01     1       no                 1.86
swp1      50:00:00:02:00:01     0       yes                0.00
swp2      50:00:00:02:00:02     0       yes                0.00
swp3      50:00:00:02:00:03     0       yes                0.00
swp1      50:00:00:03:00:00     100     no                20.34
swp1      50:00:00:04:00:00     200     no                 0.53
swp3      50:00:00:05:00:00     200     no                 0.53
swp2      50:00:00:06:00:00     100     no                20.35
root@CMLS-SW-2:~

Ping-test
Server-3 - Server-6
Figure 2.8 - Ping-test from Server-3 (10.0.100.3) to Server-6 (10.0.100.6)

Figure 2.9 - Ping-test from Server-6 (10.0.100.6) to Server-6 (10.0.100.3)
Server-5 - Server-4
Figure 2.10 - Ping-test from Server-5 (10.0.200.5) to Server-4 (10.0.200.4)
Figure 2.11 - Ping-test from Server-4 (10.0.200.4) to Server-5 (10.0.200.5)

2.2.4 Use-case

Ensure VLAN isolation has been working, Try to change ip address server 3 from 10.0.100.3/24 to 10.0.200.3/24. Then try to ping server-4 in vlan 200.
root@CMLS-SW-1:~# brctl showmacs br-cmls-sw1
port name mac addr              vlan    is local?       ageing timer
swp1      50:00:00:01:00:01     0       yes                0.00
swp2      50:00:00:01:00:02     0       yes                0.00
swp3      50:00:00:01:00:03     0       yes                0.00
swp1      50:00:00:02:00:01     1       no                11.28
swp2      50:00:00:03:00:00     100     no                 0.19
root@CMLS-SW-1:~#

Figure 2.12 - Ping result when Change IP address from server3 to can join another server in another vlan
Here, the documentation video from simple switch topology from cumulus vx


3. Reference

  1. Cumulus Linux. Overview Cumulus Linux. 3 May. https://cumulusnetworks.com/cumulus-linux/overview/ 
  2. Cumulus Linux. 2016. Comparing Cumulus VX with Other Cumulus Networks Products-v1-20160602_1442
  3. Unified Networking Lab. Supported images on Unified Networking Lab. 3 May  http://www.unetlab.com/documentation/supported-images/index.html
  4. Unified Networking Lab.  Adding Cisco IOS XRv. 3 May http://www.unetlab.com/2014/11/adding-cisco-xrv-images/