Vagrant for SDN Labs pt2

Part 2 – Install

In part 2 of this blog post, we cover off how to install the necessary components to build virtual SDN labs with Vagrant.

You need a good base machine (preferably 8GB or more RAM). We’ll assume that you’re running Windows, but it should be easy to adapt to other operating systems. Some spare disk space is needed for the software installs and for VM images.

Here are the steps to set things up (skip steps if not needed):

Install VirtualBox

VirtualBox is used as the hypervisor (Provider in Vagrant-speak). It pretends to be a bare-metal chassis for guests that are spun up and manages resources such as CPU, memory and network.

Download and install VirtualBox from

Install Vagrant

Vagrant is the VM provisioning system. Download and install Vagrant from

Download a Box

Vagrant has the concept of boxes, which are pre-packaged VM images.
The labs in the repo use the bento box of Ubuntu 16.04. Download this box on your host machine with:

vagrant box add bento/ubuntu-16.04

Choose VirtualBox option from menu (2)

Install GitHub Desktop

This is a GUI client for git, skip if you prefer the command line git. See

Clone Repo

I’ve created a GitHub repo of example SDN labs at The repo includes a basic Mininet single-guest environment through to a multiple guest and switch environment.

Clone the Vagrant repo from into somewhere on your local file system that makes sense for you.


Run the Lab

To run a lab, navigate in a command prompt to the appropriate subdirectory off the git repo and type

vagrant up

Connect to the guest (assuming there’s only one) by using an SSH client to connect to localhost:2222

Username vagrant, password vagrant.

Connect to any further guests with SSH to localhost:2200 and increment port number for every subsequent guest.

Have fun.

2 thoughts on “Vagrant for SDN Labs pt2

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s