Can’t find a usable init.tcl in the following directories
sometimes while installing ns2 this error “application-specific initialization failed: Can’t find a usable init.tcl in the following directories: ” sucks , we don’t know what to do.
I have a solution.
application-specific initialization failed: Can’t find a usable init.tcl in the following directories:/root/ns2/ns-allinone-2.34/lib/tcl8.4 /usr/local/lib/tcl8.4 /usr/lib/tcl8.4 /usr/local/library /usr/library /usr/tcl8.4.18/library /tcl8.4.18/library /root/ns2/ns-allinone-2.34/lib/tcl8.4
or at local folder too
There are some solution please try may be they can help:
1) Go to location root-usr-local-bin by giving following command in terminal
2) There you would find the ns file. We just need to remove it by giving following command
3) Thats it, you are done. Now your ns starts running successfully.
This error can happen if you make any changes to the “ns-allinone-2.34/” directory :
Renaming the directory, moving the directory to another location,
i.e. anything that will change the “/home/arungupta2008/ns-allinone-2.34/tcl8.4.18/lib/” path.
Or when changes were made in /home/arungupta2008/ns-allinone-2.34/tcl8.4.18/lib/
The binary ‘ns’ is hard coded to know the location of it’s libraries, tclsh8* :
Workarounds, fixes :
1) cd ns-allinone-2.34/tcl8.4.18/ && ln -s lib/ library
2) Reinstall ns-allinone-2.34 2. The problem is because, ns executable is also at /usr which is conflicting.
Note : while removing symlinks first make that file removable then , you can remove that file for Ex. chmod 755 ns