From 7f03eca063959b39cdc5e657cfa64e2bcc3d681c Mon Sep 17 00:00:00 2001 From: Carlos Antonio De Lima Filho <carlos.lima.106@ufrn.edu.br> Date: Tue, 12 Nov 2024 23:07:24 +0000 Subject: [PATCH] Update README.md --- .../README.md | 110 +++++++++++++++++- 1 file changed, 104 insertions(+), 6 deletions(-) diff --git a/openairinterface5g/openairinterface-install-scripts/README.md b/openairinterface5g/openairinterface-install-scripts/README.md index 3564a953..0bac9681 100644 --- a/openairinterface5g/openairinterface-install-scripts/README.md +++ b/openairinterface5g/openairinterface-install-scripts/README.md @@ -188,9 +188,93 @@ To install OAI FlexRIC, go back to /home/$your user$ and follow this tutorial. > > sudo make install +## UE 1 Configurations + +**Step 1:** Creating a namespace: + +sudo ip netns add oai-2 + +**Step 2:** Creating a pair of virtual interfaces (veth): + +sudo ip link add veth0 type veth peer name veth1 + +**Step 3:** Moving one interface to the created namespace: + +sudo ip link set veth1 netns oai-2 + +**Step 4:** Configuring an IP address for veth0 interface: + +sudo ip addr add 192.168.1.1/24 dev veth0 + +**Step 5:** Configuring an IP address for veth1 interface within the namespace: + +sudo ip netns exec oai-2 ip addr add 192.168.1.2/24 dev veth1 + +**Step 6:** Bringing up the veth0 interface: + +sudo ip link set veth0 up + +**Step 7:** Bringing up the veth1 interface within the namespace: + +sudo ip netns exec oai-2 ip link set veth1 up + +**Step 8:** Adding a route within the namespace: + +sudo ip netns exec oai-2 ip route add 192.168.70.128/26 via 192.168.1.1 dev veth1 + +**Step 9:** Enabling packet forwarding within the namespace: + +sudo ip netns exec oai-2 sysctl net.ipv4.conf.all.forwarding=1 + +**Step 10:** Setting default policy for packet forwarding within the namespace to ACCEPT:: + +sudo ip netns exec oai-2 iptables -P FORWARD ACCEPT + +## UE 2 Configurations + +**Step 1:** Creating a namespace: + +sudo ip netns add oai-2 + +**Step 2:** Creating a pair of virtual interfaces (veth): + +sudo ip link add veth0 type veth peer name veth1 + +**Step 3:** Moving one interface to the created namespace: + +sudo ip link set veth1 netns oai-2 + +**Step 4:** Configuring an IP address for veth0 interface: + +sudo ip addr add 192.168.1.1/24 dev veth0 + +**Step 5:** Configuring an IP address for veth1 interface within the namespace: + +sudo ip netns exec oai-2 ip addr add 192.168.1.2/24 dev veth1 + +**Step 6:** Bringing up the veth0 interface: + +sudo ip link set veth0 up + +**Step 7:** Bringing up the veth1 interface within the namespace: + +sudo ip netns exec oai-2 ip link set veth1 up + +**Step 8:** Adding a route within the namespace: + +sudo ip netns exec oai-2 ip route add 192.168.70.128/26 via 192.168.1.1 dev veth1 + +**Step 9:** Enabling packet forwarding within the namespace: + +sudo ip netns exec oai-2 sysctl net.ipv4.conf.all.forwarding=1 + +**Step 10:** Setting default policy for packet forwarding within the namespace to ACCEPT:: + +sudo ip netns exec oai-2 iptables -P FORWARD ACCEPT + ## Deployment -For this task, open another terminal using crtl+Alt+T. +Use a separate terminal for each of the following steps. **Step 1:** Core deployment? @@ -219,7 +303,7 @@ After running the above command the expect result is shown in figure below. **Attention:** You must have Core 5G up and running -**Step 3.1:** open a new terminal using ctrl+Alt+T and type: +**Step 3.1:** gNB deploy: > sudo su > @@ -227,12 +311,26 @@ After running the above command the expect result is shown in figure below. > > sudo RFSIMULATOR=server ./nr-softmodem --rfsim --sa -O ../../../targets/PROJECTS/GENERIC-NR-5GC/CONF/gnb.sa.band78.fr1.106PRB.usrpb210.conf --gNBs.[0].min_rxtxtime 6 --continuous-tx - - -**Step 3.2**: To check the connection of gNodeB to the Core, see AMF logs. Open another terminal (the third one) using ctrl+Alt+T and type: +**Step 3.2**: To check the connection of gNodeB to the Core, see AMF logs. Open a terminal and use the command below: > docker logs -f oai-amf The expected return is shown in figure below, where gNodeB shows the connected status. - \ No newline at end of file + + +**Step 4:** UE 1 deployment: + +> sudo ip netns exec oai-ue1 bash +> +> cd /home/$your user$/openairinterface5g/cmake_targets/ran_build/build/ +> +> sudo RFSIMULATOR=192.168.1.2 ./nr-uesoftmodem -r 106 --numerology 1 --band 78 -C 3619200000 --rfsim --sa --nokrnmod -O ../../../targets/PROJECTS/GENERIC-NR-5GC/CONF/ue.conf + +**Step 4:** UE 2 deployment: + +> sudo ip netns exec oai-ue2 bash +> +> cd /home/$your user$/openairinterface5g/cmake_targets/ran_build/build/ +> +> sudo RFSIMULATOR=192.168.1.2 ./nr-uesoftmodem -r 106 --numerology 1 --band 78 -C 3619200000 --rfsim --sa --nokrnmod -O ../../../targets/PROJECTS/GENERIC-NR-5GC/CONF/ue2.conf -- GitLab