Commit Graph

30 Commits

Author SHA1 Message Date
Pau Espin 772482145f ttcn3-pgw-test: Configure open5gs-smfd S2b/S6b/P-CSCF related bits
Depends: osmo-ttcn3-hacks.git Change-Id I38e469edf0e00feca5a648035b64645e2c905937
Change-Id: I3ff503990167f52ddb94a7719e2773db3f889a39
2024-02-28 13:12:01 +00:00
Oliver Smith 15caf486bb open5gs configs: update to current format
Adjust open5gs configs to the new formats from:

This fixes all open5gs programs from crashing on startup with various
errors such as:
  11/21 07:39:25.971: [core] FATAL: epoll_init: Assertion `context->epfd >= 0' failed. (../lib/core/ogs-epoll.c:77)

Related: OS#6267
Change-Id: Idf2706f3904eb06e94cee0728faa17e72a6cf1f6
2023-11-23 16:30:51 +01:00
Oliver Smith 4836524115 open5gs configs: duplicate cfgs for latest/master
The config format just changed significantly in main/master. Duplicate
the configs, so we can run latest with the old versions.

Related: OS#6267
Change-Id: I2446695172b92ccf75305f878cb932a82e44fdd2
2023-11-23 16:30:51 +01:00
Oliver Smith 71a4f4c9ac open5gs configs: remove comments
A lot of these comments got outdated with recent config changes
in the related PR. Instead of syncing the comments again and having a
big diff, remove the comments once and then only have diffs of
actual config changes in future patches. This will make it easier to
maintain these configs.

Change-Id: I67c2a198b9682e15e23a466380e62a976e6236cd
2023-11-23 16:30:51 +01:00
Oliver Smith 6a8118dad8 ttcn3: use debian-bookworm-titan
Related: OS#6057
Change-Id: I2017dd3888670c475b96e692d911a433484f3df9
2023-08-14 09:28:24 +00:00
Vadim Yanitskiy abd1105000 ttcn3-pgw-test: make the testsuite dir writable by all users
When running as root or any other user with UID different
than UID=1000 of the 'osmocom' user we have in open5gs-{master,latest}
images, programs spawned by osmo-uecups-daemon (e.g. ping) may fail to
start.  In such cases, osmo-uecups-daemon reports unexpected program
termination with exit code=512.  This is happening because the
stdout and stderr of a spawned program are being redirected to
"$VOL_BASE_DIR/pgw-tester/TESTCASE.prog.std{out,err}", for which
the 'osmocom' user needs to have write permissions.

Change-Id: Icb6b30e618e290d974a919fef34c6b5cb7eeb648
Related: OS#5913
2023-02-26 15:38:16 +07:00
Vadim Yanitskiy 18b578295e ttcn3-pgw-test: update open5gs-{nrf,smf,upf} config files
As stated in the ticket, both open5gs-{nrf,smf} daemons refuse to
start since build #326 because of the following error:

  [sbi] ERROR: TLS enabled but no server key (../lib/sbi/context.c:186)

The problem is that the recent open5gs (v2.6.0-39-g22be888 at the
moment of writing) is attempting to employ TLS verification for SBI
even if it's not explicitly configured in the config files.

  commit 05fbaf69587488e53b5e741a9ada9f9fa5749322
  Author: Sukchan Lee <>
  Date:   Sat Feb 18 10:58:29 2023 +0900

    [SBI] HTTP2-TLS verification - ConfFile Changed

Our config files are slightly outdated, so let's take a chance
to update them and specify the missing TLS params.  Check out
open5gs-{nrf,smf,upf}.yaml from the latest git version.

The updated files are confirmed to work with both:

* latest release for Debian v2.5.8, and
* latest git version v2.6.0-39-g22be888.

Change-Id: I27adbab6a6b95ddf4c6d39803e4f7dd079f11a4c
Related: OS#5913
2023-02-21 00:13:00 +07:00
Vadim Yanitskiy 273e066c98 ttcn3-pgw-test: allow using osmo-uecups from the latest feed
Change-Id: I4f92577f062e8a9be29af83026214636dff19d78
2023-02-20 16:41:38 +07:00
Oliver Smith f997b4e771 network_create: find free subnet automatically
Try multiple subnet numbers until successfully creating a network. This
way we can run the same ttcn3 testsuite multiple times in parallel
without conflicts (e.g. once against latest, once against nightly). Also
we don't need to make sure each new testsuite has a unique subnet
number anymore.

I've considered also adjusting network_bridge_create, but that gets used
exclusively by osmo-ran/, a script which we don't actually run
in jenkins. It seems that in this script it makes more sense to not get
a random subnet number.

Related: OS#5802
Change-Id: I57152b08ef0f38e17e7019a8df032189b03f56cf
2023-01-16 15:19:29 +00:00
Pau Espin 0ecbb795c5 ttcn3-{pgw,ggsn}-test: Update smf.yml with new metrics section location
The "metrics" section was moved inside each program node to avoid
clashes when several network programs are run in the same process and
use the same config file.

Depends: open5gs.git 2d4fbf92eb1be9ffe84df6dc103ee7401d1d3b0f
Change-Id: Iae16bfccfbaaed37701e671ba619f8082f55506d
2022-11-21 11:28:52 +01:00
Vadim Yanitskiy ff221f9af5 ttcn3-pgw-test: update freeDiameter-smf.conf
Recent open5gs changed location of the TLS key and certificate files:

  commit 0859dd44530a944076c207c750188572effc2709
  Author: Sukchan Lee <>
  Date:   Sat Nov 12 09:37:43 2022 +0900

      Follow-up on #1865

Updating paths makes the open5gs-master work, however the -latest
still installs these files to '/etc/freeDiameter/'.  Let's remove
both 'TLS_Cred' and 'TLS_CA' params, we are not using TLS anyway.

Change-Id: Ic90f713fb127f8d5407c18553b29b3c2be141420
2022-11-15 22:41:08 +07:00
Pau Espin a719a8db61 Use gerrit as osmo-ttcn3-hacks.git git remote
Other remotes are mirrors of gerrit one, which means there's some delay
between pushing some ref to the gerrit remote and having them available
in the mirrors.
Hence, it becomes annoying while developing and new stuff to test is
pushed. Let's simply use gerrit since it's the master remote.

Change-Id: Ic87c196f8b91a3a3e6ddde2cca36482ce7070df7
2022-09-20 12:09:32 +02:00
Pau Espin e7a5379e29 open5gs: Enable libmetrics prometheus implementation
metrics support using Prometheus has been recently added to open5gs
(28e40a0f1b9048768958344e213c69994be671f5). However, it is still not
enabled by default. Let's enable it and update open5gs config files to
make use of it.

Change-Id: I6ec827d66241e20d631f3a851457921718c168a0
2022-06-08 13:49:43 +02:00
Pau Espin af1397c5ea ttcn3-pgw: Configure Gy interface
Depends: osmo-ttcn3-hacks.git Ie4e567f62bbbdba276e6b3221111c8d9f82cde14
Change-Id: Iaeed2086aa058e1079295cb1911ad80e9613f8fa
2022-04-21 17:29:32 +02:00
Pau Espin e9146766b5 ttcn-pgw-test: Improve osmo-uecups cfg file
Bind to specific container IP address.
Use more uniform logging config settings as most of the other osmocom processes.

Change-Id: I36bb04a388ab65aaa03a82c159a1b258886ec0d0
2022-04-12 13:41:44 +02:00
Pau Espin 043f436fcb ttcn3-pgw: Parallel docker container stop
Stopping all the containers takes quite a lot of time. Let's stop them
all in parallel to gain some time.

Change-Id: Iabf63ebdee9d1bf13a364ea3eb530ed9dae9b2a5
2022-04-11 13:31:04 +02:00
Pau Espin e9a25e2b25 ttcn3-pgw: Pass config file to osmo-uecups
Change-Id: I714172ca063c76a3104daf06f52b5823f304dffe
2022-04-11 13:21:21 +02:00
Pau Espin 713468b295 ttcn3-{ggsn,pgw}-test: Avoid open5gs itself logging to a file
We already log stdout/stderr to a file, so there's no need to log a file
internally. We prefer logging that through stdout/stderr in order to
catch more stuff, like segfaults.

Change-Id: Ifdc010f26abdc8cefeec0c72a1f617911ec375d7
2022-04-07 20:40:12 +02:00
Pau Espin 9a744f2108 ttcn3-pgw-test: Log open5gs-nrfd stdout/stderr
This way we see potential crashes.

Change-Id: I31f2ff2dd5daa68756e910c4cb91acefdad50cb1
2022-04-07 20:38:31 +02:00
Pau Espin 5c9182751c ttcn3-pgw-tests: use same bootstrap for upfd as in ttcn-ggsn-tests-ogs
This approach has several benefits:
* We end up with ip/tun setup output in the same log file as
  open5gs-upfd process output.
* We configure all ip/tun *before* the open5gs-upfd process starts.

Furthermore, we have same procedure as in ttcn3-ggsn-tests-ogs, which
simplifies maintainment/use.

The IP address pool for UEs is still different in pgw-tests and
ggsn-tests-ogs. We can make them the same in subsequent patches.

Change-Id: I94219abbeb5e004ce707407b5aa5ee8ad6c3a80e
2022-04-07 20:24:18 +02:00
Pau Espin 6acec0cbd1 ttcn3-{pgw,ggsn}-tests: Add comment with procedure to get open5gs-smfd bt automatically
Some specific gdb commands need to be run in open5gs-smfd to get the
desired result (some signals need to be ignored).
gdb use is not enabled by default. Furthermore, if one wants to use it,
editing the Dockerfile to install gdb is required.

Change-Id: I1ac8b77e84d57040fc09964356bc8a01e5d721e3
2022-04-07 19:48:51 +02:00
Pau Espin ca3b751ae0 ttcn3-pgw-test: Use process name in log file
This way it becomes similar to what we use in ttcn3-ggsn-tests-ogs.

Change-Id: Ibac0e6bc9dc7c2e576a4f5d1ccb730211d1e1427
2022-04-07 19:42:11 +02:00
Pau Espin 8063cd7da1 ttcn3-pgw-test: Log stdout to find crashes
Change-Id: I573637866787ce1f613bd56a009251578c98cbf3
2022-04-07 19:40:33 +02:00
Vadim Yanitskiy bfabf9aa42 ttcn3-pgw-test: configure the 'ogstun' device for open5gs-upfd
Unlike osmo-ggsn, open5gs-upfd does not configure the tun interface
itself.  All IPv4/IPv6 addresses must be assigned manually.  This
is exactly why both PGW_Tests.TC_createSession_ping4[_256] fail:

  [sock] ERROR: ogs_write() failed (5:Input/outputerror) (../lib/tun/tunio.c:84)
  [upf] WARNING: ogs_tun_write() failed (../src/upf/gtp-path.c:448)

Take Harald's from open5gs-master and execute it in the
container running open5gs-upfd.  This fixes the ogs_write() errors.

Change-Id: I0730b1f69285484a0aa0ebd664dafd8e476b294f
Related: SYS#5602
2022-02-03 13:55:41 +06:00
Vadim Yanitskiy 647a5fdef9 ttcn3-pgw-test: set PGW_Tests.mp_run_prog_log_path to '/data'
Change-Id: Idd5a37e5768c400d410958149b97869db1e92fb1
Depends: I04ab92c13fcd893d39dbb6a8a8af5ff41d207e36
Related: SYS#5602
2022-02-02 23:34:56 +06:00
Vadim Yanitskiy cb73113dc4 ttcn3-pgw-test: make osmo-uecups-daemon more verbose
Change-Id: Id491b4f9db63c82f3dc58f3fc523b4f84fea01e0
Related: SYS#5602
2022-02-02 23:31:47 +06:00
Vadim Yanitskiy 290df47815 ttcn3-pgw-test: fix do not use bash specific syntax
On some systems /bin/sh is a symbolic link to bash, so everything
works fine.  On systems where /bin/sh is a real sh, copy fails:

  cp: cannot access 'open5gs-{smf,upf,nrf}.yaml': No such file or directory

Change-Id: I64e9ddefdb6deb21b3bce3bc1af875a92919e6c9
Related: SYS#5602
2022-01-29 18:54:08 +06:00
Vadim Yanitskiy 4f57079115 ttcn3-pgw-test: set '--ulimit core=-1' for osmo-uecups-daemon
Change-Id: I16f4eefa2bb48486c139ca63f2a48346f0532a8c
Related: SYS#5602
2022-01-26 00:23:13 +06:00
Vadim Yanitskiy 13d4b200b2 ttcn3-pgw-test: set '--ulimit core=-1' for open5gs-{nrf,upf,smf}
Change-Id: I2da2d502f339fc4cbea8fa72414eeaeb6078dfd9
Related: SYS#5602
2022-01-26 00:23:13 +06:00
Harald Welte 7c32f1deb7 ttcn3-pgw-test: add Dockerfile, and configs for open5gs
Change-Id: I69e2f5be8204cc4fd0cc0f4eb019ef1104121b60
Tweaked-By: Vadim Yanitskiy <>
Related: SYS#5602
2022-01-26 00:23:13 +06:00