Network Simulator 2 (NS2) : Tools For
Tcl Scripts In NS2
Tools for generating TCL Script
for NS2
NS2 a very common and widely used tool to simulate small
and large area networks. Tcl scripts are widely used in
NS-2 simulation tool. Tcl scripts are used to set up a wired
or wireless communication network, and then run these scripts
via the NS-2 for getting the simulation results.Several
tools are available to design networks and generate TCL
scripts some of them are discussed below
I. NS2 scenario Generator (NSG):
Its a java based tool that can run on any platform and
can generate TCL scripts for wired and Wireless scenarios
for NS2.Main features of NSG are:
Creating Wired and wireless nodes by drag and drop.
Creating Simplex and Duplex links for wired network
Creating Grid, Random and Chain topologies.
Creating TCP and UDP agents. Also supports TCP
Tahoe, TCP Reno, TCP New-Reno and TCP Vegas.
Supports Ad Hoc routing protocols such as DSDV,
AODV, DSR and TORA.
Supports FTP and CBR applications.
Supports node mobility.
Setting the packet size, start time of simulation,
end
Time of simulation, transmission range and interference
Range in case of wireless networks, etc.
Setting other network parameters such as bandwidth,
etc for wireless scenarios
II. Visual Network Simulator (VNS):
This tool is centered on capabilities of NSG. It also
provides support to Differentiated Services (DiffServ) scenarios
and simple and intuitive set of icons to represent the components
of a network. Some features of VNS are given below:
Adding and configuration of links, agents and traffic
sources.
Modeling network scenarios with support to multicast.
Selection of a dynamic routing protocol.
Definition of the simulation output as an animation
and/or graphics.
Edition of the Tcl script generated.
Saving the defined simulation scenario
III. NS 2 Workbench
Ns Bench makes NS-2 simulation development and analysis faster
and easier for students and researchers without losing the flexibility
or expressiveness gained by writing a script. Some features
are:
Creating "Groups" concept to compensate for "loops"
Scenario generator.
Link Monitors.
Loss Models.
Routing Protocols
IV. Network Simulation by Mouse (NSBM)
NSBM, developed in java, is a graphical tool that is used
to generate TCL script using a mouse. Nodes and links can be
created with a single mouse click. You can draw a network topology
with multiple nodes with only a few mouse clicks. Afterwards
you click on a button and there is the TCL code, almost ready
for use with the ns.
NSBM used in order to process the XML configuration data.
It must provide many functions, which are specified only in
the configuration data at run time. Because the classes are
implementation-specific, classes generated by the binding compiler
in one JAXB implementation will probably not work with another
JAXB implementation. So if you change to another JAXB implementation,
you should rebind the schema with the binding compiler provided
by that implementation
Trace Files Generated in NS2
NS2 currently supports a number of different types of trace
files. In addition to its own format, NS2 also has the Nam trace
format, which contains the necessary information from the simulation
to drive the Nam visualizer. Both of these trace formats are
very specific when it comes to giving details about the events
that occur during an NS2 simulation.
Traces and monitors represent the only support for data collection
in ns-2. Traces record events related to the generation, enqueueing,
forwarding, and dropping of packets. Each event corresponds
to a line of ASCII characters, which contains information on
the event type and the information stored into the packet
NS-2 provides three kinds of formats for wired networks:
Tracing, Monitoring and NAM trace file.