Ns-CBRP patch for ns2.35

109 views
Skip to first unread message

Sadik Manik

unread,
Apr 16, 2024, 4:07:08 AM4/16/24
to Network Simulator 2 (NS2)
Hi, I am looking for a CBRP patch that can be used for ns2.35. If it could be helpful, I would greatly appreciate it.

knudfl

unread,
Apr 16, 2024, 6:05:40 AM4/16/24
to Network Simulator 2 (NS2)
Hi.
Seems the patches I created from the CBRP code year 2017 also include the LTE patch :


...... The old CBRP code can be compiled with g++34, from gcc version 3.4.6 . ......
for building with ns-2.35.

Year 2024 edits ..... of the above answer
Download, and install :
sudo apt install Downloads/compat-gcc34-3.4.6-ubuntu1204-1_amd64.deb
sudo apt install Downloads/compat-gcc-34-c++_3.4.6-20_amd64.deb

tar xvf ns-allinone-2.35_gcc5.tar.gz         // 2014 update
https://drive.google.com/file/d/0B7S255p3kFXNVVlxR0ZNRGVORjQ/view?usp=sharing&resourcekey=0-EyPhoScBFDb7ul0VFk6FZQ
cd ns-allinone-2.35/
patch -p0 < CBRP+LTE_ns235.patch
https://drive.google.com/file/d/0B7S255p3kFXNMlJBRy10SlYwWk0/view?usp=sharing
export CC=gcc-4.8 CXX=g++-4.8 && ./install
                       // Stops with error in ns-2.35/cbrp/*
cd ns-2.35/    
                       // Edit the Makefile line 37 to CPP    = g++34
make
                       // Stops with errors. Edit the Makefile to g++-4.8
make
cp ns ns235-cbrp-lte
sudo cp ns235-cbrp-lte /usr/local/bin/
Simulation :  $ ns235-cbrp-lte ex.tcl

Sadik Manik

unread,
Apr 17, 2024, 9:05:53 AM4/17/24
to Network Simulator 2 (NS2)
Hello, thank you so much for your answer!But after following your process, I did not generate an executable file for ns2

Sadik Manik

unread,
Apr 17, 2024, 10:29:02 AM4/17/24
to Network Simulator 2 (NS2)
I successfully generated ns235-cbrp-lte!
But when I ran the ex cbrp program, it displayed
...
reating node 38
Creating node 39
Starting Simulation...
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 550.0
SORTING LISTS ...DONE!
logic error at recv, event sendUP
logic error at recv, event sendUP
...
corrupted size vs. prev_size
已放弃 (核心已转储)

knudfl

unread,
Apr 17, 2024, 12:10:43 PM4/17/24
to Network Simulator 2 (NS2)
My test .............
$ ns235-CBRP-lte-64 40CBRP-802_11p-vanet.tcl : Segmentation fault  ..... and "logic error at recv, event sendUP"
$ ns233-cbrp-64 40CBRP-802_11p-vanet.tcl : OK
$ ns233-cbrp-64 C-CBRP-kartiksd.tcl: OK
$ ns233-cbrp-64 C-Network-Topology-Test-1.tcl : OK
$ ns235-CBRP-lte-64 C-Network-Topology-Test-1.tcl : OK
$ ns233-cbrp-64 cb-derekman-1.tcl : OK
$ ns235-CBRP-lte-64 cb-derekman-1.tcl : OK
$ ns235-CBRP-lte-64 CBRP-3t-urban-Clustering-moc_v1.tcl OK
$ ns235-CBRP-lte-64 CBRP-kartiksd.tcl : OK
......... So please avoid the unusable example,  40CBRP-802_11p-vanet.tcl . 
May work OK with a year 2016 OS. Anyway it works OK with the year 2017 executable 'ns233-cbrp' !

If any issues / questions :  
Please show the actual command. And the OS must be specified. Example Ubuntu 18.04 - amd64.
I.e. if no required information is shown, you cannot expect an answer.

-

Sadik Manik

unread,
Apr 18, 2024, 1:34:20 AM4/18/24
to Network Simulator 2 (NS2)
Thank you very much !!

ihab jabor

unread,
May 23, 2024, 12:33:55 PM5/23/24
to Network Simulator 2 (NS2)
Dear Knudfl, 
Can I contact you about this issue? 
Your help will be highly appreciated. 
regards 

knudfl

unread,
May 23, 2024, 1:45:17 PM5/23/24
to Network Simulator 2 (NS2)
engi....  :  You haven't described any issues yet ...

General issues are discussed here https://groups.google.com/g/ns-users/c/e36ykHyzXNM
→  My answer  Jun 4, 2018

ihab jabor

unread,
May 23, 2024, 2:53:11 PM5/23/24
to Network Simulator 2 (NS2)
Dear Knudfl, 
Thank you for your response. I've run some LTE from the file (lte-ex_08.22); however, I've not installed any patch of LTE. Do VirtualBox_ns2_23_05_2024_21_48_53.png I need to install any? 
I have run other LTE codes but could not execute any of them; I'm looking for a 4G or 5G network for performance analysis.
that's why I will be grateful for your help as well as contacting you.
Regards.

knudfl

unread,
May 23, 2024, 4:30:03 PM5/23/24
to Network Simulator 2 (NS2)
engi....

...... and there's a reason for that :   These ~100 protocols are not included in ns2.

_______________


export CC=gcc-4.8 CXX=g++-4.8 && ./install
cd ns-2.35/
cp ns ns235-LTE
sudo cp ns235-LTE /usr/local/bin/
--------- Simulation ----------
ns235-LTE deVacto-lte.tcl

ihab jabor

unread,
May 23, 2024, 4:37:36 PM5/23/24
to Network Simulator 2 (NS2)
gratitude for your replay, 
Kindly 
I'm looking for 4G/5G tcl files to execute it. 
Vehicles and IoT ( sensors) 
I've searched the tcl repository but couldn't find it.
Your help and response are appreciated.
Ihab

knudfl

unread,
May 23, 2024, 4:57:41 PM5/23/24
to Network Simulator 2 (NS2)
engi ...

Vehicles and IoT ( sensors) :   Is a new thing I guess.   ns2 no support since year 2015.
Suggest :  Search for a simulator which can do what you want.


-

ihab jabor

unread,
May 23, 2024, 5:03:59 PM5/23/24
to Network Simulator 2 (NS2)
Thank you for your feedback. 
Can vehicles and IoT be assigned through ns2 by sensor environment? If so, which patch I've to installed? which tcl files in the repository would you share please?

knudfl

unread,
May 24, 2024, 3:27:21 AM5/24/24
to Network Simulator 2 (NS2)
engi ....

I have no knowledge of any "vehicles and IoT .. assigned through ns2 by sensor environment".
Repeat : Please search for a simulator which can do what you want. ( ns2 no support since year 2015.)

There is no "repository of ns2 tcl simulations". 
There is the ~3000 simulations collected / saved over the last 15 years 

-

ihab jabor

unread,
May 24, 2024, 12:52:57 PM5/24/24
to Network Simulator 2 (NS2)
Thank you sir, 
actually, other simulations could not find a good hands-on tutorial for it.
Reply all
Reply to author
Forward
0 new messages