Installing openvswitch in CentOS 6.3

Okay, once I installed CentOS 6.3 in my N40L, it’s time to prepare the tools for my virtual lab environment.
I’m willing to test openvswitch so I read the documentation from the project’s webpage.

I’m goint to use openvswitch as a bridge module replacement. The documentation is easy to read and quite clear, just browse it slowly so you don’t miss important things. These are the notes I took during the installation…

  • First of all, check if the bridge kernel module is loaded with “lsmod | grep bridge”, it it’s loaded remove it with “rmmod bridge”.
  • Let’s install some packages with yum (I’m using epel repository just in case!):
     yum install make gcc pkgconfig openssl openssl-devel glibc-devel iproute kernel-devel git python python-zope-interface python-twisted-conch PyQt4 wget 
  • Warning #1: I tried to build the latest release (1.7.1 at the time of writing) and the long-term support release with no success. Compilation failed, complaining about skb_frag_page() was redefined, and here you can find the problem with Red Hat / CentOS 6.3. I had to use the source code from their git repository.
  • Warning #2:You’ll need autoconf > 2.63 if you want to build the latest openvswitch from git. Sorry… you’ll have to download and compile autoconf first:
     make install
  • Then I created a non-root user to build openvswitch and I got into /home/ovswitch:
    adduser ovswitch
    cd /home/ovswitch
  • I downloaded the source from the project’s git repository. Then inside openvswitch directory, and as your non-root user let’s compile Openvswitch:
    git clone git://
    ./configure --with-linux=/lib/modules/`uname -r`/build
  • And now as root user:
    make install
  • Ok. As openvswitch’s documentation suggests, let’s try to load the module:
    cd datapath/linux
    insmod openvswitch.ko
  • If no error was shown…
    make modules_install

And that’s all!, now I’m going to learn how to use openvswitch…


6 thoughts on “Installing openvswitch in CentOS 6.3

    • n40lab says:

      have you run the ./ command, after downloading the git version? you need to run that command to generate the configure file.

      Hope it helps and thanks for posting your feedback.


      • Ashutosh Narayan says:

        When I run ./ I get the following error:
        Can’t exec “aclocal”: No such file or directory at /usr/local/share/autoconf/Autom4te/ line 326.
        autoreconf: failed to run aclocal: No such file or directory

        How to get rid of this ?


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 )

Twitter picture

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

Facebook photo

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

Connecting to %s