Hi all,

at the SIGNET lab, Dept. of Information Engineering, University of
Padova, Italy, we've developed a patch for ns2 which enables effective
use of dynamic libraries in ns2. We believe that the introduction of
this feature substantially improves the current way of developing
extensions to ns2. A list of the offered advantages is reported below:

* People can develop add-ons for ns2 (e.g. introducing new agents,
packet types, protocols) without having to modify the core simulator.

* New packet headers and types, as well as packet tracers, could be
defined to assist debugging, collection of statistics and inter-module
communication. These can also be loaded on demand according to user's needs.

* Dynamic libraries can be loaded at simulation time, with no need to
recompile the whole ns2 distribution or to keep different ns2 binaries.

* The installation of third-party ns2 extensions is made easier, thereby
facilitating their dissemination.

* Dynamic libraries will make life easier for lab technicians and
students. In fact, an official ns2 version can be installed by
administrators, and students can just build and use their preferred
extensions independently.

* ns2 will become more modular and scalable, while at the same time
preserving backwad compatibility.


We observe that dynamic libraries are natively supported in ns2 (see Tcl
load functionality). However, the set of functionalities which can be
accounted for by means of this approach is severely limited by the
intrinsic structure of the simulator. As an example, new packet types
and headers cannot be added to the code. In order to remove these
limitations, the patch we developed enables dynamic definition of packet
types, headers and their corresponding tracers.

Special care has been taken to ensure backward compatibility: the patch
has been designed in order not to interfere with the existing
functionalities in ns2. We have been testing this patch on different
linux systems since summer 2006, and so far we did not encounter any issue.

The patch is available at this location:
http://www.dei.unipd.it/~rossi/ns2-patch.html

Also, a detailed documentation of the modifications introduced by the
patch, as well as a tutorial for building ns extensions as dynamic
libraries, can be found at this location:
http://www.dei.unipd.it/~baldo/ns_dl_patch

Finally, we also provide a few sample modules to allow a straightforward
evaluation of the benefits provided by our patch. In particular, we
provide dynamic library versions of the UMTS implementation by the
EURANE project and of the TCP Veno implementation by NTU. The relative
packages can be found at this location:
http://www.dei.unipd.it/~baldo/ns_dl_patch/Sample_dynamic_ns_modules.html


Of course, any feedback on our proposal is welcome!


Regards,

Nicola





Reply via email to