path: root/include
diff options
authorPau Espin Pedrol <pespin@sysmocom.de>2018-08-16 12:11:46 +0200
committerHarald Welte <laforge@gnumonks.org>2018-08-17 14:13:24 +0000
commit67f1d1edf49258f37b021357b00c25c79d973ae8 (patch)
treee5eeb04591705b209af4a5dcb0e93144187f8e01 /include
parent36abeadc7ba6ff15a3e01230195309f87f788f33 (diff)
gbproxy: Add VTY parameter: link stored-msgs-max-length
It was discovered in some prod setups that some TLLIs can maintain quite long queues of msgb in case its IMSI is not acquired and the tlli is not pruned due to link-list max-{age,length} being set to 0. As a result, the osmo-gpbroxy steadly increases the list size of maintained TLLIs, and some TLLI was found without IMSI catching already 1211 msgb. Let's allow setting a maxiumum length for the queue storing those msgb in a per TLLI base. If the limit is reached, oldest msgb are removed before adding a new one. Depends: libosmocore Change-Id I33b501e89a8f29e4aa121696bcbb13d4b83db40f Related: SYS#4297 Change-Id: I4473be8604f80302df03ffdd5a13280dc072f824
Diffstat (limited to 'include')
1 files changed, 5 insertions, 0 deletions
diff --git a/include/osmocom/sgsn/gb_proxy.h b/include/osmocom/sgsn/gb_proxy.h
index 70de3d71..16082fcd 100644
--- a/include/osmocom/sgsn/gb_proxy.h
+++ b/include/osmocom/sgsn/gb_proxy.h
@@ -105,8 +105,12 @@ struct gbproxy_config {
struct osmo_plmn_id core_plmn;
uint8_t* core_apn;
size_t core_apn_size;
+ /* If !0, Max age to consider a struct gbproxy_link_info as stale */
int tlli_max_age;
+ /* If !0, Max len of gbproxy_peer->list (list of struct gbproxy_link_info) */
int tlli_max_len;
+ /* If !0, Max len of gbproxy_link_info->stored_msgs (list of msgb) */
+ uint32_t stored_msgs_max_len;
/* Experimental config */
int patch_ptmsi;
@@ -171,6 +175,7 @@ struct gbproxy_link_info {
int imsi_acq_pending;
struct llist_head stored_msgs;
+ uint32_t stored_msgs_len;
unsigned vu_gen_tx_bss;
int is_deregistered;