Ns3 Projects for B.E/B.Tech M.E/M.Tech PhD Scholars.  Phone-Number:9790238391   E-mail: ns3simulation@gmail.com

NS 3.28 INSTALLATION STEPS

Network Simulator 3 (ns-3) is a free, flexible, and strong tool for computer network simulations. It allows users to create, test, and verify network behaviour in different situations. The simulator’s modular design makes it simple to add or modify parts. Network architects and researchers can use it to test and improve network protocols, layouts, and devices, helping to develop new network technologies and designs. Feel free to address all your doubts to ns3simulation.com we will provide you with good execution support.

We’re elated to share a comprehensive article on how to install Network Simulator 3.

PRE-REQUISITES:

  1. Fresh installation of Ubuntu 18.04 LTS:

Screenshot:

Fresh installation of Ubuntu 18.04 LTS

2.Download ns-allinone-3.28.tar.bz2 file:

We have to download the ns-allinone-3.28.tar.bz2 under home directory by the clicking the Link, it will directly download to Download Location and move the compressed file to the home Directory.

Link: https://www.nsnam.org/releases/ns-allinone-3.28.tar.bz2

Screenshot:

3.Extraction of the ns-allinone-3.28.tar.bz2 file:

Next, we have to extract the compressed file by right click and click Extract here to extract the ns-allinone-3.28 as folder in the home directory.

Screenshot:

Extraction of the ns-allinone-3_28_tar_bz2 file

Screenshot:

Extraction of the ns-allinone-3_28_tar_bz2 file

ns-allinone-3.28 compressed file Extracted Successfully in the home directory.

INSTALL DEPENDENCIES OF NS3:

  1. Open a terminal, Copy and Paste the commands to install required package:

Screenshot:

Open a terminal

2.System File Update Command:

First of all, we need to updates the list of available packages and their versions stored in the system’s package index. Use below command to update the system package.

Command:      “sudo apt-get update”

Screenshot:

System File Update Command

3.Install Essential Tools:

    1. g++: A C++ compiler from the GNU Compiler Collection, essential for compiling C++ programs.
    2. python: The Python programming language interpreter, used for running Python scripts and applications.
    3. cmake: A cross-platform tool for managing the build process of software using a compiler-independent method.
    4. git: A distributed version control system for tracking changes in source code during software development.
    5. gcc: A compiler system that supports various programming languages, including C, C++, Objective-C, Fortran, Ada, and more.

Command:      “sudo apt install g++ python cmake git gcc”

Screenshot:

Install Essential Tools

Click the key Y to install the required Essentials tools for giving permission to install the package in the user system.

Install Essential Tools6.2-Install Essential Tools

Installation of the Essential tools package completed successfully.

  1. Install Required Libraries and Development Tools:
    • python3-dev: Header files and a static library for Python development.
    • pkg-config: Helps to manage compile and link flags for libraries.
    • autoconf: Tool for generating configure scripts.
    • automake: Tool for generating Makefile.in files.
    • libc6-dev, libc6-dev-i386: Development libraries for the GNU C Library.
    • libclang-dev: Development files for Clang, a C language family frontend for LLVM.
    • llvm-dev: Development libraries for LLVM.
    • libboost-all-dev: Boost libraries development files.
    • gsl-bin, libgsl-dev, libgslcblas0: GNU Scientific Library development files and binaries.
    • python3-setuptools: Tools for installing Python packages.
    • python3-gi, python3-gi-cairo: Python bindings for gobject-introspection libraries.
    • python3-pygraphviz: Python interface to Graphviz.
    • ipython3: Enhanced interactive Python shell.
    • qtbase5-dev, qtchooser, qt5-qmake, qtbase5-dev-tools: Development files and tools for Qt 5.
    • 2-goocanvas-2.0, gir1.2-gtk-3.0: GObject introspection data for GooCanvas and GTK+.
    • openmpi-bin, openmpi-common, openmpi-doc, libopenmpi-dev: MPI libraries and tools for parallel computing.
    • cvs: Concurrent Versions System, a version control system.
    • bzr: Bazaar, a distributed version control system.
    • unrar: Unarchiver for .rar files.
    • wireshark, tcpdump: Network protocol analyzers.
    • gdb: The GNU Project Debugger.
    • valgrind: Tool for memory debugging, memory leak detection, and profiling.
    • uncrustify: Source code beautifier for C, C++, C#, Objective-C, D, Java, Pawn, and Vala.
    • doxygen: Documentation generator from annotated C++ sources.
    • graphviz: Open-source graph visualization software.
    • imagemagick: Software suite to create, edit, and compose bitmap images.
    • texlive, texlive-extra-utils, texlive-latex-extra, texlive-font-utils, texlive-lang-portuguese: TeX Live and related utilities for typesetting documents.
    • dvipng: Convert DVI files to PNG graphics.
    • latexmk: Automated LaTeX document generation.
    • python-sphinx: Python documentation generator.
    • dia: Diagram editor for GNOME.
    • flex, bison, libfl-dev: Tools for generating and compiling lexical and syntax analyzers.
    • sqlite, sqlite3, libsqlite3-dev: SQLite database command-line interface and development files.
    • libxml2, libxml2-dev: Libraries for parsing XML.
    • libxmu-dev: Development headers for the X11 miscellaneous utility library (libXmu).
    • build-essential: Meta-package that includes essential tools for compiling software from source code.
    • 0-0, libgtk2.0-dev: Libraries and development files for GTK+ 2.0.
    • vtun: Virtual Tunnels over TCP/IP networks.
    • lxc: Linux Containers, a lightweight virtualization system.
    • libboost-signals-dev: Boost Signals library development files.
    • libboost-filesystem-dev: Boost Filesystem library development files.
    • cxxfilt: Python library that allows you to demangle C++ symbols

