1. Follow the tutorial below to install
Install with Me!: What to install NS-2.35 in ubuntu-13.10/14.04 (in 4 easy steps)
2. When running an example program, ***buffer overflow detected * *: NS terminated
3. Refer to Existing scheme, GCC error:4.4 does not have that file or directory
sudo apt-get intall gcc-4.4
sudo apt-get intall g++-4.4
Modify the file under the Tcl8.4.18/unix folder makefile.in
CC = @[email protected] modified to: CC = @[email protected]-V 4.4
Resolved * * * * Buffer Overflow detected * * *: NS terminated_xuelinger_2010_ Sina Blog
4. After adding the following command on the 3 basis, NS completes the compilation
rm /usr/bin/gccrm /usr/bin/g++ln -s /usr/bin/gcc-4.4 /usr/bin/gccln -s /usr/bin/g++-4.4 /usr/bin/g++
Choose gcc and g++ version-ask Ubuntu
5. Re-enter terminal, run the program with the NS command, and no longer prompt for buffer overflow error
Ubuntu 14.04 ns2.35 ***buffer Overflow detected *: NS terminated solution