Welcome to LQ.
Log in as root : Please never do that. Is unsafe.
And if you do, make it short, and log out again ASAP.
The command ( su ( root )) : system-config-users
.. can set up a new user.
ns2 :
http://nsnam.isi.edu/nsnam/index.php/User_Information
And : LQ Search > > Tag Name = ns2
Which ns2 are you trying to install ? ?
Recommended is : ns-allinone-2.34 .. in this location :
/home/<user>/ns2/ns-allinone-2.34/
To make it work this is also recommended :
# yum remove tcl tcl-devel tk tk-devel
tcl, tk version 8.4.xx can be reinstalled after the ns2 build.
.....