Bugzilla – Bug 2441
Can't change NSC-linux2.6.26 kernel attribute if Openflow module is enabled in NS3.
Last modified: 2017-01-09 08:20:18 EST
I am using nsc-0.5.3 with ns-3-dev 3.23 to test different tcp versions. I used the simple example "tcp-nsc-lfn" from examples/tcp to ensure the functionality of nsc. First I noticed that, if I run this script directly from the examples folder, it runs properly and allows me to change the tcp version using Config::Set ("/NodeList/*/$ns3::Ns3NscStack<linux2.6.26>/net.ipv4.tcp_congestion_control", StringValue (tcpver)). However, when I run the same script from the scratch folder it doesn't accept the "net.ipv4.tcp_congestion_control" attribute with one of the following error messages ( the error messages alternate each run). printk[0]: 0.000000) <4>nsc_convert_syserr_to_nscerr: Unhandled error number -1 msg="setting net.ipv4.tcp_congestion_control to hybla failed (retval -1 stack linux2.6.26", file=../src/internet/model/nsc-sysctl.cc, line=151 terminate called without an active exception OR msg="Attribute name=net.ipv4.tcp_congestion_control does not exist for this object: tid=ns3::Ns3NscStack<linux2.6.26>", file=../src/core/model/object-base.cc, line=198 After a lot of digging and investigations, I can confirm that there is a conflict caused by the enabled modules "Openflow" and "OFSwitch13". Unlike, "Scratch Folder" the examples are built against specific modules instead of all_modules, thus the script can run normally from examples. I interested to analyze different tcp variants available on the linux kernel on NSC stacks with the presence of openflow switch. my system is NS-3.23 on Ubuntu 14.04, x64 / gcc-4.8/4.9/5.3. python 2.7
Hi. First of all, it is important to note that the OFSwtich13 module (http://www.lrc.ic.unicamp.br/ofswitch13/) is a contributing code to the ns-3 project, but is not integrated to the main development tree and has no support assured. The error you are describing is related to setting a nsc attribute. Probably, the error should be fixed there, not on the OpenFlow module. However, as you are saying that this error only happens when the code is compiled and liked with the openflow libraries, the cause can be related to some code that is external to the ns-3 simulator. Both openflow modules can be used to do the same thing: simulate OpenFlow networks (however, the OFSwitch13 offer much more features than the standard Openflow module). Also, both modules uses external libraries to implement the switch datapaths, and this can be causing some conflicts. These modules are compiled and linked with extenal C libraries, supported only in linux environments. I'm not sure about what is happenning, but I would try disabling one of these modules (I would try first with the standard Openflow module) to see what's happening. Please, note that doesn't make sense to use both Openflow and OFSwtich13 modules together, so I would pick one of them to use. To effectivelly understand what is happening and how to fix it it would be good to have a simulation scrip inducing the error.