Command:           

“sudo apt-get install -y python3-dev pkg-config autoconf automake libc6-dev libc6-dev-i386 libclang-dev llvm-dev libboost-all-dev gsl-bin libgsl-dev libgslcblas0 python3-setuptools python3-gi python3-gi-cairo python3-pygraphviz ipython3 qtbase5-dev qtchooser qt5-qmake qtbase5-dev-tools gir1.2-goocanvas-2.0 gir1.2-gtk-3.0 openmpi-bin openmpi-common openmpi-doc libopenmpi-dev cvs bzr unrar wireshark tcpdump gdb valgrind uncrustify doxygen graphviz imagemagick texlive texlive-extra-utils texlive-latex-extra texlive-font-utils texlive-lang-portuguese dvipng latexmk python-sphinx dia flex bison libfl-dev sqlite sqlite3 libsqlite3-dev libxml2 libxml2-dev libxmu-dev build-essential libgtk2.0-0 libgtk2.0-dev vtun lxc libboost-signals-dev libboost-filesystem-dev qt5-default”

Screenshot:

Install Required Libraries and Development Tools

Click Yes to install wireshark packages to capture the packets from Network simulator 3.

Screenshot:

Install Required Libraries and Development Tools

Screenshot:

Install Required Libraries and Development Tools

To Enable Python Bindings, we need to use command to install required packages.

Command:

“sudo apt-get install python3-pip && sudo pip3 install cxxfilt”

Screenshot:

Install Required Libraries and Development Tools

Installation of the Required Libraries and Development Tools package completed successfully.

INSTALL NETWORK SIMULATOR 3 (NS3):

  1. Locating the ns-allinone-3.28 Folder:

Next, we need to install the NS 3 in our system so locate the Extracted ns-allinone-3.28 folder in the home directory.

Screenshot:

Locating the ns-allinone-3_28 Folder

2.Launching the terminal in the ns-allinone-3.28 Folder:

Then Right Click in the current Directory and select the “Open in Terminal” button and it will launch the terminal.

Screenshot:

Launching the terminal in the ns-allinone-3_28 Folder

Here, we launched the terminal by that button in the folder.

Screenshot:

Launching the terminal in the ns-allinone-3_28 Folder

3.Building the terminal in the ns-allinone-3.28 Folder:

Next, we need to build the ns-3.28 to install the network simulation 3 Environment in the User system and it will build the netanim also. So, use the command to build the ns-3.28.

Command:      “./build.py”

Screenshot:

Building the terminal in the ns-allinone-3_28 Folder

Netanim Building process:

Screenshot:

Netanim Building process

Ns-3.28 Configuring process:

Screenshot:

Ns-3_28 Configuring process

The “./ns3 configure” command is to configure the Network Simulator 3 (NS-3) environment. This command is typically used to set various parameters, such as the simulation duration, network topology, and node properties. It can also be used to specify the output format and other simulation settings.

Screenshot:

Ns-3.28 Configuration Completed successfully.

Ns-3.28 Building process:

Screenshot:

Ns-3_28 Building process

The “./ns3 build” command is used to build the Network Simulator 3 (NS-3) framework from its source code. When use this command, It will compiles the source code, generates the Makefiles, and builds the NS-3 binary and libraries and make Runnable Environment.

Screenshot:

Ns-3_28 Building process

Ns-3.28 Installed successfully in the Ubuntu 18.04 system. Get best developers care to get your implementation done it you face any errors, we will give you best solution.