core dumped

98 views
Skip to first unread message

belhadj aissa

unread,
Feb 28, 2024, 4:51:40 PM2/28/24
to Network Simulator 2 (NS2)
when i run a tcl file with 802.11p configuration it display segmentation fault core dumped

knudfl

unread,
Feb 29, 2024, 4:22:31 AM2/29/24
to Network Simulator 2 (NS2)
Unknown file-name, unknown simulation.
If you want a precise answer,  the command must be shown.
And :  Your OS  must be specified,   like Ubuntu 18.04 - amd64.

Valid examples are    802.11p-examples-06.19.tar.gz
No issues with Segmentation fault  but these
ns  aomdv-Na__I2Ep-Lcode.tcl     Segmentation fault
ns n-802.11p-vanet.tcl        Segmentation fault, paris.tr = 50.8 MB
1.  Segmentation fault can be ignored when the trace files have an OK file size.
2.  ns2 is old. Not all simulations will work any more with a "year 2023 OS":  Use an old OS.
     .... Besides that, it's easy to make an example that doesn't work with any OS.

-

knudfl

unread,
Feb 29, 2024, 6:11:48 PM2/29/24
to Network Simulator 2 (NS2)
Examples 802.11p , in ex-vanet-08.22/
AODV :   100A-urban-VANET.tcl
         A-urban-VANET-TeatinosM40.tcl
         A-xy2300-ebecm.tcl
         A-xy4700-ebecm.tcl
         A-xy700-ebecm.tcl
DSDV :   DSDV-urban-VANET-TeatinosM40.tcl
         n-802.11p-vanet.tcl
         unam11-802.11p.tcl
.... and then some OLSR, Dream, LTE, Tora, ZRP.

Vanet-ex-0822.tar.xz
https://drive.google.com/file/d/1EWcvdSdUzqAti1e-S-iVyd1ZFa2HYwAJ/view?usp=drive_link

belhadj aissa

unread,
Mar 1, 2024, 8:36:11 AM3/1/24
to ns-u...@googlegroups.com
thank you sir for your response. my system version is  Ubuntu 18.04 - amd64 with ns2

--
You received this message because you are subscribed to the Google Groups "Network Simulator 2 (NS2)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-users+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ns-users/fe118798-d35b-4a00-bc70-f238accf0d33n%40googlegroups.com.

belhadj aissa

unread,
Mar 1, 2024, 9:23:44 AM3/1/24
to ns-u...@googlegroups.com
this  is a screenshot of my command and its result. also the nam do not appear when the segmentation fault occurs

Le jeu. 29 févr. 2024 à 10:22, knudfl <tx.li...@gmail.com> a écrit :
--
Capture d’écran de 2024-03-01 15-57-19.jpg

knudfl

unread,
Mar 1, 2024, 10:49:58 AM3/1/24
to Network Simulator 2 (NS2)
The file  3-nodePositions is missing in the package ex-802.11p-06.19/.

$ ns235-orig B-simple-wireless-Bilgin.tcl
num_nodes is set 102
INITIALIZE THE LIST xListHead
Loading initial node positions file...
Load complete...
Loading scenario file...
Load complete...
Starting Simulation...
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 17976931348623157081452742373170435679807056752584499659891747680315726078002853876058955863276687817
15404589535143824642343213268894641827684675467035375169860499105765512820762454900903893289440758685084551339423045832369032229481658085
59332123348274797826204144723168738177180919299881250404026184124858368.0
SORTING LISTS ...DONE!
------------------------------------ i.e. no issues,  Ubuntu 18.04 - amd64
Files created:  simple_out.nam 58.9 kB, simple_trace.tr 221.6 kB

About these "simple wireless" ex ,  A-simple-wireless-Bilgin.tcl B-simple-wireless-Bilgin.tcl:
→ No real animation / no traffic in nam. The original @Bilgin file : There was no nam file !

belhadj aissa

unread,
Mar 2, 2024, 6:16:50 AM3/2/24
to ns-u...@googlegroups.com
i have got the same  problem with the 04.22 package

.trashed-1711966466-IMG20240302111414[1].jpg

