LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 11-24-2010, 10:15 AM   #1
MounaRM
Member
 
Registered: Nov 2010
Posts: 35

Rep: Reputation: 14
problem with ns-2.34 installation on ubuntu 10.10


I've been trying to install ns-2.34 on ubuntu 10.10 so many times , each time I got an error in the installation, now I got this error :

trace/cmu-trace.o: In function `hdr_ant_pkt::access(Packet const*)':
cmu-trace.cc:(.text._ZN11hdr_ant_pkt6accessEPK6Packet[hdr_ant_pkt::access(Packet const*)]+0x7): undefined reference to `hdr_ant_pkt::offset_'
collect2: ld returned 1 exit status
make: *** [ns] Erreur 1
Ns make failed!

could anybody help me please !!
thanks for the help.
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 11-24-2010, 01:04 PM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
'ns-allinone-2.34' .. .. Ubuntu 10.10 Maverick

Welcome to LQ.

sudo apt-get install \
libx11-dev libxmu-dev libxmu-headers libxt-dev libtool

cd ns-allinone-2.34/ && ./install : No errors. ( -x86_64, amd64.)


Known issues : Nam may fail ..
Solution : cd ns-allinone-2.34/tk8.4.18 &&
patch -p0 < tk-8.4-lastevent.patch
... and then do './install' again.
...
 
Old 11-24-2010, 02:55 PM   #3
MounaRM
Member
 
Registered: Nov 2010
Posts: 35

Original Poster
Rep: Reputation: 14
not working !!! :(
I got :

patching file generic/tk.h
Hunk #1 FAILED at 635.
1 out of 1 hunk FAILED -- saving rejects to file generic/tk.h.rej
 
Old 11-24-2010, 04:41 PM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
The 'messages / information' output from patch are not errors.
They are informing you, that one of several lines do not require editing.

You can just continue ...

And by the way, nam is not that important :
Any binary nam can be used.
..

Suggest : Read some of the other ns2 threads for more information.
LQ Search , keyword = ns2
..
 
Old 11-25-2010, 04:05 AM   #5
MounaRM
Member
 
Registered: Nov 2010
Posts: 35

Original Poster
Rep: Reputation: 14
I am still having the same error :

trace/cmu-trace.o: In function `hdr_ant_pkt::access(Packet const*)':
cmu-trace.cc:(.text._ZN11hdr_ant_pkt6accessEPK6Packet[hdr_ant_pkt::access(Packet const*)]+0x7): undefined reference to `hdr_ant_pkt::offset_'
collect2: ld returned 1 exit status
make: *** [ns] Erreur 1
Ns make failed!

I checked the synaptic installed packages , I find out that the tck and tk installed version are 8.4.16
can this cause this problem ? and how to solve it ?

Thanks !

Last edited by MounaRM; 11-25-2010 at 04:22 AM.
 
Old 11-25-2010, 07:23 AM   #6
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Haven't noticed any problems with an installed tcl/tk lately,
when building ns2, but may be none was installed. ..

I used to give the advise :
Remove all tcl / tk before building ns-allinone-2.xx :

'sudo apt-get remove tcl8.4'

Ubuntu 10.10 Maverick has tcl8.4 / tk8.4 version 8.4.19 !

" 8.4.16 " is the old 'Ubuntu 8.04 Hardy' version.
You can still use that after the ns-allinone has been built,
if it is required for other applications. Else: use the default 8.4.19.

Version 8.4.16 will usually also work OK with ns2, I think.
..

Last edited by knudfl; 11-25-2010 at 07:26 AM.
 
Old 11-25-2010, 07:37 AM   #7
jestinjoy
Member
 
Registered: May 2004
Location: India
Distribution: Ubuntu 9.04, Debian Lenny
Posts: 121

Rep: Reputation: 22
re

I think a better solution for beginners is to install ns2 using PPA. It will automatically solve all the dependecy problems. Hope the following link help you:

http://opensourcetips.org/linux/ubun...n-6-easy-steps

If you find any difficulty. Reply back
 
2 members found this post helpful.
Old 11-25-2010, 08:28 AM   #8
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
@ jestinjoy, post # 7. Thank you.

The referred HOWTO is for Ubuntu 10.04 and 10.10 ?
http://opensourcetips.org/linux/ubun...n-6-easy-steps
Comments to the link : The package "ns" is not available any more.
'sudo apt-get install ns2' will provide /usr/bin/ns from ns-2.35~RC6.


( ns-2.35-RC6.tar.gz http://www.isi.edu/nsnam/dist/release/ )
..

Last edited by knudfl; 11-25-2010 at 06:10 PM.
 
1 members found this post helpful.
Old 11-25-2010, 08:48 AM   #9
jestinjoy
Member
 
Registered: May 2004
Location: India
Distribution: Ubuntu 9.04, Debian Lenny
Posts: 121

Rep: Reputation: 22
I successfully installed ns in both Debian Lenny and Ubuntu 10.04 from this PPA. It didint showed any dependency issues. In my Debian it reads version as "2.33-0ubuntu1" . Are you telling that any problem doing this.
 
Old 11-25-2010, 12:16 PM   #10
MounaRM
Member
 
Registered: Nov 2010
Posts: 35

Original Poster
Rep: Reputation: 14
thanks a lot for your help !
now NS2 is working ))
 
Old 11-26-2010, 06:56 AM   #11
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Some further explanations ..

Ubuntu 10.04 + all older versions starting with Hardy 8.04, i386, 32bit :
sudo apt-get install ns : Will provide ns version ns-2.33 from "ppa".

Ubuntu 10.04 amd64 : No packages. Probably valid for older versions too.
https://launchpad.net/~wouterh/+arch...s_filter=lucid

No ppa repo is required for Ubuntu 10.10 !
It's all included in the universe repo
http://packages.ubuntu.com/en/maverick/ns2 | i386 | amd64.
Hence 'sudo apt-get install ns2'.



#7 QUOTE : .. will automatically solve all the dependecy problems
#9 QUOTE : .. It didn't show any dependency issues
Comment : I don't think there are any known dependency issues with ns2 :
NS2 is very well documented here at LQ.
..

Last edited by knudfl; 11-26-2010 at 07:09 AM.
 
Old 08-17-2011, 09:37 PM   #12
aicaicai
Member
 
Registered: Aug 2011
Posts: 40

Rep: Reputation: Disabled
please help me

Quote:
Originally Posted by MounaRM View Post
thanks a lot for your help !
now NS2 is working ))
can you tell me your resolution.I meet the same error with you.
 
Old 01-12-2014, 01:07 AM   #13
narges62
LQ Newbie
 
Registered: Jan 2014
Posts: 5

Rep: Reputation: Disabled
when i make all in ns2, an error eccur

hi
i've been trying to add a new potocol in ns2-35
when i typing make in ns an error accur

trace/cmu-trace.o : In function `hdr_mcv::access(Packet const*)':
cmu-trace.cc : (.text._ZN7hdr_mcv6accessEPK6Packet[hdr_mcv::access(Packet const*)]+0x7):
undefined reference to `hdr_mcv:: offset_


could anybody help me please
thanks for the help.

Last edited by narges62; 01-12-2014 at 01:08 AM.
 
Old 01-12-2014, 08:26 AM   #14
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Post #13, @narges62.

Looks like you are using the wrong compiler (g++).
`ns-allinone-2.35' requires gcc/g++ version 4.4*.
Old protocols will often require g++ version 4.1.2 or 3.4.6 .

Which protocol is it about ? A link to some information, please.
Which OS are you using ? Please show the output from :
a) $ uname -m <Enter>
b) $ cat /etc/*release* <Enter>


-

Last edited by knudfl; 01-13-2014 at 02:20 PM.
 
Old 01-18-2014, 10:10 AM   #15
narges62
LQ Newbie
 
Registered: Jan 2014
Posts: 5

Rep: Reputation: Disabled
when i use make command

hi knudfl
thanks
i am using ubuntu 12.4 32 bit
i write a new portocol for vanet and i want to add to ns2.35
i changed necessary changes in cmu-trace and....
but when i use make command this error showing

trace/cmu-trace.o: In function `hdr_mcv::access(Packet const*)':
cmu-trace.cc: (.text._ZN7hdr_mcv6accessEPK6Packet[hdr_mcv::access(Packet const*)]+0x7): undefined reference to `hdr_mcv:: offset_'
collect2: ld returned 1 exit status
make: *** [ns] Error 1
 
  


Reply



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
[SOLVED] Ubuntu 10.04 installation problem edzams Linux - Newbie 1 07-31-2010 09:48 AM
g++ 3.4.4 installation problem in Ubuntu 9.04!!! Suranjit Linux - Software 9 10-09-2009 03:08 AM
Ubuntu installation problem jestinjoy Linux - Newbie 4 11-30-2008 11:21 AM
[Ubuntu] Installation problem Flippje Linux - Newbie 6 11-09-2005 01:20 PM
Ubuntu Installation Problem Norvegia Ubuntu 4 09-26-2005 01:25 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:33 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration