---
title: "NS2 on Ubuntu 9.10"
description: "To install The Network Simulator - ns-2 we need to bit of circus. Install dependencies : $ sudo apt-get install libpcap-dev."
url: "https://h3manth.com/scribe/ns2-ubuntu-910/"
canonical_url: "https://h3manth.com/scribe/ns2-ubuntu-910/"
markdown_url: "https://h3manth.com/scribe/blog/ns2-ubuntu-910.md"
publishDate: "2010-02-13T00:00:00.000Z"
author: "Hemanth HM"
category: "linux"
tags: ["ubuntu","bash","web","linux"]
word_count: 118
reading_time_minutes: 1
x_markdown_tokens: 281
content_signal: "ai-train=yes, search=yes, ai-input=yes"
---

# NS2 on Ubuntu 9.10

> To install The Network Simulator - ns-2 we need to bit of circus. Install dependencies : $ sudo apt-get install libpcap-dev.

To install The Network Simulator - ns-2 we need to bit of circus.

**Install dependencies :** `$ sudo apt-get install libpcap-dev gcc-4.3 g++-4.3 tcl tk tk8.4-dev tcl8.4-dev xorg-dev sgb `

_By default gcc version is 4.4, but has ns2 compiles well only will 4.3 we need to downgrade gcc !_

**Backup the current links and update symbolic links :** ` $ sudo mv gcc gcc.old $ sudo mv i486-linux-gnu-gcc i486-linux-gnu-gcc.old $ sudo ln -s gcc-4.3 gcc $ sudo ln -s gcc-4.3 i486-linux-gnu-gcc `

**Download and Install ns2:** ` $ wget http://sourceforge.net/projects/nsnam/files/allinone/ns-allinone-2.33.tar.gz/download $ sudo tar zxvf ns-allinone-2.33.tar.gz $ sudo cd ns-allinone-2.33 $ sudo ./install `

**P.S : In case of nay issues with gcc or g++ restore the backup**