knudfl

unread,
Mar 2, 2024, 7:54:22 AM3/2/24
to Network Simulator 2 (NS2)
"You should avoid posting pictures of text. Pictures can be hard to read. Text is easier to read in different screen formats, can be copied and pasted, as well as is search engine addressable, making it easier for people to reach this post who may have a similar issue"
* Your image is not readable .... I guess you know how to copy-paste a text.

The Ubuntu 18.04.4 that I'm using for test has libc6-2.27-3ubuntu1.6 : No issues.
Segmentation fault may happen if you updated to a later  libc6 version.

If it's still about "B-simple-wireless-Bilgin.tcl",
and if you are still working with Vanet :
I guess a wireless simulation may not be relevant. Vanet → mobile nodes.

Please specify your requirements (Vanet ? examples .. 802.11p ?)
-

knudfl

unread,
Mar 2, 2024, 9:04:15 AM3/2/24
to Network Simulator 2 (NS2)
?? Looks like you are trying to use my command example ns235-orig ?
..... It's just an indication that I am using a ns-2.35 with no modifications.
I.e. a stock  ns-allinone-2.35_gcc5.tar.gz

And there can only be one file by name 'ns', so when I have 350 different "ns"
..... they all must have different file names.
You must of course use a command that's present on your OS, e.g. ns
-

belhadj aissa

unread,
Mar 2, 2024, 9:30:41 AM3/2/24
to ns-u...@googlegroups.com
i am so sorry sir the problem is the next:
belhadj@belhadj-HP-Laptop-14s-fq0xxx:~/ns-allinone-2.35/aaa/802.11p-ex__04.22/ex-802.11p__04.22$ ns B-simple-wireless-Bilgin.tcl

num_nodes is set 102
INITIALIZE THE LIST xListHead
Loading initial node positions file...
Load complete...
Loading scenario file...
Load complete...
Starting Simulation...
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
Erreur de segmentation (core dumped)

You received this message because you are subscribed to a topic in the Google Groups "Network Simulator 2 (NS2)" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ns-users/OFWe-wMVVKI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ns-users+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ns-users/5faa6a5f-3a7e-4110-851c-05f7cc8103c1n%40googlegroups.com.

belhadj aissa

unread,
Mar 2, 2024, 9:39:27 AM3/2/24
to ns-u...@googlegroups.com
also my requierement is in VANET with 802.11p protocol.

knudfl

unread,
Mar 2, 2024, 2:21:03 PM3/2/24
to Network Simulator 2 (NS2)
Please do not use examples that don't work for you. 
And still: B-simple-wireless-Bilgin.tcl is not "vanet" I think.
I cannot see why your Ubuntu "ns" works different from the executable´s that I am using.
libc6 2.27-3ubuntu1.6 is the latest.
Are you using Ubuntu inside a Windows OS? Or in a virtual machine, VirtualBox or wmWare?
-----
New are e.g.
00D-1H-guindy-teatinos40A.tcl    2 static (=rsu?)
8p47-vanet-rsu-19.tcl        rsu
I-nn30-P-802.11p-Soumia.tcl  (Energy model)
I-P-802.11p-Soumia.tcl     (Energy model)
-

belhadj aissa

unread,
Mar 2, 2024, 3:47:10 PM3/2/24
to ns-u...@googlegroups.com
i use ubuntu separatly do not in VM, i know it is not a VANET example but the problem is happened only when i use the 802.11p with the 802.11 it works without any issues

knudfl

unread,
Mar 2, 2024, 4:49:08 PM3/2/24
to Network Simulator 2 (NS2)
As said   "I cannot see why your Ubuntu "ns" works different from the executable´s that I am using."
Runs OK here: The 'ns' installed with the Ubuntu ns2 package. Or one created here. No issues.
? May be another Ubuntu update causes the different ns2 behavior. ?
.....  Is "B-simple-wireless-Bilgin.tcl" the only example with "Segmentation fault" ?

