Skip to content
Snippets Groups Projects
Commit 7a8d9c15 authored by Rohan's avatar Rohan
Browse files

multiple gnbsim instance added

parent e078f0fb
No related branches found
No related tags found
1 merge request!6Gnbsim
...@@ -22,7 +22,7 @@ if [[ $1 == 'start' ]]; then ...@@ -22,7 +22,7 @@ if [[ $1 == 'start' ]]; then
docker-compose -f docker-compose.yaml -p 5gcn up -d docker-compose -f docker-compose.yaml -p 5gcn up -d
elif [[ $2 == 'gnbsim' ]]; then elif [[ $2 == 'gnbsim' ]]; then
echo -e "${BLUE}Starting 5gcn components in the order nrf, mysql, amf, smf, spgwu${NC}..." echo -e "${BLUE}Starting 5gcn components in the order nrf, mysql, amf, smf, spgwu${NC}..."
docker-compose -f docker-compose-gnbsim.yaml -p gnbsim up -d docker-compose -f docker-compose-gnbsim.yaml up -d gnbsim$3
else else
echo -e "${BLUE}Starting 5gcn components in the order mysql, amf, smf, spgwu${NC}..." echo -e "${BLUE}Starting 5gcn components in the order mysql, amf, smf, spgwu${NC}..."
docker-compose -f docker-compose-no-nrf.yaml -p 5gcn up -d docker-compose -f docker-compose-no-nrf.yaml -p 5gcn up -d
...@@ -90,7 +90,9 @@ elif [[ $1 == 'stop' ]]; then ...@@ -90,7 +90,9 @@ elif [[ $1 == 'stop' ]]; then
echo -e "${BLUE}Stopping the core network${NC}..." echo -e "${BLUE}Stopping the core network${NC}..."
if [[ $2 == 'nrf' ]]; then if [[ $2 == 'nrf' ]]; then
docker-compose -f docker-compose.yaml -p 5gcn down docker-compose -f docker-compose.yaml -p 5gcn down
else elif [[ $2 == 'gnbsim' ]]; then
docker-compose -f docker-compose-gnbsim.yaml down
else
docker-compose -f docker-compose-no-nrf.yaml -p 5gcn down docker-compose -f docker-compose-no-nrf.yaml -p 5gcn down
fi fi
echo -e "${GREEN}Core network stopped${NC}" echo -e "${GREEN}Core network stopped${NC}"
......
...@@ -23,7 +23,7 @@ services: ...@@ -23,7 +23,7 @@ services:
- URL=http://www.asnt.org:8080/ - URL=http://www.asnt.org:8080/
- NRCellID=1 - NRCellID=1
- NGAPPeerAddr=192.168.70.132 - NGAPPeerAddr=192.168.70.132
- GTPuLocalAddr=192.168.70.136 # spgwu-tiny-upf - GTPuLocalAddr=192.168.70.136
- GTPuIFname=eth0 - GTPuIFname=eth0
networks: networks:
public_net: public_net:
...@@ -33,6 +33,143 @@ services: ...@@ -33,6 +33,143 @@ services:
interval: 10s interval: 10s
timeout: 5s timeout: 5s
retries: 5 retries: 5
gnbsim2:
container_name: gnbsim2
image: gnbsim:develop
privileged: true
environment:
- MCC=208
- MNC=95
- GNBID=2
- TAC=0x00a000
- SST=222
- SD=00007b
- PagingDRX=v32
- RANUENGAPID=0
- IMEISV=35609204079514
- MSIN=0000000032
- RoutingIndicator=1234
- ProtectionScheme=null
- KEY=0C0A34601D4F07677303652C0462535B
- OPc=63bfa50ee6523365ff14c1f45f88737d
- DNN=default
- URL=http://www.asnt.org:8080/
- NRCellID=1
- NGAPPeerAddr=192.168.70.132
- GTPuLocalAddr=192.168.70.137
- GTPuIFname=eth0
networks:
public_net:
ipv4_address: 192.168.70.137
healthcheck:
test: /bin/bash -c "ifconfig gtp-gnb"
interval: 10s
timeout: 5s
retries: 5
gnbsim3:
container_name: gnbsim3
image: gnbsim:develop
privileged: true
environment:
- MCC=208
- MNC=95
- GNBID=3
- TAC=0x00a000
- SST=222
- SD=00007b
- PagingDRX=v32
- RANUENGAPID=0
- IMEISV=35609204079514
- MSIN=0000000033
- RoutingIndicator=1234
- ProtectionScheme=null
- KEY=0C0A34601D4F07677303652C0462535B
- OPc=63bfa50ee6523365ff14c1f45f88737d
- DNN=default
- URL=http://www.asnt.org:8080/
- NRCellID=1
- NGAPPeerAddr=192.168.70.132
- GTPuLocalAddr=192.168.70.138
- GTPuIFname=eth0
networks:
public_net:
ipv4_address: 192.168.70.138
healthcheck:
test: /bin/bash -c "ifconfig gtp-gnb"
interval: 10s
timeout: 5s
retries: 5
gnbsim4:
container_name: gnbsim4
image: gnbsim:develop
privileged: true
environment:
- MCC=208
- MNC=95
- GNBID=4
- TAC=0x00a000
- SST=222
- SD=00007b
- PagingDRX=v32
- RANUENGAPID=0
- IMEISV=35609204079514
- MSIN=0000000034
- RoutingIndicator=1234
- ProtectionScheme=null
- KEY=0C0A34601D4F07677303652C0462535B
- OPc=63bfa50ee6523365ff14c1f45f88737d
- DNN=default
- URL=http://www.asnt.org:8080/
- NRCellID=1
- NGAPPeerAddr=192.168.70.132
- GTPuLocalAddr=192.168.70.139
- GTPuIFname=eth0
networks:
public_net:
ipv4_address: 192.168.70.139
healthcheck:
test: /bin/bash -c "ifconfig gtp-gnb"
interval: 10s
timeout: 5s
retries: 5
gnbsim5:
container_name: gnbsim5
image: gnbsim:develop
privileged: true
environment:
- MCC=208
- MNC=95
- GNBID=5
- TAC=0x00a000
- SST=222
- SD=00007b
- PagingDRX=v32
- RANUENGAPID=0
- IMEISV=35609204079514
- MSIN=0000000035
- RoutingIndicator=1234
- ProtectionScheme=null
- KEY=0C0A34601D4F07677303652C0462535B
- OPc=63bfa50ee6523365ff14c1f45f88737d
- DNN=default
- URL=http://www.asnt.org:8080/
- NRCellID=1
- NGAPPeerAddr=192.168.70.132
- GTPuLocalAddr=192.168.70.140
- GTPuIFname=eth0
networks:
public_net:
ipv4_address: 192.168.70.140
healthcheck:
test: /bin/bash -c "ifconfig gtp-gnb"
interval: 10s
timeout: 5s
retries: 5
networks: networks:
public_net: public_net:
external: external:
...@@ -45,4 +182,4 @@ networks: ...@@ -45,4 +182,4 @@ networks:
# config: # config:
# - subnet: 192.168.70.128/26 # - subnet: 192.168.70.128/26
# driver_opts: # driver_opts:
# com.docker.network.bridge.name: "demo-oai" # com.docker.network.bridge.name: "demo-oai"
\ No newline at end of file
This diff is collapsed.
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
6. [Configuring gnbsim Scenario](#6-configuring-gnbsim-scenario) 6. [Configuring gnbsim Scenario](#6-configuring-gnbsim-scenario)
7. [Executing gnbsim Scenario](#7-executing-the-gnbsim-scenario) 7. [Executing gnbsim Scenario](#7-executing-the-gnbsim-scenario)
8. [Analysing Scenario Results](#8-analysing-the-scenario-results) 8. [Analysing Scenario Results](#8-analysing-the-scenario-results)
9. [Trying some advanced stuff](#9-trying-some-advanced-stuff)
* In this demo the image tags and commits which were used are listed below, follow the [Building images](./BUILD_IMAGES.md) to build images with below tags. * In this demo the image tags and commits which were used are listed below, follow the [Building images](./BUILD_IMAGES.md) to build images with below tags.
...@@ -174,3 +175,91 @@ iperf Done. ...@@ -174,3 +175,91 @@ iperf Done.
| [spgwu.log](./results/logs/spgwu.log) | [spgwu.log](./results/logs/spgwu.log)
* For detailed analysis of messages, please refer previous tutorial of [testing with dsTester](./docs/DEPLOY_SA5G_WITH_DS_TESTER.md). * For detailed analysis of messages, please refer previous tutorial of [testing with dsTester](./docs/DEPLOY_SA5G_WITH_DS_TESTER.md).
## 8. Trying Some Advanced Stuff ##
Here we try some scaling test with gnbsim. There are additional IMSIs are added into database (208950000000031-208950000000040). Now we create few more gnbsim instances (4 more for now). We use same script to generate additional instance as follow -
```bash
oai-cn5g-fed/docker-compose$ ./core-network.sh start gnbsim 2
Creating gnbsim2 ... done
```
So here basically, minimum configuration parameters that need to change is gnbid, imsi and container ip address in docker-compose-gnbsim.yaml.
Please make sure status of instance is healthy before creating one more instance. Now here we have deployed all 5 gnbsim intances -
```bash
$ docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
a25174c51297 gnbsim:develop "/gnbsim/bin/entrypo…" 3 minutes ago Up 3 minutes (healthy) gnbsim5
00c6207b0064 gnbsim:develop "/gnbsim/bin/entrypo…" 4 minutes ago Up 4 minutes (healthy) gnbsim4
ed440f95fb19 gnbsim:develop "/gnbsim/bin/entrypo…" 4 minutes ago Up 4 minutes (healthy) gnbsim3
8c4e4098955d gnbsim:develop "/gnbsim/bin/entrypo…" 14 minutes ago Up 14 minutes (healthy) gnbsim2
895b1838c62a gnbsim:develop "/gnbsim/bin/entrypo…" 15 minutes ago Up 15 minutes (healthy) gnbsim
d48135fd045c ubuntu:bionic "/bin/bash -c ' apt …" 16 minutes ago Up 16 minutes oai-ext-dn
5e98a708d12b oai-amf:develop "/bin/bash /openair-…" 16 minutes ago Up 16 minutes (healthy) 80/tcp, 9090/tcp, 38412/sctp oai-amf
c64ae3c7f7c6 oai-spgwu-tiny:gtp-ext-header "/openair-spgwu-tiny…" 16 minutes ago Up 16 minutes (healthy) 2152/udp, 8805/udp oai-spgwu
1cd8319bddb0 oai-smf:develop "/bin/bash /openair-…" 16 minutes ago Up 16 minutes (healthy) 80/tcp, 9090/tcp, 8805/udp oai-smf
9cda92a46be4 mysql:5.7 "docker-entrypoint.s…" 16 minutes ago Up 16 minutes (healthy) 3306/tcp, 33060/tcp mysql
cc407925adf2 oai-nrf:develop "/bin/bash /openair-…" 16 minutes ago Up 16 minutes (healthy) 80/tcp, 9090/tcp oai-nrf
```
* Let's verify all gnb and ue are registered at our 5G core -
```bash
$ docker logs oai-amf
truncated output
[2021-05-17T12:17:28.539943] [AMF] [amf_app] [info ]
[2021-05-17T12:17:28.539998] [AMF] [amf_app] [info ] |----------------------------------------------------------------------------------------------------------------|
[2021-05-17T12:17:28.540009] [AMF] [amf_app] [info ] |----------------------------------------------------gNBs' information-------------------------------------------|
[2021-05-17T12:17:28.540031] [AMF] [amf_app] [info ] | Index | Status | Global ID | gNB Name | PLMN |
[2021-05-17T12:17:28.540046] [AMF] [amf_app] [info ] | 1 | Connected | 0x400 | | 208, 95 |
[2021-05-17T12:17:28.540056] [AMF] [amf_app] [info ] | 2 | Connected | 0x800 | | 208, 95 |
[2021-05-17T12:17:28.540065] [AMF] [amf_app] [info ] | 3 | Connected | 0xc00 | | 208, 95 |
[2021-05-17T12:17:28.540077] [AMF] [amf_app] [info ] | 4 | Connected | 0x1000 | | 208, 95 |
[2021-05-17T12:17:28.540086] [AMF] [amf_app] [info ] | 5 | Connected | 0x1400 | | 208, 95 |
[2021-05-17T12:17:28.540094] [AMF] [amf_app] [info ] |----------------------------------------------------------------------------------------------------------------|
[2021-05-17T12:17:28.540102] [AMF] [amf_app] [info ]
[2021-05-17T12:17:28.540108] [AMF] [amf_app] [info ] |----------------------------------------------------------------------------------------------------------------|
[2021-05-17T12:17:28.540118] [AMF] [amf_app] [info ] |----------------------------------------------------UEs' information--------------------------------------------|
[2021-05-17T12:17:28.540131] [AMF] [amf_app] [info ] | Index | 5GMM state | IMSI | GUTI | RAN UE NGAP ID | AMF UE ID | PLMN |Cell ID|
[2021-05-17T12:17:28.540146] [AMF] [amf_app] [info ] | 1| 5GMM-REGISTERED| 208950000000031| | 0| 1| 208, 95 | 262160|
[2021-05-17T12:17:28.540169] [AMF] [amf_app] [info ] | 2| 5GMM-REGISTERED| 208950000000032| | 0| 2| 208, 95 | 524304|
[2021-05-17T12:17:28.540185] [AMF] [amf_app] [info ] | 3| 5GMM-REGISTERED| 208950000000033| | 0| 3| 208, 95 | 786448|
[2021-05-17T12:17:28.540197] [AMF] [amf_app] [info ] | 4| 5GMM-REGISTERED| 208950000000034| | 0| 4| 208, 95 |1048592|
[2021-05-17T12:17:28.540211] [AMF] [amf_app] [info ] | 5| 5GMM-REGISTERED| 208950000000035| | 0| 5| 208, 95 |1310736|
[2021-05-17T12:17:28.540219] [AMF] [amf_app] [info ] |----------------------------------------------------------------------------------------------------------------|
[2021-05-17T12:17:28.540227] [AMF] [amf_app] [info ]
```
* Finally lets ping UE from external DN node -
```bash
$ docker exec -it oai-ext-dn ping -c 2 12.1.1.2
PING 12.1.1.2 (12.1.1.2) 56(84) bytes of data.
64 bytes from 12.1.1.2: icmp_seq=1 ttl=64 time=0.416 ms
64 bytes from 12.1.1.2: icmp_seq=2 ttl=64 time=0.763 ms
--- 12.1.1.2 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1008ms
rtt min/avg/max/mdev = 0.416/0.589/0.763/0.175 ms
$ docker exec -it oai-ext-dn ping -c 2 12.1.1.3
PING 12.1.1.3 (12.1.1.3) 56(84) bytes of data.
64 bytes from 12.1.1.3: icmp_seq=1 ttl=64 time=0.328 ms
64 bytes from 12.1.1.3: icmp_seq=2 ttl=64 time=0.620 ms
--- 12.1.1.3 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1005ms
rtt min/avg/max/mdev = 0.328/0.474/0.620/0.146 ms
$ docker exec -it oai-ext-dn ping -c 2 12.1.1.4
PING 12.1.1.4 (12.1.1.4) 56(84) bytes of data.
64 bytes from 12.1.1.4: icmp_seq=1 ttl=64 time=0.408 ms
64 bytes from 12.1.1.4: icmp_seq=2 ttl=64 time=0.694 ms
--- 12.1.1.4 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1032ms
rtt min/avg/max/mdev = 0.408/0.551/0.694/0.143 ms
$ docker exec -it oai-ext-dn ping -c 2 12.1.1.5
PING 12.1.1.5 (12.1.1.5) 56(84) bytes of data.
64 bytes from 12.1.1.5: icmp_seq=1 ttl=64 time=0.289 ms
64 bytes from 12.1.1.5: icmp_seq=2 ttl=64 time=0.233 ms
--- 12.1.1.5 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1004ms
rtt min/avg/max/mdev = 0.233/0.261/0.289/0.028 ms
```
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment