Install Open vSwitch v2 from Source on Red Hat Fedora 19

Install Open vSwitch v2 from Source on Red Hat Fedora 19

Redhat Ovs Sdn

Install Open vSwitch v2 on Red Hat Fedora 19

This is a walk through for installing Open vSwitch v2.0+ on RedHat Fedora 19 from source. If you want to build Open vSwitch from RPM binaries please see this post There are some new OVS tables included in the latest builds that include some neat concepts. OVS is often regarded as the SDN reference data plane implementation in the early SDN space. That is good for the industry and innovation as it reduces R&D risk and thus cost, which leads to less fragmentation and faster adoption of innovative ideas and architectures. Not to mention resides in easily over half of the vendors SDN DP kit in some form, fashion or library. I tend to make a case OVSDB is looking like the reference SDN management protocol based on real world adoption, not slide deckery. For more information on the Open vSwitch database schema, please see the ovsdb.conf spec. Fedora is a perennial favorite Linux platform for many and one of the many sponsored community projects by RedHat. Fedora is often perceived as more bleeding edge with regard to software software packaging then its counterparts, CentOS and the most conservative of the three, RHEL.

Download Fedora Images

Install a Supported Fedora Kernel Version for Open vSwitch

Start by downloading the Open vSwitch v2.0 (or any other release found here and install a Fedora Red Hat Distribution )

I ran into a dbus services bug with an error of the following:

A symlink will workaround the bug so you may want verify you have the latest NetworkManager patches:

If you have an existing installation from package, you can query and remove it with the following:

Then remove the existing. You can always upgrade but the extra step may avoid potential issues removing the kernel module:

Next pull the OVS tarball and unzip it:

Once you have Fedora up and running, we need to install a kernel version that is 3.10.x or lower. The default kernel in the install was 3.11.7. You can simply install whatever older version is available from the Yum repository. The following will enable you to search for different versions of the same package, in this case the kernel. For example:

If you do not install a different kernel version you will receive the following error from v2.0 currently.

The following installed a supported kernel version for OVS. Once complete, reboot your system.

Next install a few more dependencies.

Install Open vSwitch v2 from Source on Fedora

Now compile the source and load the kernel module.

If all went well, the OVS kernel module loaded and can be viewed with the following. If there were any problems view the kenel messages in the output of “dmesg”.

At this point, you “should” be able to run a startup script and cover the config initializations with the following:

From there you can run some tests to verify the build such as:

If you want to start and initialize the processes by hand continue with the post.

Next Start Open vSwitch on Fedora with the following to create the OVS initial database for ovsdb-server and start the OVS vswitchd daemon.

Lastly we verify the OVS version and test adding an OVS bridge.

Install Open vSwitch on RedHat Fedora from Binary with Yum

If you just want to get Open vSwitch up and running on your RedHat system you can simply install the binary from the Yum repo manager.

Order of operation and dependencies are abstracted under the hood with some of the following service scripts.

The Yum version at the time of this post is 1.11.0. If you compiled from source and then installed from package you will need to delete or migrate conf.db.

For troubleshooting the startup files are located in the systemd directory structure of Fedora. They can be viewed with the following and some additional commands.

For troubleshooting look for the processes and verify the db and pid files exist and not locked.

Get to Know Open vSwitch, Fedora and RedHat Projects

Software companies will and are driving hardware networking companies. Open source software initiatives drive proprietary software platforms and applications. That is not to say hardware or hardware companies are not innovative, but its clear we are heading towards an unbundling of vertical solutions.

Community software projects are revolutionizing technology infrastructures as much as ever. Vertical segments get broken down from the bottom up. The projects used in this tutorial were originally developed by visionary companies in Nicira (now Vmware) with Open vSwitch and RedHat with its legacy of Linux kernel development and open source stewardship.

Get involved in any of the awesome OSS infrastructure projects out there. If you are interested in SDN and are not sure where to start, swing by #opendaylight-ovsdb, #openvswitch or #opendaylight on and say hello. Community leaders are quickly identified and ready to assist. The ODL folks are a mix of traditional networking professionals and software developers, collaborating and cross-training truly enjoying such a unique time in the industry. More on OVS, OVSDB and OpenDaylight in the next couple of days as my friend Madhu Venugopal of RedHat and one of the best community conscious developers around. We will be recording some videos this weekend about the OVSDB OpenDaylight project to help folks get started so stop back by!

About the Author

Brent SalisburyI have over 15 years of experience wearing various hats from, network engineer, architect, devops and software engineer. I currently have the pleasure of working at the company that develops my favorite software I have ever used, Docker. My comments here are my personal thoughts and opinions. More at Brent's BioView all posts by Brent Salisbury →

1 year 6 months ago

Great reference. I keep coming back to it over and over….