Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-UPF
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenXG
OpenXG-UPF
Commits
fd6ed460
Unverified
Commit
fd6ed460
authored
Jun 01, 2021
by
kharade
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
code clean
parent
3d358dd2
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
58 additions
and
1063 deletions
+58
-1063
docker/Dockerfile.ubuntu.18.04
docker/Dockerfile.ubuntu.18.04
+2
-2
docker/Dockerfile.vppupf.rhel7
docker/Dockerfile.vppupf.rhel7
+13
-13
docs/BUILD_IMAGE.md
docs/BUILD_IMAGE.md
+3
-3
docs/DEPLOY_HOME.md
docs/DEPLOY_HOME.md
+0
-1
docs/INSTALL_ON_HOST.md
docs/INSTALL_ON_HOST.md
+0
-9
docs/VPP_NETWORKING.md
docs/VPP_NETWORKING.md
+1
-0
docs/VPP_UPF_CONFIG.md
docs/VPP_UPF_CONFIG.md
+8
-6
scripts/entrypoint.sh
scripts/entrypoint.sh
+8
-11
scripts/patches/rpm_dep_force_install.patch
scripts/patches/rpm_dep_force_install.patch
+16
-0
scripts/tests/DStester_upf_multiple_ue.xml
scripts/tests/DStester_upf_multiple_ue.xml
+0
-235
scripts/tests/bench/DStester_upf_multiple_ue.xml
scripts/tests/bench/DStester_upf_multiple_ue.xml
+0
-235
scripts/tests/bench/docker-compose.yml
scripts/tests/bench/docker-compose.yml
+0
-250
scripts/tests/bench/mysql-healthcheck.sh
scripts/tests/bench/mysql-healthcheck.sh
+0
-46
scripts/tests/bench/oai_db.sql
scripts/tests/bench/oai_db.sql
+0
-207
scripts/tests/docker-compose.yml
scripts/tests/docker-compose.yml
+7
-45
No files found.
docker/Dockerfile.ubuntu.18.04
View file @
fd6ed460
...
...
@@ -37,7 +37,7 @@ RUN apt update && \
# Some GIT configuration commands quite useful
RUN /bin/bash -c "if [[ -v NEEDED_GIT_PROXY ]]; then git config --global http.proxy $NEEDED_GIT_PROXY; fi"
#
RUN /bin/bash -c "if [[ -v NEEDED_GIT_PROXY ]]; then git config --global http.proxy $NEEDED_GIT_PROXY; fi"
RUN git config --global https.postBuffer 123289600
RUN git config --global http.sslverify false
...
...
@@ -67,7 +67,7 @@ RUN make install-dep build-release -C vpp
#---------------------------------------------------------------------
# TARGET IMAGE
#---------------------------------------------------------------------
FROM ubuntu:bionic as vpp-up
f
FROM ubuntu:bionic as vpp-up
g
ENV DEBIAN_FRONTEND=noninteractive
ENV TZ=Europe/Paris
RUN apt-get update && \
...
...
docker/Dockerfile.vppupf.rhel7
View file @
fd6ed460
...
...
@@ -68,8 +68,8 @@ RUN wget http://repo.openfusion.net/centos7-x86_64/hyperscan-devel-5.3.0-1.of.el
http://repo.openfusion.net/centos7-x86_64/hyperscan-5.3.0-1.of.el7.x86_64.rpm \
&& rpm -i *.rpm
WORKDIR /vpp-up
g
COPY scripts/ /vpp-up
g
/scripts
WORKDIR /vpp-up
f
COPY scripts/ /vpp-up
f
/scripts
# Applying vpp patches
RUN git clone -b stable/2101 https://github.com/fdio/vpp.git && \
...
...
@@ -105,29 +105,29 @@ RUN wget http://repo.openfusion.net/centos7-x86_64/hyperscan-devel-5.3.0-1.of.el
http://repo.openfusion.net/centos7-x86_64/hyperscan-5.3.0-1.of.el7.x86_64.rpm \
&& rpm -i *.rpm && rm *.rpm && yum remove -y wget
WORKDIR /openair-up
g/bin/
COPY --from=vpp-upg-builder /vpp-up
g/scripts/entrypoint.sh /openair-upg/bin/entrypoint.sh
COPY --from=vpp-upg-builder /vpp-up
g
/vpp/build-root/install-vpp-native/vpp/bin/vpp .
COPY --from=vpp-upg-builder /vpp-up
g
/vpp/build-root/install-vpp-native/vpp/bin/vppctl .
WORKDIR /openair-up
f/bin
COPY --from=vpp-upg-builder /vpp-up
f/scripts/entrypoint.sh .
COPY --from=vpp-upg-builder /vpp-up
f
/vpp/build-root/install-vpp-native/vpp/bin/vpp .
COPY --from=vpp-upg-builder /vpp-up
f
/vpp/build-root/install-vpp-native/vpp/bin/vppctl .
WORKDIR /openair-up
g
/etc
COPY --from=vpp-upg-builder /vpp-up
g/scripts/upg_conf/init.conf /openair-upg/etc/init.conf
COPY --from=vpp-upg-builder /vpp-up
g/scripts/upg_conf/startup_debug.conf /openair-upg/etc/startup_debug.conf
WORKDIR /openair-up
f
/etc
COPY --from=vpp-upg-builder /vpp-up
f/scripts/upg_conf/init.conf .
COPY --from=vpp-upg-builder /vpp-up
f/scripts/upg_conf/startup_debug.conf .
WORKDIR /usr/lib64
COPY --from=vpp-upg-builder /vpp-up
g
/vpp/build-root/install-vpp-native/vpp/lib/ .
COPY --from=vpp-upg-builder /vpp-up
f
/vpp/build-root/install-vpp-native/vpp/lib/ .
RUN ldconfig
RUN groupadd vpp
WORKDIR /
vpp-upg/
COPY --from=vpp-upg-builder /vpp-upg/scripts/run.sh
/openair-upg/run.sh
WORKDIR /
openair-upf
COPY --from=vpp-upg-builder /vpp-upg/scripts/run.sh
.
#expose
EXPOSE 8085/udp 2152/udp
ENTRYPOINT ["/openair-upg/bin/entrypoint.sh"]
CMD ["/openair-up
g
/run.sh"]
CMD ["/openair-up
f
/run.sh"]
docs/BUILD_IMAGE.md
View file @
fd6ed460
...
...
@@ -5,7 +5,7 @@ $ git clone https://gitlab.eurecom.fr/oai/cn5g/oai-cn5g-upf-vpp.git
$
cd
oai-cn5g-upf-vpp
$
git checkout
develop
$
git checkout
vpp-upf
```
# 2. Generic Parameters #
...
...
@@ -19,7 +19,7 @@ Here in our network configuration, we need to pass the "GIT PROXY" configuration
## 3.1 On a Ubuntu 18.04 Host ##
```
bash
$
docker build
--target
vpp-up
f
--tag
vpp-upf
:develop
\
$
docker build
--target
vpp-up
g
--tag
vpp-upg
:develop
\
--file
docker/Dockerfile.ubuntu.18.04
\
--build-arg
NEEDED_GIT_PROXY
=
"http://proxy.eurecom.fr:8080"
.
```
...
...
@@ -27,7 +27,7 @@ $ docker build --target vpp-upf --tag vpp-upf:develop \
## 3.2 On a RHEL 7 Host ##
```
bash
$
docker build
--target
vpp-upg
--tag
vpp-up
f
:develop
\
$
docker build
--target
vpp-upg
--tag
vpp-up
g
:develop
\
--file
docker/Dockerfile.vppupf.rhel7
\
--build-arg
EURECOM_PROXY
=
"http://proxy.eurecom.fr:8080"
.
```
docs/DEPLOY_HOME.md
View file @
fd6ed460
...
...
@@ -19,4 +19,3 @@
3.
[
Building the Docker Image
](
./BUILD_IMAGE.md
)
4.
[
About network configuration
](
./VPP_NETWORKING.md
)
5.
[
About VPP-UPF configuration
](
./VPP_UPF_CONFIG.md
)
6.
[
Development guidelines for VPP-UPF
](
./DEVELOPMENT_GUIDELINE.md
)
docs/INSTALL_ON_HOST.md
View file @
fd6ed460
...
...
@@ -28,12 +28,3 @@ ubuntu@test-upf:~/oai-cn5g-upf-vpp/build/scripts$ ./build_vpp_upf -I -f
```
bash
ubuntu@test-upf:~/oai-cn5g-upf-vpp/build/scripts
$
./build_vpp_upf
-c
-V
-b
Debug
```
### Configure VPP-UPF
Refer this page for
[
VPP-UPF configuration
](
./VPP_UPF_CONFIG.md
)
### Launch VPP-UPF
```
bash
ubuntu@test-upf:~
$
cd
oai-cn5g-upf-vpp/vpp
ubuntu@test-upf:~/oai-cn5g-upf-vpp/vpp
$
./run.sh
```
docs/VPP_NETWORKING.md
View file @
fd6ed460
...
...
@@ -8,6 +8,7 @@ Here I have three interfaces to docker container. We rename them just for sec of
additional route added for UE traffic 10.10.10.0/24 network
<br/>
<br/>
<br/>
```
bash
ip
link set
eth0 down
ip
link set
eth0 name access
...
...
docs/VPP_UPF_CONFIG.md
View file @
fd6ed460
...
...
@@ -9,39 +9,41 @@ Below is sample vpp-upf configuration. We use at lease three veth-pairs as UPF i
ip table add 1
ip table add 2
####### Create N4 interface
create host-interface name core
set
interface mac address host-core 00:0c:29:46:1f:54
set
interface mtu 1500 host-core
set
interface ip table host-core 0
set
interface ip address host-core 192.168.61.201/26
set
interface state host-core up
####### Create N3 interface
create host-interface name access
set
interface mac address host-access 00:0c:29:46:1f:55
set
interface mtu 1500 host-access
set
interface ip table host-access 1
set
interface ip address host-access 192.168.62.201/26
set
interface state host-access up
####### Create N6 interface
create host-interface name sgi
set
interface mac address host-sgi 00:0c:29:46:1f:53
set
interface mtu 1500 host-sgi
set
interface ip table host-sgi 2
set
interface ip address host-sgi 192.168.63.201/26
set
interface state host-sgi up
####### Add ip routes
ip route add 0.0.0.0/0 table 0 via 192.168.61.196 host-core
ip route add 0.0.0.0/0 table 1 via 192.168.62.210 host-access
ip route add 0.0.0.0/0 table 2 via 192.168.63.194 host-sgi
####### Configure PFCP enpoint
upf pfcp endpoint ip 192.168.61.201 vrf 0
####### Add network instance
upf nwi name core vrf 0
upf nwi name access vrf 1
upf nwi name sgi vrf 2
####### Add fqdn
upf node-id fqdn gwu1.vpp.upg.node.epc.mnc095.mcc208.3gppnetwork.org
####### Specify release for TS 3GPP 29.244 (15 or 16)
upf specification release 16
trace add af-packet-input 100
...
...
scripts/entrypoint.sh
View file @
fd6ed460
...
...
@@ -44,24 +44,21 @@ done
# Near future we will have multiple interfaces (e.g. two n6 interface for edge computing case)
# We define in this order in docker-compose -> it is alphabetical order
#
SGI_IPV4
=
$(
ifconfig
$INTERFACE_SGI
|
grep
"inet "
|
awk
'{print $2}'
)
SGI_IPV4
=
$(
ifconfig eth2 |
grep
"inet "
|
awk
'{print $2}'
)
UE_DL_Gw
=
$SGI_IPV4
ip
link set
eth0 down
ip
link set
eth0 name access
ip
link set
$INTERFACE_ACCESS
down
ip
link set
$INTERFACE_ACCESS
name access
ip
link set
access up
ip
link set
eth1
down
ip
link set
eth1
name core
ip
link set
$INTERFACE_CORE
down
ip
link set
$INTERFACE_CORE
name core
ip
link set
core up
ip
link set
eth2
down
ip
link set
eth2
name sgi
ip
link set
$INTERFACE_SGI
down
ip
link set
$INTERFACE_SGI
name sgi
ip
link set
sgi up
ip route add
$NETWORK_UE_IP
via
$
UE_DL_Gw
dev sgi
ip route add
$NETWORK_UE_IP
via
$
SGI_IPV4
dev sgi
echo
"Done setting the configuration"
...
...
scripts/patches/rpm_dep_force_install.patch
0 → 100644
View file @
fd6ed460
--- a/Makefile 2021-04-30 14:53:42.462488110 +0200
+++ b/Makefile 2021-04-30 14:50:53.189155910 +0200
@@ -279,9 +279,9 @@
else ifneq ("$(wildcard /etc/redhat-release)","")
ifeq ($(OS_ID),rhel)
@sudo -E yum-config-manager --enable rhel-server-rhscl-7-rpms
- @sudo -E yum groupinstall $(CONFIRM) $(RPM_DEPENDS_GROUPS)
- @sudo -E yum install $(CONFIRM) $(RPM_DEPENDS)
- @sudo -E debuginfo-install $(CONFIRM) glibc openssl-libs mbedtls-devel zlib
+ @sudo -E yum groupinstall -y $(RPM_DEPENDS_GROUPS)
+ @sudo -E yum install -y $(RPM_DEPENDS)
+ @sudo -E debuginfo-install -y glibc openssl-libs mbedtls-devel zlib
else ifeq ($(OS_ID)-$(OS_VERSION_ID),centos-8)
@sudo -E dnf install $(CONFIRM) dnf-plugins-core epel-release
@sudo -E dnf config-manager --set-enabled \
scripts/tests/DStester_upf_multiple_ue.xml
deleted
100644 → 0
View file @
3d358dd2
This diff is collapsed.
Click to expand it.
scripts/tests/bench/DStester_upf_multiple_ue.xml
deleted
100644 → 0
View file @
3d358dd2
This diff is collapsed.
Click to expand it.
scripts/tests/bench/docker-compose.yml
deleted
100644 → 0
View file @
3d358dd2
version
:
'
3.8'
services
:
mysql
:
container_name
:
vpptest-mysql
image
:
mysql:5.7
volumes
:
-
./oai_db.sql:/docker-entrypoint-initdb.d/oai_db.sql
-
./mysql-healthcheck.sh:/tmp/mysql-healthcheck.sh
environment
:
-
TZ=Europe/Paris
-
MYSQL_DATABASE=oai_db
-
MYSQL_USER=test
-
MYSQL_PASSWORD=test
-
MYSQL_ROOT_PASSWORD=linux
healthcheck
:
test
:
/bin/bash -c "/tmp/mysql-healthcheck.sh"
interval
:
10s
timeout
:
5s
retries
:
5
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.200
oai-smf
:
image
:
oai-smf:vpp-upf
container_name
:
vpptest-oai-smf
privileged
:
true
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.196
environment
:
INSTANCE
:
1
PID_DIRECTORY
:
/var/run
SMF_INTERFACE_NAME_FOR_N4
:
eth0
SMF_INTERFACE_NAME_FOR_SBI
:
eth0
SMF_INTERFACE_PORT_FOR_SBI
:
80
SMF_INTERFACE_HTTP2_PORT_FOR_SBI
:
8080
SMF_API_VERSION
:
v1
DEFAULT_DNS_IPV4_ADDRESS
:
8.8.8.8
DEFAULT_DNS_SEC_IPV4_ADDRESS
:
8.8.4.4
UE_IP_ADDRESS_POOL
:
'
10.1.1.2
-
10.1.1.200'
AMF_IPV4_ADDRESS
:
192.168.74.195
AMF_PORT
:
80
AMF_API_VERSION
:
v1
UDM_IPV4_ADDRESS
:
192.168.74.194
UDM_PORT
:
80
UDM_API_VERSION
:
v1
UPF_IPV4_ADDRESS
:
192.168.74.202
USE_NETWORK_INSTANCE
:
'
yes'
DISCOVER_UPF
:
'
no'
NRF_API_VERSION
:
'
v1'
NRF_IPV4_ADDRESS
:
'
127.0.0.1'
NRF_PORT
:
'
8080'
REGISTER_NRF
:
'
no'
healthcheck
:
test
:
/bin/bash -c "pgrep oai_smf"
interval
:
10s
timeout
:
5s
retries
:
5
extra_hosts
:
-
"
gw1.vppupf.node.5gcn.mnc95.mcc208.3gppnetwork.org:192.168.74.202"
oai-amf
:
image
:
oai-amf:develop
container_name
:
vpptest-oai-amf
privileged
:
true
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.195
environment
:
INSTANCE
:
1
PID_DIRECTORY
:
/var/run
MCC
:
'
208'
MNC
:
'
95'
REGION_ID
:
'
128'
AMF_SET_ID
:
1
SERVED_GUAMI_MCC_0
:
'
208'
SERVED_GUAMI_MCC_1
:
'
460'
SERVED_GUAMI_MNC_0
:
'
95'
SERVED_GUAMI_MNC_1
:
'
11'
SERVED_GUAMI_REGION_ID_0
:
'
95'
SERVED_GUAMI_REGION_ID_1
:
'
11'
SERVED_GUAMI_AMF_SET_ID_0
:
'
1'
SERVED_GUAMI_AMF_SET_ID_1
:
'
1'
PLMN_SUPPORT_MCC
:
'
208'
PLMN_SUPPORT_MNC
:
'
95'
PLMN_SUPPORT_TAC
:
'
0xa000'
SST_0
:
'
222'
SST_1
:
'
1'
SD_0
:
'
123'
SD_1
:
'
12'
SMF_SELECTION
:
'
no'
SMF_INSTANCE_ID_0
:
1
SMF_INSTANCE_ID_1
:
2
SMF_IPV4_ADDR_0
:
192.168.74.196
SMF_IPV4_ADDR_1
:
127.0.0.1
SMF_HTTP_VERSION_0
:
v1
SMF_HTTP_VERSION_1
:
v1
AMF_INTERFACE_NAME_FOR_NGAP
:
eth0
AMF_INTERFACE_NAME_FOR_N11
:
eth0
AUSF_IPV4_ADDRESS
:
192.168.74.205
AUSF_API_VERSION
:
'
v1'
AUSF_PORT
:
80
NRF_IPV4_ADDRESS
:
192.168.74.206
NRF_API_VERSION
:
'
v1'
NRF_PORT
:
80
MYSQL_SERVER
:
192.168.74.200
MYSQL_USER
:
'
root'
MYSQL_PASS
:
'
linux'
MYSQL_DB
:
'
oai_db'
OPERATOR_KEY
:
'
63bfa50ee6523365ff14c1f45f88737d'
NF_REGISTRATION
:
'
no'
healthcheck
:
test
:
/bin/bash -c "pgrep oai_smf"
interval
:
10s
timeout
:
5s
retries
:
5
oai-vpp
:
image
:
vpp-upg:latest
privileged
:
true
container_name
:
vpptest-oai-vpp-upf
networks
:
macvlan_net
:
ipv4_address
:
192.168.75.197
macvlan_net
:
ipv4_address
:
192.168.74.197
macvlan_net
:
ipv4_address
:
192.168.76.197
environment
:
NWI_CORE
:
"
core.oai"
NWI_ACCESS
:
"
access.oai"
NWI_SGI
:
"
sgi.oai"
# NWI_SGI_SEC: "sgi.secondary.oai" # To Do - Traffic sterring or traffic redirection or I-UPF (N9)
GW_ID
:
"
1"
MNC03
:
"
95"
MCC
:
"
208"
REALM
:
"
3gppnetwork.org"
NETWORK_UE_IP
:
"
12.1.1.0/24"
N3_IPV4_ADDRESS_REMOTE
:
"
192.168.75.198"
N3_IPV4_ADDRESS_LOCAL
:
"
192.168.75.202"
N4_IPV4_ADDRESS_REMOTE
:
"
192.168.74.196"
N4_IPV4_ADDRESS_LOCAL
:
"
192.168.74.202"
N6_IPV4_ADDRESS_REMOTE
:
"
192.168.76.205"
N6_IPV4_ADDRESS_LOCAL
:
"
192.168.76.202"
VPP_MAIN_CORE
:
0
VPP_CORE_WORKER
:
1
oai-spgwu
:
image
:
oai-spgwu-tiny:gtp_ext_header
privileged
:
true
container_name
:
oai-spgwu
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.199
environment
:
INSTANCE
:
1
PID_DIRECTORY
:
/var/run
SGW_INTERFACE_NAME_FOR_S1U_S12_S4_UP
:
"
eth0"
SGW_INTERFACE_NAME_FOR_SX
:
"
eth0"
PGW_INTERFACE_NAME_FOR_SGI
:
"
eth0"
SPGWC0_IP_ADDRESS
:
"
192.168.74.196"
NETWORK_UE_IP
:
"
10.1.1.0/24"
NETWORK_UE_NAT_OPTION
:
"
yes"
NRF_IPV4_ADDRESS
:
"
192.168.1.23"
NRF_PORT
:
"
8080"
NRF_API_VERSION
:
"
v1"
GW_ID
:
"
1"
MNC03
:
"
95"
MCC
:
"
208"
REALM
:
"
3gppnetwork.org"
THREAD_S1U_PRIO
:
"
64"
S1U_THREADS
:
"
16"
THREAD_SX_PRIO
:
"
64"
SX_THREADS
:
"
1"
THREAD_SGI_PRIO
:
"
64"
SGI_THREADS
:
"
16"
GTP_EXTENSION_HEADER_PRESENT
:
"
no"
BYPASS_UL_PFCP_RULES
:
"
no"
oai-nat
:
image
:
ubuntu:bionic
privileged
:
true
container_name
:
vpptest-oai-nat
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.205
macvlan_net
:
ipv4_address
:
192.168.76.205
entrypoint
:
/bin/bash -c \
"apt update; apt install -y iptables iproute2 iputils-ping net-tools python iperf3;"\
"iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE;"\
"ip route add 10.1.1.0/24 via 192.168.74.199 dev eth0;"\
"ip route add 12.1.1.0/24 via 192.168.76.201 dev eth1; sleep infinity"
gnbsim
:
image
:
gnbsim:latest
privileged
:
true
container_name
:
vpptest-gnbsim
environment
:
MCC
:
208
MNC
:
95
GNBID
:
1
TAC
:
'
0x00a000'
SST
:
'
222'
SD
:
'
010203'
SD_UE_PARAM
:
'
00007b'
PagingDRX
:
'
v32'
RANUENGAPID
:
0
IMEISV
:
'
35609204079514'
MSIN
:
'
0000000031'
RoutingIndicator
:
1234
ProtectionScheme
:
'
null'
KEY
:
'
0C0A34601D4F07677303652C0462535B'
OPc
:
'
63bfa50ee6523365ff14c1f45f88737d'
DNN
:
'
default'
URL
:
'
http://192.168.76.205:8000'
NRCellID
:
1
NGAPPeerAddr
:
'
192.168.74.195'
GTPuLocalAddr
:
'
192.168.75.198'
GTPuIFname
:
'
eth0'
networks
:
macvlan_net
:
ipv4_address
:
192.168.74.198
macvlan_net
:
ipv4_address
:
192.168.75.198
volumes
:
-
./lib/modules/4.15.0-76-generic/kernel/drivers/net/gtp.ko:/lib/modules/5.8.0-43-generic/kernel/drivers/net/gtp.ko
networks
:
# public_net:
# name: oai-public-net
# ipam:
# config:
# - subnet: 192.168.74.0/24
# public_net_access:
# name: oai-public-access
# ipam:
# config:
# - subnet: 192.168.75.0/24
# public_net_sgi_lan:
# name: oai-public-sgi-lan
# ipam:
# config:
# - subnet: 192.168.76.0/24
macvlan_net
:
external
:
name
:
oairohan
scripts/tests/bench/mysql-healthcheck.sh
deleted
100755 → 0
View file @
3d358dd2
#!/bin/bash
set
-eo
pipefail
if
[
"
$MYSQL_ROOT_PASSWORD
"
]
&&
[
-z
"
$MYSQL_USER
"
]
&&
[
-z
"
$MYSQL_PASSWORD
"
]
;
then
echo
>
&2
'Healthcheck error: cannot determine root password (and MYSQL_USER and MYSQL_PASSWORD were not set)'
exit
0
fi
host
=
"
$(
hostname
--ip-address
||
echo
'127.0.0.1'
)
"
user
=
"
${
MYSQL_USER
:-
root
}
"
export
MYSQL_PWD
=
"
${
MYSQL_PASSWORD
:-
$MYSQL_ROOT_PASSWORD
}
"
args
=(
# force mysql to not use the local "mysqld.sock" (test "external" connectivity)
-h
"
$host
"
-u
"
$user
"
--silent
)
STATUS
=
0
if
command
-v
mysqladmin &> /dev/null
;
then
if
mysqladmin
"
${
args
[@]
}
"
ping
>
/dev/null
;
then
database_check
=
$(
mysql
-u
$user
-D
oai_db
--silent
-e
"SELECT * FROM users;"
)
if
[[
-z
$database_check
]]
;
then
echo
"Healthcheck error: oai_db not populated"
STATUS
=
1
fi
STATUS
=
0
else
echo
"Healthcheck error: Mysql port inactive"
STATUS
=
1
fi
else
if select
=
"
$(
echo
'SELECT 1'
| mysql
"
${
args
[@]
}
"
)
"
&&
[
"
$select
"
=
'1'
]
;
then
database_check
=
$(
mysql
-u
$user
-D
oai_db
--silent
-e
"SELECT * FROM users;"
)
if
[[
-z
$database_check
]]
;
then
echo
"Healthcheck error: oai_db not populated"
STATUS
=
1
fi
STATUS
=
0
else
echo
"Healthcheck error: Mysql port inactive"
STATUS
=
1
fi
fi
exit
$STATUS
scripts/tests/bench/oai_db.sql
deleted
100755 → 0
View file @
3d358dd2
This diff is collapsed.
Click to expand it.
scripts/tests/docker-compose.yml
View file @
fd6ed460
...
...
@@ -21,7 +21,6 @@ services:
networks
:
public_net
:
ipv4_address
:
192.168.74.200
oai-smf
:
image
:
oai-smf:vpp-upf
depends_on
:
[
oai-vpp
]
...
...
@@ -61,8 +60,6 @@ services:
retries
:
5
extra_hosts
:
-
"
gw1.vppupf.node.5gcn.mnc95.mcc208.3gppnetwork.org:192.168.74.202"
-
"
gw1.spgw.node.epc.mnc95.mcc208.3gppnetwork.org:192.168.74.199"
oai-amf
:
image
:
oai-amf:develop
depends_on
:
[
oai-smf
,
mysql
]
...
...
@@ -119,9 +116,8 @@ services:
interval
:
10s
timeout
:
5s
retries
:
5
oai-vpp
:
image
:
vpp-upg:
latest
image
:
vpp-upg:
develop
privileged
:
true
container_name
:
vpp-upf
networks
:
...
...
@@ -135,7 +131,6 @@ services:
NWI_CORE
:
"
core.oai"
NWI_ACCESS
:
"
access.oai"
NWI_SGI
:
"
sgi.oai"
# NWI_SGI_SEC: "sgi.secondary.oai" # To Do - Traffic sterring or traffic redirection or I-UPF (N9)
GW_ID
:
"
1"
MNC03
:
"
95"
MCC
:
"
208"
...
...
@@ -151,44 +146,14 @@ services:
VPP_CORE_WORKER
:
1
# VPP_PLUGIN_PATH: "/usr/lib64/vpp_plugins/" # RHEL7
VPP_PLUGIN_PATH
:
"
/usr/lib/x86_64-linux-gnu/vpp_plugins/"
# Ubntu18.04
INTERFACE_ACCESS
:
"
eth0"
INTERFACE_CORE
:
"
eth1"
INTERFACE_SGI
:
"
eth2"
healthcheck
:
test
:
/bin/bash -c "pgrep vpp"
interval
:
10s
timeout
:
5s
retries
:
5
oai-spgwu
:
image
:
oai-spgwu-tiny:gtp_ext_header
privileged
:
true
container_name
:
oai-spgwu
networks
:
public_net
:
ipv4_address
:
192.168.74.199
environment
:
INSTANCE
:
1
PID_DIRECTORY
:
/var/run
SGW_INTERFACE_NAME_FOR_S1U_S12_S4_UP
:
"
eth0"
SGW_INTERFACE_NAME_FOR_SX
:
"
eth0"
PGW_INTERFACE_NAME_FOR_SGI
:
"
eth0"
SPGWC0_IP_ADDRESS
:
"
192.168.74.196"
NETWORK_UE_IP
:
"
10.1.1.0/24"
NETWORK_UE_NAT_OPTION
:
"
yes"
NRF_IPV4_ADDRESS
:
"
192.168.1.23"
NRF_PORT
:
"
8080"
NRF_API_VERSION
:
"
v1"
GW_ID
:
"
1"
MNC03
:
"
95"
MCC
:
"
208"
REALM
:
"
3gppnetwork.org"
THREAD_S1U_PRIO
:
"
64"
S1U_THREADS
:
"
16"
THREAD_SX_PRIO
:
"
64"
SX_THREADS
:
"
1"
THREAD_SGI_PRIO
:
"
64"
SGI_THREADS
:
"
16"
GTP_EXTENSION_HEADER_PRESENT
:
"
no"
BYPASS_UL_PFCP_RULES
:
"
no"
retries
:
5
oai-nat
:
image
:
ubuntu:bionic
privileged
:
true
...
...
@@ -201,9 +166,7 @@ services:
entrypoint
:
/bin/bash -c \
"apt update; apt install -y iptables iproute2 iputils-ping net-tools python iperf3;"\
"iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE;"\
"ip route add 10.1.1.0/24 via 192.168.74.199 dev eth0;"\
"ip route add 12.1.1.0/24 via 192.168.76.201 dev eth1; sleep infinity"
"ip route add 12.1.1.0/24 via 192.168.76.202 dev eth1; sleep infinity"
gnbsim
:
image
:
gnbsim:latest
depends_on
:
[
oai-amf
]
...
...
@@ -215,8 +178,7 @@ services:
GNBID
:
1
TAC
:
'
0x00a000'
SST
:
'
222'
SD
:
'
010203'
SD_UE_PARAM
:
'
00007b'
SD
:
'
00007b'
PagingDRX
:
'
v32'
RANUENGAPID
:
0
IMEISV
:
'
35609204079514'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment