LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   ns 2.34 on ubuntu 9.04 (https://www.linuxquestions.org/questions/linux-newbie-8/ns-2-34-on-ubuntu-9-04-a-919181/)

kozomoja 12-17-2011 05:40 AM

ns 2.34 on ubuntu 9.04
 
Hi,

I'm trying to install ns 2.34 on ubuntu 9.04, running on VMware 7.01.
I follow this instructions: http://gulzameenkhan.wordpress.com/2...u-9-10-32-bit/ but I got stuck on this command:
$sudo apt-get install build-essential autoconf automake libxmu-dev
I get 'Failed to fetch <some URL> 404 Not Found'.

Any suggestions?

knudfl 12-17-2011 06:43 AM

Welcome to LQ.

Ubuntu 9.04 is obsolete. The repo was moved to the Ubuntu old archive.
Your new '/etc/apt/sources.list' must be changed to these lines only :
( "hardy" lines can be kept, if any.)
Code:

deb http://old-releases.ubuntu.com/ubuntu/ jaunty main
deb http://old-releases.ubuntu.com/ubuntu/ jaunty multiverse universe
deb http://old-releases.ubuntu.com/ubuntu/ jaunty-updates main multiverse universe
deb http://old-releases.ubuntu.com/ubuntu/ jaunty-security main multiverse universe

..
Quote:

sudo apt-get install build-essential autoconf automake libxmu-dev
This will do :
sudo apt-get install g++ make automake autoconf \
libx11-dev libxmu-dev libxmu-headers libxt-dev libtool

..

kozomoja 12-17-2011 10:08 AM

I can't find the file you're reffering to (sources.list) anywhere on Ubuntu and when I try the code below, I get: 'Couldn't find package libx11-dev'...

snowday 12-17-2011 10:21 AM

Use a supported Ubuntu release (10.04 or newer), problem solved.

knudfl 12-17-2011 11:22 AM

The file sources.list is located in /etc/apt/ ,
like said in post # 2.

Suggest :
Create a new file 'sources.list' in your /home/<name> with the 4 lines.

Then : sudo cp -a sources.list /etc/apt/
Next : sudo apt-get update
... And you are ready to install packages.


Ref. post # 4 : Ubuntu 10.04 and 10.10 are the latest to use for ns2.
Ubuntu 11.04 requires special compilers. ( Like a "g++42-compat" ).
Ubuntu 11.10 : Not at all usable.

..

kozomoja 12-18-2011 07:47 AM

I downloaded Ubuntu 10.10 and installed ns-2.34 (no errors), changed environment variables, ran validation with no errors and now I'm trying to run a simple script:
Quote:

set ns [new Simulator]
set nf [open out.nam w]
$ns namtrace-all $nf



proc finish {} {
global ns nf
$ns flush-trace
close $nf
exec nam out.nam &
exit 0
}


$ns at 5.0 "finish"
$ns run
and get following error:

Quote:

ns: finish: couldn't execute "nam": no such file or directory
while executing
"exec nam out.nam &"
(procedure "finish" line 5)
invoked from within
"finish"
anyone familiar with this...?

knudfl 12-18-2011 08:29 AM

# 6

cd ns-allinone-2.34/nam-1.14/ && sudo make install

( 'make install' will simply copy nam to /usr/local/bin/ :
Then it is in a system path. You can do the same with ns ).

Quote:

changed environment variables
Not required.


May be nam wasn't created ?
Use another binary nam : Unpack, and 'sudo cp nam /usr/local/bin/'
https://docs.google.com/open?id=0B7S...k4NGI5NzliM2Ux
> nam-1.14.i586.tar.gz

.

kozomoja 12-18-2011 02:35 PM

Thank you very much, that first command solved my problem!


All times are GMT -5. The time now is 01:37 AM.