Please note that you cannot run any random example with Mac802.11p / "Phy/WirelessPhyExt" / "Mac/802_11Ext".
A few Vanet ex could be modified to 802.11p . And one "Energy model" ex. And may be one cluster ex :
As shown in the package  Vanet-802.11p-ex.tar.xz
-
Hint :   Various 802.11p configuration files :
IEEE802-11p-2008-10-29.tcl, IEEE802-11p.tcl
802.11p-2.tcl, 802.11p-4.tcl

The setting "Propagation" can be Nakagami or TwoRayGround.  (Or Shadowing)
Some simulations can use either.

-

belhadj aissa

unread,
Mar 2, 2024, 5:29:00 PM3/2/24
to ns-u...@googlegroups.com
no the problem occurs with all examples that uses Mac802.11p / "Phy/WirelessPhyExt" / "Mac/802_11Ext"

knudfl

unread,
Mar 3, 2024, 9:44:16 AM3/3/24
to Network Simulator 2 (NS2)
Have you tried this
$ sudo apt install ns2           ## to get a clean ns2 → ns-2.35
..... provides /usr/bin/ns
------- Simulation ---------
$ /usr/bin/ns I-P-802.11p-Soumia.tcl
-

belhadj aissa

unread,
Mar 3, 2024, 6:05:30 PM3/3/24
to ns-u...@googlegroups.com
this what is appear
Belhadj@belhadj-HP-Laptop-14s-fq0xxx:~/ns-allinone-2.35/Vanet-802.11p-ex$ /usr/bin/ns 8p47-vanet-rsu-19.tcl
 When configured, ns found the right version of tclsh in /usr/bin/tclsh8.6
but it doesn't seem to be there anymore, so ns will fall back on running the first tclsh in your path. The wrong version of tclsh may break the test suites. Reconfigure and rebuild ns if this is a problem.
num_nodes is set 47
num_nodes is set 47
num_nodes is set 47
INITIALIZE THE LIST xListHead
Number of RSU: 2?
Number of vehicles: 45
Simulation time 100.0
CBR Data rate: 10000kbps
Starting Simulation...
SORTING LISTS ...DONE!

channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 2180.6

knudfl

unread,
Mar 4, 2024, 5:29:41 AM3/4/24
to Network Simulator 2 (NS2)
" When configured, ns found the right version of tclsh in /usr/bin/tclsh8.6
but it doesn't seem to be there anymore, so ns will fall back on running the first tclsh in your path "
....... You probably have an Ubuntu update (install) later than the "ns2 libtcl8.x version".
I.e. Ubuntu ns2 and nam packages have low priority. No updates. Never.
Thus the   libtcl8.x version can be later than the "ns2 libtcl8.x build version".

» $ /usr/bin/ns 8p47-vanet-rsu-19.tcl
num_nodes is set 47
num_nodes is set 47
num_nodes is set 47
INITIALIZE THE LIST xListHead
Number of RSU: 2?
Number of vehicles: 45
Simulation time 100.0
CBR Data rate: 10000kbps
Starting Simulation...
SORTING LISTS ...DONE!
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 2180.6  «
...... Probably OK ..... when the trace file have the right size :
rsu19.nam is about 142MB, 19RSU.tr ~90MB

Then you can run NAM: $ nam rsu19.nam &
-

knudfl

unread,
Mar 4, 2024, 2:25:42 PM3/4/24
to Network Simulator 2 (NS2)
How to build a new perfect ns-2.35 :
The "build prerequisites" for ns2 must be installed :
sudo apt install g++ g++-4.8 autoconf libtool libxmu-dev

Unpack a new ns-allinone into a new folder in /home/name/ns2/
tar xvf ns-allinone-2.35_gcc5.tar.gz                   ## 2014 - 2017 update
cd ns-allinone-2.35/
export CC=gcc-4.8 CXX=g++-4.8 && ./install
cd ns-2.35/
sudo make install       ## will copy the executable ns to /usr/local/bin/
cp ns ns-orig      ## this is your backup of the stock ns / the unmodified executable
sudo cp ns-orig /usr/local/bin/
.......... so simulations can be run with  ns-orig file.tcl

-
Reply all
Reply to author
Forward
0 new messages