First, disclaimer: I’m an HP employee. HP’s a major contributor to the OpenSwitch project. Just thought you should know in case you think that affects my opinion here.
If you need more info on the OpenSwitch project, you can check out the first post in this series here.
Getting our hands dirty
This section comes down into three steps, if you don’t follow these steps, you won’t succeed. I’m not going to go into details on these steps as I’m assuming you can figure this out if you found this blog. 🙂
– Install Virtual Box
– Install Vagrant
– Install Docker Toolbox
I’m running OpenSwitch on a Windows box in this case as the documentation covers the ‘IX build. I’m running on this natively on OSX which also means that I’ve got to install the docker toolbox plugin to get docker containesr to work. I’m also assuming that you’ve already installed Virtual Box and Vagrant for the following section.
Installing Vagrant Plugin
From a terminal window, run the vagrant plugin install vagrant-reload command from the CLI. This should show the following output.
Installing the OpenSwitch Dev Environment
For this section, I’m assuming you have already downloaded the vagrant files from here into your working directory.
Running the Docker Toolbox Plugin
Run the Docker QuickStart Terminal application and wait for the virtual box image to come to a running state. You should be able to see the following
From the terminal, navigate to where you have unzipped the OpenSwitch vagrant files that you downloaded from here. Run vagrant up command from the CLI. At this point some magic happens ( read more on Vagrant here if you’ve never worked with this tool before. Magic is obviously not magic, but I just don’t feel like explaining the whole process in this post. )
On a OSX box, you’re not running as root so you may end up with the following window
If you hit this, don’t worry, just SUDO it!
Accessing the OpenSwitch
From the same terminal window issue the sudo vagrant ssh command to be able to access the shell (CLI) of the OpenSwitch.
If you are successful, you should see the following output. Notice the shell has changed to vagrant@switch
Accessing the network interface
From the vagrant@switch prompt, issue the sudo vtysh command and you will now have access to an industry standard hierarchical CLI like we all know and love!
My thoughts so far
Getting this up and running has been relatively painless. There were a couple of small things to get it running that were particular to OSX which was not covered on the OpenSwitch quick start guide. Nothing that a little patience and google didn’t help me cover in a few minutes though. The install experience was pretty easy. The guides were pretty accurate and the getting this up and running should be something most of us can follow without much trouble.
OpenSwitch doesn’t have what I would call a robust network stack at this point in time, but we’re still really early in this world. Now that I’ve got it up and running, I’m looking forward to starting to look at the alternate interfaces such as OVSDB and REST as described here.
Anyone else got this up and running yet? Thoughts? Let me know in the comments below!