This article explains the way of installing 5G-Lena 3GPP-NR module on ns-3.36 under Debian OS. This is nothing but a learning log of 5G-Lena 3GPP-NR module installation on ns-3.36 .
5G New Radio(NR)
5G NR is a new radio access technology (RAT) developed by 3GPP for the 5G (fifth generation) mobile network. It was designed to be the global standard for the air interface of 5G networks[3].
5G NR uses frequency bands in two frequency ranges[3]:
- Frequency Range 1 (FR1), for bands within 410 MHz – 7125 MHz
- Frequency Range 2 (FR2), for bands within 24250 MHz – 52600 MHz
The non-standalone (NSA) mode of 5G NR refers to an option of 5G NR deployment that depends on the control plane of an existing 4G LTE network for control functions, while 5G NR is exclusively focused on the user plane.
5G-Lena 3GPP-NR module
5G-LENA is a GPLv2 New Radio (NR) network simulator, designed as a pluggable module to ns-3 by Mobile Networks group of a public research institute, CTTC (Centre Tecnològic de Telecomunicacions de Catalunya)[1]. The simulator is the natural evolution of LENA, the LTE/EPC Network Simulator, the development Inspired by mmWave module by NYU/UniPD] [2], and it incorporates fundamental PHY-MAC NR features aligned with NR Release 15[1]
The 5G-LENA code of [1] that I used in this installation is a version meant for installing 3GPP NR module in ns-3-dev and it is for the simulation 5G NR non-standalone cellular networks under ns-3 using 5G-LENA project.
The following architectural description from[4] describes all the building blocks from a remote host to a User Equipment of their Model.
One may learn more about the features of this module by reading the following links:
This installation procedure is “chroot jail” based one. So one should setup a “chroot Jail” before proceeding this installation. The following [5] article explains the way of setting up a “chroot jail”.
https://www.projectguideline.com/installing-ns3-35-in-debian-10-chroot-jail-under-debian-11-host-os-or-any-version-of-linux-host/
Step 1: Installation of ns-3-dev
If ‘git’ is not installed on your system, first install it.
$ sudo apt install git
$ git clone https://gitlab.com/nsnam/ns-3-dev.git
At this step, you can switch to the compatible ns-3 release branch as follows:
Step 3: Configure ns-3
$ ./ns3 configure –enable-examples –enable-tests
Step 3: Compile the Default ns-3-dev
# For example, we may limit jobs as 4 by passing the argument -j4 to limit the CPU usage at the build/compile operation like:
# ./ns3 build -j4
Step 4: Installing NR module from GitLab
$ cd src
$ git clone https://gitlab.com/cttc-lena/nr.git
#now we should switch to the latest NR release branch.
# For example, to switch to the NR version 2.2 we should do the following
cd /home/your_home/ns-3-dev/src/nr
git checkout 5g-lena-v2.2.y
Step 5: Configure the ns-3 again to add the new Lena module
$ ./ns3 configure –enable-examples –enable-tests
Step 6: Build ns-3 to compile it with the new Lena module
$ ./ns3 build
You may correct this error as follows:
And build again:
$ ./ns3 build
Step 6: Testing the Lena nr installation with an Example Simulation
After the successful compilation of ns-3 with nr module, we may test its working by running an example simulation.
The comment section of the simulation example cttc-nr-demo.cc describes how to setup a simulation using the 3GPP channel model from TR 38.900. “This example consists of a simple grid topology, in which you can choose the number of gNbs and UEs. Have a look at the possible parameters to know what you can configure through the command line. With the default configuration, the example will create two flows that will go through two different subband numerologies (or bandwidth parts). For that, specifically, two bands are created, each with a single CC, and each CC containing one bandwidth part.”
$ ./ns3 run cttc-nr-demo
Conclusion
The 5G-LENA project is getting improved and updated often. So, one may need to use the correct ns-3 version and the correct 5G-Lena version to successfully compile it under ns-3. In our future article, we may present a more interesting simulation using this new module.