LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 12-29-2009, 05:43 AM   #1
Makrand Naik
LQ Newbie
 
Registered: Dec 2009
Posts: 1

Rep: Reputation: 0
1 error when calling class OldSim:


hi
i need to know how to run a tcl script on ns 2-30
ive installed it on fedora 9
the installation was succeessfull
and i have also set the path of the variables correctly
but whenever i start ns, and try to execute a tcl script
i get an error as 1 error when calling class OldSim:

Please tell me where am i wrong
and suggest a correct way to work this out
 
Old 12-30-2009, 05:49 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,519

Rep: Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495
Welcome to LQ.

Any particular reason to use the old ns-2.30 ?
The latest version is 2.34 , works OK on Fedora 9.

I never saw the error, you have.
How did ./validate turn out ?

Is it all tcl sripts, causing that error ?
Please try with some of the 300 scripts in ns-2.30/tcl/

Or use some of the examples e.g.
http://nile.wpi.edu/NS/simple_ns.html
from http://nile.wpi.edu/NS/

Or .. http://www.isi.edu/nsnam/ns/tutorial/
http://www.isi.edu/nsnam/ns/tutorial/nsscript1.html
http://www.isi.edu/nsnam/ns/tutorial.../example1b.tcl
etc. etc.
.....
 
Old 06-05-2010, 04:07 AM   #3
noorzaman
LQ Newbie
 
Registered: Jun 2010
Posts: 1

Rep: Reputation: 0
Thumbs up OldSim error Recovery

This is not an error in actual, but this is a wrong attempt to execute your script file like following way.
Running script like this is not allowed , I mean it will generate the error ( $ ns

% ns examplename.tcl <~~~~ Please DON'T go like this )


Please run your script like this way.

$ ns examplename.tcl <~~~~ DO this way

Noor Zaman
 
Old 12-28-2010, 10:55 AM   #4
zungeru
LQ Newbie
 
Registered: Dec 2010
Location: Kajang, Malaysia
Posts: 1

Rep: Reputation: 0
same trouble I am facing

Quote:
Originally Posted by noorzaman View Post
This is not an error in actual, but this is a wrong attempt to execute your script file like following way.
Running script like this is not allowed , I mean it will generate the error ( $ ns

% ns examplename.tcl <~~~~ Please DON'T go like this )


Please run your script like this way.

$ ns examplename.tcl <~~~~ DO this way

Noor Zaman
I amalso facing the same trouble, pls help

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
}
set n0 [$ns node]
set n1 [$ns node]

$ns duplex-link $n0 $n1 1Mb 10ms DropTail

$ns at 5.0 "finish"

$ns run


zungeru@zungeru-AOA110:~$ ns example1.tcl
can't read "ns": no such variable
while executing
"$ns namtrace-all $nf"
(file "example1.tcl" line 2)
zungeru@zungeru-AOA110:~$
 
Old 12-28-2010, 11:46 AM   #5
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,519

Rep: Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495
Post # 4, @ zungeru : Welcome to LQ.

1) cd ns-allinone-2.34/ns-2.34/ ( Or whatever your version is ).
2) su ( or sudo 'make install', if you have Ubuntu.)
2a) make install : The binary 'ns' will be copied to /usr/local/bin/
... and ns will always be in your path.

The same can be done with nam : 'make install' will copy one file to
/usr/local/bin/ : 'nam'

..
 
Old 03-10-2013, 12:25 AM   #6
Amithaspalan
LQ Newbie
 
Registered: Mar 2013
Posts: 1

Rep: Reputation: Disabled
class oldsim error

we have to run tcl script like this"xxxx@xxxx-PC:~$ns filename.tcl"
 
  


Reply

Tags
error, recovery


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ns:"error when calling class OldSim"&tclsh:"invalid command+child process exits abn." shojaru Linux - Newbie 0 03-05-2009 04:23 AM
Error calling Functions: Command Not Found ravi2ray Linux - Newbie 2 12-03-2008 12:14 PM
Calling to mysql error syok Suse/Novell 2 07-15-2008 12:04 AM
PHP: Calling class functions from another class. unreal128 Programming 5 11-24-2006 03:04 AM
Strange error calling fopen() twice Nerox Programming 4 07-05-2004 07:27 AM


All times are GMT -5. The time now is 01:38 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration