LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-13-2013, 08:08 AM   #1
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Rep: Reputation: Disabled
Segmentation Fault with GPSR-HLS (hls.tcl)


I patched NS 2.33 for GPSR using http://www.cn.uni-duesseldorf.de/alu.../hls-ns2-patch When I run hls.tcl in hls/utils/

it gives me
Sorting lists done ...
Segmentation Fault (core dumped)

When I run the nam file it runs only for 1 second whereas I set the time to 200 secs.

Any help is highly appreciated.
 
Old 04-14-2013, 06:11 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153
Welcome to LQ.

Segmentation Fault : Looks like a failed build of ns-2.33 / GPSR-hls ?
Which OS are you using ? 1) $ cat /etc/*release* ; 2) uname -m

Or may be you edited the file 'hls.tcl' ?
There is no "out.nam" from the original 'hls.tcl'.

All hls examples : gpsr-hls-examples-0113.tar.gz
https://docs.google.com/file/d/0B7S2...it?usp=sharing

All LQ GPSR-hls http://www.linuxquestions.org/questions/tags/gpsr-hls/
GPSR-KeLiu http://www.linuxquestions.org/questi...gs/gpsr-keliu/

-

Last edited by knudfl; 04-14-2013 at 07:24 AM.
 
Old 04-14-2013, 07:48 AM   #3
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
#2

I am using
Ubuntu 12.10
i686

I tried running ssoumayaa.tcl but same error
"Starting Simulation"
Segmentation fault core dumped
 
Old 04-14-2013, 08:48 AM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153
#3 : GPSR-hls can be built on Ubuntu 12.10 .

a) cd ns-allinone-2.33/ns-2.33/
b) patch -p1 < ns-2.33-hls.patch
c) tar xvf hls-files-ns233.tar.gz
d) cd ../
e) export CC=gcc41 CXX=g++41 && ./install

f) cd ns-2.33/ ; ./ns : OK.
sudo cp ns /usr/local/bin/
cd hls-utils/ ; ns hls.tcl : OK.
ns ssoumayaa.tcl : OK.
bash run_small.bat : OK.

-
 
Old 04-14-2013, 11:55 AM   #5
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
#4

I have made the patch and it worked fine without any errors.
I also install greedy routing protocol
http://www.cse.ohio-state.edu/~sakai...s2_greedy.html

but scripts for this protocol give the same error as well.

I guess there might be some problem with my ns-2.33 installation. I had one more ns-2.33 installation in other directory that got corrupt. No sure what is causing the problem. I will test with AODV, DSDV and let you know.
 
Old 04-14-2013, 12:47 PM   #6
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153
# 5 .

You will have to be very careful when you add more than one patch/extra protocol.
Some patches will make conflicting changes to the files.
 
Old 04-14-2013, 12:56 PM   #7
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
#4
Did export CC=gcc41 CXX=g++41 && ./install

but got the following error

Code:
* Build tcl8.4.18
============================================================
configure: WARNING: unrecognized options: --enable-gcc
checking whether to use symlinks for manpages... no
checking whether to compress the manpages... no
checking whether to add a package name suffix for the manpages... no
checking for gcc... gcc41
checking whether the C compiler works... no
configure: error: in `/home/devan/Documents/ns-allinone-2.33/tcl8.4.18/unix':
configure: error: C compiler cannot create executables
See `config.log' for more details
tcl8.4.18 configuration failed! Exiting ...
 
Old 04-14-2013, 01:07 PM   #8
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
Fixed #7

export CC=/usr/bin/gcc-4.7 CXX=g++-4.7

Last edited by devanthakur; 04-14-2013 at 01:36 PM.
 
Old 04-14-2013, 01:34 PM   #9
devanthakur
LQ Newbie
 
Registered: Mar 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
I don't know how but after the last step

Quote:
export CC=/usr/bin/gcc-4.7 CXX=g++-4.7
I did ./install

and now everthing works fine. No segmentation fault.
Thanks Knudfl for your support. I appreciate that.
 
  


Reply


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
yast segmentation fault, system freezing - nvidia driver at fault? BaltikaTroika SUSE / openSUSE 2 12-02-2005 10:34 AM
Segmentation Fault monojit_18 Programming 1 12-12-2004 12:22 PM
segmentation fault for everything gsv Linux - Newbie 1 08-23-2004 07:19 PM
Segmentation fault.. please help me! rpmadness Linux - Software 4 11-25-2003 07:47 PM
Segmentation fault suriyamohan Linux - General 5 10-21-2003 02:37 AM


All times are GMT -5. The time now is 08:21 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration