Projects
osmocom:nightly
osmo-hnbgw
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 117
View file
osmo-hnbgw.spec
Changed
@@ -17,14 +17,14 @@ %define _lto_cflags %{nil} Name: osmo-hnbgw -Requires: osmocom-nightly = 202210200002 -Version: 1.3.0.45.b9be.202210200002 +Requires: osmocom-nightly = 202210210002 +Version: 1.3.0.48.0e03.202210210002 Release: 0 Summary: OsmoHNBGW: Osmocom's Base Station Controller for 2G CS mobile networks License: AGPL-3.0-or-later AND GPL-2.0-or-later Group: Hardware/Mobile URL: https://osmocom.org/projects/osmohnbgw -Source: osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz +Source: osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz Source1: rpmlintrc BuildRequires: automake >= 1.9 BuildRequires: libtool >= 2
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.dsc -> osmo-hnbgw_1.3.0.48.0e03.202210210002.dsc
Changed
@@ -2,7 +2,7 @@ Source: osmo-hnbgw Binary: osmo-hnbgw, osmo-hnbgw-dbg, osmo-hnbgw-doc Architecture: any all -Version: 1.3.0.45.b9be.202210200002 +Version: 1.3.0.48.0e03.202210210002 Maintainer: Osmocom team <openbsc@lists.osmocom.org> Homepage: https://projects.osmocom.org/projects/osmo-hnbgw Standards-Version: 3.9.8 @@ -14,8 +14,8 @@ osmo-hnbgw-dbg deb debug extra arch=any osmo-hnbgw-doc deb doc optional arch=all Checksums-Sha1: - 559c87ce5a312a50c9337e97a2b4b35ddd550540 72104 osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz + 9b03d7e0697ed3b473452a1c4621eed0de930b35 72828 osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz Checksums-Sha256: - 59742e5fed28bd1223e983701471793b36b8dd49ca8b9c9833ace83f7555f118 72104 osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz + f3af91da8b050983395a8a44671c506183c5ebab2c7588ebe6c7602d4cdd495d 72828 osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz Files: - e26e696bf0c6402266b8bf2f9f8b5b11 72104 osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz + 21aa4a4cac22c033aaaa7f0a84170846 72828 osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/.tarball-version -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/.tarball-version
Changed
@@ -1 +1 @@ -1.3.0.45-b9be.202210200002 +1.3.0.48-0e03.202210210002
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/contrib/osmo-hnbgw.spec.in -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/contrib/osmo-hnbgw.spec.in
Changed
@@ -17,7 +17,7 @@ %define _lto_cflags %{nil} Name: osmo-hnbgw -Requires: osmocom-nightly = 202210200002 +Requires: osmocom-nightly = 202210210002 Version: @VERSION@ Release: 0 Summary: OsmoHNBGW: Osmocom's Base Station Controller for 2G CS mobile networks
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/debian/changelog -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/debian/changelog
Changed
@@ -1,8 +1,8 @@ -osmo-hnbgw (1.3.0.45.b9be.202210200002) unstable; urgency=medium +osmo-hnbgw (1.3.0.48.0e03.202210210002) unstable; urgency=medium * Automatically generated changelog entry for building the Osmocom nightly feed - -- Osmocom OBS scripts <info@osmocom.org> Thu, 20 Oct 2022 00:03:10 +0000 + -- Osmocom OBS scripts <info@osmocom.org> Fri, 21 Oct 2022 00:03:10 +0000 osmo-hnbgw (1.3.0) unstable; urgency=medium
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/debian/control -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/debian/control
Changed
@@ -31,7 +31,7 @@ Package: osmo-hnbgw Architecture: any Multi-Arch: foreign -Depends: osmocom-nightly (= 202210200002), ${misc:Depends}, ${shlibs:Depends} +Depends: osmocom-nightly (= 202210210002), ${misc:Depends}, ${shlibs:Depends} Recommends: osmo-mgw Description: OsmoHNBGW: Osmocom Home Node B Gateway @@ -39,14 +39,14 @@ Section: debug Architecture: any Multi-Arch: same -Depends: osmocom-nightly (= 202210200002), osmo-hnbgw (= ${binary:Version}), ${misc:Depends} +Depends: osmocom-nightly (= 202210210002), osmo-hnbgw (= ${binary:Version}), ${misc:Depends} Description: OsmoHNBGW: Osmocom Home Node B Gateway Package: osmo-hnbgw-doc Architecture: all Section: doc Priority: optional -Depends: osmocom-nightly (= 202210200002), ${misc:Depends} +Depends: osmocom-nightly (= 202210210002), ${misc:Depends} Description: ${misc:Package} PDF documentation Various manuals: user manual, VTY reference manual and/or protocol/interface manuals.
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/doc/examples/osmo-hnbgw/osmo-hnbgw-pfcp.cfg -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/doc/examples/osmo-hnbgw/osmo-hnbgw-pfcp.cfg
Changed
@@ -11,11 +11,11 @@ iuh local-ip 0.0.0.0 hnbap-allow-tmsi 1 - mgcp - mgw remote-ip 127.0.0.1 - mgw local-port 2729 - mgw remote-port 2427 - mgw reset-endpoint rtpbridge/* + mgw 0 + remote-ip 127.0.0.1 + local-port 2729 + remote-port 2427 + reset-endpoint rtpbridge/* pfcp remote-addr 127.0.0.2 local-addr 127.0.0.1
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/doc/examples/osmo-hnbgw/osmo-hnbgw.cfg -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/doc/examples/osmo-hnbgw/osmo-hnbgw.cfg
Changed
@@ -11,9 +11,9 @@ iuh local-ip 0.0.0.0 hnbap-allow-tmsi 1 - mgcp - mgw remote-ip 127.0.0.1 - mgw local-port 2729 - mgw remote-port 2427 - mgw reset-endpoint rtpbridge/* + mgw 0 + remote-ip 127.0.0.1 + local-port 2729 + remote-port 2427 + reset-endpoint rtpbridge/*
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/doc/manuals/chapters/running.adoc -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/doc/manuals/chapters/running.adoc
Changed
@@ -136,11 +136,28 @@ ---- hnbgw - mgcp - mgw remote-ip 127.0.0.1 - mgw remote-port 2427 - mgw reset-endpoint rtpbridge/* + mgw 0 + remote-ip 127.0.0.1 + remote-port 2427 + reset-endpoint rtpbridge/* <1> ---- +<1> The 'reset-endpoint' setting instructs the OsmoMGW to send a wildcarded +DLCX to the media gateway. This helps to clear lingering calls from the +media gateway when the OsmoHNBGW is restarted. + +OsmoHNBGW is also able to handle a pool of media gateways for load +distribution. See also <<mgw_pooling>>. + +NOTE +==== +Previous versions of OsmoHNBGW didn't have the 'mgw' VTY node and +hence didn't support the MGW pooling feature. Therefore, historically the MGW +related commands where placed under the `mgcp` VTY node. The MGW related commands +under the `mgcp` VTY are still parsed and used but its use is deprecated and +hence discouraged in favour of the new `mgw` node. Writing the config to a file +from within OsmoHNBGW will automatically convert the config to use the new `mgw` +node. +==== ==== Configure co-located User Plane Function
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/doc/manuals/osmohnbgw-usermanual.adoc -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/doc/manuals/osmohnbgw-usermanual.adoc
Changed
@@ -24,6 +24,8 @@ include::./common/chapters/cs7-config.adoc +include::./common/chapters/mgwpool.adoc + // include::{srcdir}/chapters/net.adoc // include::./common/chapters/control_if.adoc
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/include/osmocom/hnbgw/hnbgw.h -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/include/osmocom/hnbgw/hnbgw.h
Changed
@@ -10,6 +10,8 @@ #define DEBUG #include <osmocom/core/logging.h> +#include <osmocom/mgcp_client/mgcp_client.h> +#include <osmocom/mgcp_client/mgcp_client_pool.h> enum { DMAIN, @@ -160,7 +162,9 @@ struct osmo_sccp_addr iucs_remote_addr; struct osmo_sccp_addr iups_remote_addr; } sccp; - struct mgcp_client *mgcp_client; + /* MGW pool, also includes the single MGCP client as fallback if no + * pool is configured. */ + struct mgcp_client_pool *mgw_pool; struct { struct osmo_pfcp_endpoint *ep;
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/include/osmocom/hnbgw/vty.h -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/include/osmocom/hnbgw/vty.h
Changed
@@ -8,6 +8,7 @@ IUCS_NODE, IUPS_NODE, MGCP_NODE, + MGW_NODE, PFCP_NODE, };
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/src/osmo-hnbgw/Makefile.am -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/src/osmo-hnbgw/Makefile.am
Changed
@@ -55,7 +55,6 @@ $(LIBOSMORUA_LIBS) \ $(LIBOSMORANAP_LIBS) \ $(LIBOSMOHNBAP_LIBS) \ - $(LIBOSMOMGCPCLIENT_LIBS) \ $(LIBSCTP_LIBS) \ $(LIBOSMOMGCPCLIENT_LIBS) \ $(NULL)
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/src/osmo-hnbgw/hnbgw.c -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/src/osmo-hnbgw/hnbgw.c
Changed
@@ -104,6 +104,7 @@ context_map_init(gw); + gw->mgw_pool = mgcp_client_pool_alloc(gw); gw->config.mgcp_client = talloc_zero(tall_hnb_ctx, struct mgcp_client_conf); mgcp_client_conf_init(gw->config.mgcp_client); @@ -673,6 +674,41 @@ return 1; } +static int hnbgw_mgw_setup(void) +{ + struct mgcp_client *mgcp_client_single; + unsigned int pool_members_initalized; + + /* Initialize MGW pool. This initalizes and connects all MGCP clients that are currently configured in + * the pool. Adding additional MGCP clients to the pool is possible but the user has to configure and + * (re)connect them manually from the VTY. */ + pool_members_initalized = mgcp_client_pool_connect(g_hnb_gw->mgw_pool); + if (pool_members_initalized) { + LOGP(DMGW, LOGL_NOTICE, + "MGW pool with %u pool members configured, (ignoring MGW configuration in VTY node 'mgcp').\n", + pool_members_initalized); + return 0; + } + + /* Initialize and connect a single MGCP client. This MGCP client will appear as the one and only pool + * member if there is no MGW pool configured. */ + LOGP(DMGW, LOGL_NOTICE, "No MGW pool configured, using MGW configuration in VTY node 'mgcp'\n"); + mgcp_client_single = mgcp_client_init(tall_hnb_ctx, g_hnb_gw->config.mgcp_client); + if (!mgcp_client_single) { + LOGP(DMGW, LOGL_ERROR, "MGW (single) client initalization failed\n"); + return -EINVAL; + } + if (mgcp_client_connect(mgcp_client_single)) { + LOGP(DMGW, LOGL_ERROR, "MGW (single) connect failed at (%s:%u)\n", + g_hnb_gw->config.mgcp_client->remote_addr, + g_hnb_gw->config.mgcp_client->remote_port); + return -EINVAL; + } + mgcp_client_pool_register_single(g_hnb_gw->mgw_pool, mgcp_client_single); + + return 0; +} + int main(int argc, char **argv) { struct osmo_stream_srv_link *srv; @@ -784,17 +820,8 @@ g_hnb_gw->iuh = srv; /* Initialize and connect MGCP client. */ - g_hnb_gw->mgcp_client = mgcp_client_init(tall_hnb_ctx, g_hnb_gw->config.mgcp_client); - if (!g_hnb_gw->mgcp_client) { - LOGP(DMGW, LOGL_ERROR, "MGW client initalization failed\n"); + if (hnbgw_mgw_setup() != 0) return -EINVAL; - } - if (mgcp_client_connect(g_hnb_gw->mgcp_client)) { - LOGP(DMGW, LOGL_ERROR, "MGW connect failed at (%s:%u)\n", - g_hnb_gw->config.mgcp_client->remote_addr, - g_hnb_gw->config.mgcp_client->remote_port); - return -EINVAL; - } #if ENABLE_PFCP /* If UPF is configured, set up PFCP socket and send Association Setup Request to UPF */
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/src/osmo-hnbgw/hnbgw_vty.c -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/src/osmo-hnbgw/hnbgw_vty.c
Changed
@@ -464,14 +464,6 @@ return CMD_SUCCESS; } -static int config_write_hnbgw_mgcp(struct vty *vty) -{ - vty_out(vty, " mgcp%s", VTY_NEWLINE); - mgcp_client_config_write(vty, " "); - - return CMD_SUCCESS; -} - #if ENABLE_PFCP static int config_write_hnbgw_pfcp(struct vty *vty) { @@ -521,7 +513,11 @@ install_element_ve(&show_talloc_cmd); install_element(HNBGW_NODE, &cfg_hnbgw_mgcp_cmd); - install_node(&mgcp_node, config_write_hnbgw_mgcp); + /* Deprecated: Old MGCP config without pooling support in MSC node: */ + install_node(&mgcp_node, NULL); + mgcp_client_vty_init(tall_hnb_ctx, MGCP_NODE, g_hnb_gw->config.mgcp_client); + + mgcp_client_pool_vty_init(HNBGW_NODE, MGW_NODE, " ", g_hnb_gw->mgw_pool); #if ENABLE_PFCP install_node(&pfcp_node, config_write_hnbgw_pfcp); @@ -531,6 +527,5 @@ install_element(PFCP_NODE, &cfg_pfcp_remote_addr_cmd); #endif - mgcp_client_vty_init(tall_hnb_ctx, MGCP_NODE, g_hnb_gw->config.mgcp_client); osmo_tdef_vty_groups_init(HNBGW_NODE, hnbgw_tdef_group); }
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/src/osmo-hnbgw/mgw_fsm.c -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/src/osmo-hnbgw/mgw_fsm.c
Changed
@@ -141,6 +141,7 @@ RANAP_RAB_AssignmentRequestIEs_t *ies; const char *epname; struct mgcp_conn_peer mgw_info; + struct mgcp_client *mgcp_client; int rc; LOGPFSML(fi, LOGL_DEBUG, "RAB-AssignmentRequest received, creating HNB side call-leg on MGW...\n"); @@ -172,9 +173,16 @@ mgw_info.codecs0 = CODEC_IUFP; mgw_info.codecs_len = 1; - epname = mgcp_client_rtpbridge_wildcard(map->hnb_ctx->gw->mgcp_client); + mgcp_client = mgcp_client_pool_get(map->hnb_ctx->gw->mgw_pool); + if (!mgcp_client) { + LOGPFSML(fi, LOGL_ERROR, + "cannot ensure MGW endpoint -- no MGW configured, check configuration!\n"); + osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0); + return; + } + epname = mgcp_client_rtpbridge_wildcard(mgcp_client); mgw_fsm_priv->mgcpc_ep = - osmo_mgcpc_ep_alloc(fi, MGW_EV_MGCP_TERM, map->hnb_ctx->gw->mgcp_client, mgw_fsm_T_defs, fi->id, "%s", epname); + osmo_mgcpc_ep_alloc(fi, MGW_EV_MGCP_TERM, mgcp_client, mgw_fsm_T_defs, fi->id, "%s", epname); mgw_fsm_priv->mgcpc_ep_ci_hnb = osmo_mgcpc_ep_ci_add(mgw_fsm_priv->mgcpc_ep, "to-HNB"); osmo_mgcpc_ep_ci_request(mgw_fsm_priv->mgcpc_ep_ci_hnb, MGCP_VERB_CRCX, &mgw_info, fi, MGW_EV_MGCP_OK, @@ -488,9 +496,13 @@ static void mgw_fsm_allstate_action(struct osmo_fsm_inst *fi, uint32_t event, void *data) { struct mgw_fsm_priv *mgw_fsm_priv = fi->priv; + struct mgcp_client *mgcp_client; switch (event) { case MGW_EV_MGCP_TERM: + /* Put MGCP client back into MGW pool */ + mgcp_client = osmo_mgcpc_ep_client(mgw_fsm_priv->mgcpc_ep); + mgcp_client_pool_put(mgcp_client); mgw_fsm_priv->mgcpc_ep = NULL; LOGPFSML(fi, LOGL_ERROR, "Media gateway failed\n"); osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0); @@ -547,6 +559,10 @@ struct hnbgw_context_map *map = mgw_fsm_priv->map; if (mgw_fsm_priv->mgcpc_ep) { + /* Put MGCP client back into MGW pool */ + struct mgcp_client *mgcp_client = osmo_mgcpc_ep_client(mgw_fsm_priv->mgcpc_ep); + mgcp_client_pool_put(mgcp_client); + osmo_mgcpc_ep_clear(mgw_fsm_priv->mgcpc_ep); mgw_fsm_priv->mgcpc_ep = NULL; }
View file
osmo-hnbgw_1.3.0.45.b9be.202210200002.tar.xz/tests/ranap_rab_ass/Makefile.am -> osmo-hnbgw_1.3.0.48.0e03.202210210002.tar.xz/tests/ranap_rab_ass/Makefile.am
Changed
@@ -11,6 +11,7 @@ $(LIBOSMOVTY_CFLAGS) \ $(LIBOSMORANAP_CFLAGS) \ $(LIBOSMOSIGTRAN_CFLAGS) \ + $(LIBOSMOMGCPCLIENT_CFLAGS) \ $(COVERAGE_CFLAGS) \ $(NULL) @@ -32,6 +33,7 @@ $(LIBOSMOVTY_LIBS) \ $(LIBOSMORANAP_LIBS) \ $(LIBOSMOSIGTRAN_LIBS) \ + $(LIBOSMOMGCPCLIENT_LIBS) \ $(COVERAGE_LDFLAGS) \ $(top_builddir)/src/osmo-hnbgw/ranap_rab_ass.o \ $(NULL)
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.