Testing new config with Cumulus VX - Port Numbers


Userlevel 1
Hi,

I'm trying to look into automated testing with Cumulus VX so that if we plan to carry out a config change, we can get gitlab to run through a automated process to spin up some Cumulus VX vm's and confirm that the change won't break anything.

By default Cumulus VX will obviously not be able to mirror the same number of ports of a real hardware switch. This presents a small problem in that although I could carry out a small subset of tests on client connecting ports 1-8 for example, the 40G uplink ports 49-50 won't be 49-50 on Cumulus VX. The config would need to be modified in someway before being applied to the VX vm's, which slightly defeats the point of being able to test the exact config.

Anybody have any smart ideas how to handle this? Can you use something like udev to remap the last 2 ports of the VM to show up with the same numbers as the 40G ports on a hardware switch?

4 replies

Userlevel 1
I've been doing some more reading and it appears that with kvm, if you use the multifunction parameter, you can add up to 8 nics per VM PCI slot and so should be able to emulate a full HW switch. I'm not sure if you can configure this via vagrant so it might have to be done with custom scripting.
Userlevel 2
Nick Fisk wrote:

I've been doing some more reading and it appears that with kvm, if you use the multifunction para...

Nick, I believe that the vagrant limit is 36 nics. You are correct in that you can use udev to remap ports so that you can use the high numbered ports. Check out what our spectacular consulting team put together for a reference topology here. If you look at the vagrantfile you'll see some examples of the udev mapping.
Userlevel 5
Nick Fisk wrote:

I've been doing some more reading and it appears that with kvm, if you use the multifunction para...

If you're looking to roll your own custom topology check out the topology converter tool --> https://github.com/CumulusNetworks/topology_converter this will automatically build and install the appropriate udev rules in the simulated devices. Let me know if we can be of any more help. The demo that Kevin points out above is built using topology converter.
Userlevel 1
Nick Fisk wrote:

I've been doing some more reading and it appears that with kvm, if you use the multifunction para...

Thanks, that looks interesting. I missed these replies, but have since got a bunch of 50 port switches using the above mentioned multifunction pci devices in KVM/libvirt. I do like the idea of simply being able to describe the topology though and let vagrant do the rest, so will probably give it a go.

Reply