We will be using a number of tools, namely Mininet, Open vSwitch, the OpenFlow Ryu controller, and Wireshark with the OpenFlow dissector. We can install each of these tools separately; however, it will take a while before we get everything installed and configured correctly. Luckily, SDN Hub (http://sdnhub.org) provides an all-in-one SDN app development starter VM (http://sdnhub.org/tutorials/sdn-tutorial-vm/) that includes all of the tools mentioned here and more. The base operating system is Ubuntu 14.04, which is similar to the VM that we have been using up to this point, and it also contains all the popular SDN controllers in one setting, such as OpenDaylight, ONOS, Ryu, Floodlight, POX, and Trema.
For this chapter and the next, we will be using this all-in-one image to have a self-contained OpenFlow network as a starting point to experiment and learn about OpenFlow and SDN. It is a pretty big image to be downloaded, at about 3 GB, but for the amount of work it saves, I feel it is worth the effort. Start the download, grab a cup of coffee, and off we go!
After the OVA image download, you can run the image on a number of hypervisors, including VirtualBox and VMWare. I would recommend using the same hypervisor as your VIRL setup, since in the following chapters, we will try to use the OpenFlow environment to interact with the VIRL VM. You can also use a different hypervisor, such as Hyper-V or VirtualBox, as long as you bridge the interfaces to the same virtual network as the VIRL VM for future chapters.
In my personal setup, I imported the image to VMware Fusion:
The recommended resource allocation is 2 vCPU and 2 GB of memory:
For consistency, I have also added additional network interfaces to the VMNet, similar to the setup for the virtual machine we have been using:
We will add the IP address to /etc/network/interfaces/ in order to preserve settings after reboot:
ubuntu@sdnhubvm:~[06:56]$ cat /etc/network/interfaces
...
auto eth1
iface eth1 inet static
address 172.16.1.174
netmask 255.255.255.0
We are now ready to work with OpenFlow, so let's take a quick overview of the OpenFlow protocol.