C++ compiler cannot create executables

Hey, guys,

If you’ve tried to install OFSoftswitch13, maybe you have faced with the problem: “c++ compiler cannot create executables” at ./configure stage even though you have installed the OFSoftswitch13 dependencies:

$ sudo apt-get install cmake libpcap-dev libxerces-c2-dev libpcre3-dev flex bison pkg-config autoconf libtool libboost-dev

The problem is because you probably did not have installed build-essential package. So, all you have to do, is to install it.

$ sudo apt-get install build-essential

That’s all,

Advertisements

Installing NOX dependencies on Ubuntu/Debian

Hi,

This is the simplest post. This post shows how to install NOX dependencies to compile and run it. Just follows the following script.

cd /etc/apt/sources.list.d/
$ sudo su
# wget http://openflowswitch.org/downloads/debian/nox.list
# apt-get update
# apt-get install nox-dependencies
# apt-get install libtbb-dev
# apt-get install libboost-serialization-dev libboost-all-dev

bye

Compiling NOX (zaku) on Fedora 14, kernel 2.6

Hi,

I always thought that we cannot to compile NOX on Fedora system. I have always used Ubuntu as my NOX controller in a VM. However, I don’t know why, but I was idle today (little :))… and so, I tried to compile it on my workstation. Well, I have tried before, but now I was passing more parameters for ./configure file. Well, after some minutes… success in compilation :). One of the issues that I have found, it was related to boost filesystem (boost::system::system_category error)… so I solved by putting -lboost_system library as a ./configure file parameter. Look this:

./configure --with-boost-filesystem=boost_filesystem --with-boost-unit-test-framework=mt --with-python=no LDFLAGS='-L/usr/include/openssl -lssl -lcrypto -lboost_system'

And, I almost forget.. I have problem with SWIG version… This is only necessary if you use python and c++ together. In my case, I don’t need to use any python module.. so I have disabled by putting –with-python=no parameter to ./configure file. Thereafter, I’ve did make to compile the controller.

Until next time,

How to start OpenFlow datapath and controller?

Hello all,

In OpenFlow-based software-defined network, we need two modules called OpenFlow datapath and controller (e.g. NOX). More specifically, in a commuter (OpenFlow-enabled switch/router) we need to start two daemons called ofdatapath and ofprotocol. The former is the datapath functioning itself and the latter, is an auxiliary module that is used to connect ofdataptah to an OpenFlow controller. Look this example:

Controller:

./nox_core -i ptcp:6633 switch

Datapath:

./ofdatapath -i eth0.1,eth0.2,eth0.3,eth0.4 -d 000000000001 --no-slicing punix:/var/run/sock
./ofprotocol unix:/var/run/sock tcp:192.168.1.10:6633

The parameter unix:/var/run/sock and tcp:192.168.1.10:6633 of ofprotocol are used to create a local connection to ofdatapath and a remote connection to NOX controller. That’s all.

Using Boost Filesystem V2 in NOX (zaku)

Hi,

When we try to compile NOX, it is possible to find compilation error with nox/src/nox/netapps/tablog/tablog.hh file. I solved it by inserting:

#include "component.hh"
#include "config.h"
#include "hash_map.hh"
#define BOOST_FILESYSTEM_VERSION 2
#include 
...

NOX (zaku): solving boot.sh problem

Hi,

After you try to run ./boot.sh file and this kind of errors appear:

`pkglibdir’ is not a legitimate directory for `SCRIPTS’

Try to edit nox/src/Make.vars file at line 56:

pkglib_SCRIPTS = $(NOX_RUNTIMEFILES) $(NOX_PYBUILDFILES)

to

pkgdata_SCRIPTS = $(NOX_RUNTIMEFILES) $(NOX_PYBUILDFILES)

This won’t solve everything probably, some warnings will occur, however in the end of ./boot.sh file execution, it will proceed and finish well. So, it’s possible to compile after that. This worked for me. 🙂

Compiling NOX, but openssl/md5.h not found

Hi,

It’s been a long time since my last post here. Well, today I’m gonna post about a common problem normally found when we try to compile NOX (zaku).  So, if ‘openssl/md5.h not found’ message appears, try to modify the file nox/config/ax_ssl.m4. You need to remove and add new commands in it.

Remove:

 AC_CHECK_LIB(ssl, MD5_Init,
             [SSL_LIBS="-lssl"; AC_SUBST(SSL_LIBS) break],
             [AC_ERROR([openssl/md5.h not found. NOX requires OpenSSL])])

Add:

 AC_CHECK_LIB(ssl, MD5_Init,
             [SSL_LIBS="-lssl"; AC_SUBST(SSL_LIBS) break],[
             AC_CHECK_LIB(crypto, MD5_Init,
             [SSL_LIBS="-lssl -lcrypto"; AC_SUBST(SSL_LIBS) break],
             [AC_ERROR([MD5_Init() is not linkable. NOX requires OpenSSL])])])

Thereafter, execute ./boot.sh file again. So try to compile normally.

$ ./configure --with-boost-filesystem=boost_filesystem --with-boost-unit-test-framework=mt LDFLAGS='-L/usr/include/openssl -lssl -lcrypto'
$ make