fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/27409 )
Change subject: VTY: avoid printing duplicate rate_ctr/stat_item groups
......................................................................
VTY: avoid printing duplicate rate_ctr/stat_item groups
There can be more than one rate_ctr/stat_item groups of the same
class, registered with different index. For example, we may have
several BTS instances in osmo-bsc, and each instance would have
its own rate counter group with the matching index.
Command 'show asciidoc counters' relies on rate_ctr_for_each_group()
and osmo_stat_item_for_each_group(). These functions do iterate
over all registered rate_ctr/stat_item groups, including the ones
belonging to the same class but having different indexes. This is
why there can be duplicates in the output of this command.
A more sophisticated approach would be adding new for_each functions
ensuring that the given rate_ctr_group_handler_t is called only once
for groups of the same class. However, as a quick workaround we can
assume that there is always a group with index == 0, and avoid
printing groups with index != 0.
Change-Id: I1e66bc5720dfe255b480780aa9a0b76f4c0cc1fe
Fixes: OS#4848
---
M src/vty/stats_vty.c
1 file changed, 8 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/09/27409/1
diff --git a/src/vty/stats_vty.c b/src/vty/stats_vty.c
index a73fafb..299b341 100644
--- a/src/vty/stats_vty.c
+++ b/src/vty/stats_vty.c
@@ -500,6 +500,10 @@
{
struct vty *vty = sctx_;
+ /* Avoid printing duplicate groups */
+ if (ctrg->idx != 0)
+ return 0;
+
char *group_description = osmo_asciidoc_escape(ctrg->desc->group_description);
char *group_name_prefix = osmo_asciidoc_escape(ctrg->desc->group_name_prefix);
@@ -550,6 +554,10 @@
char *group_name_prefix = osmo_asciidoc_escape(statg->desc->group_name_prefix);
char *group_description = osmo_asciidoc_escape(statg->desc->group_description);
+ /* Avoid printing duplicate groups */
+ if (statg->idx != 0)
+ return 0;
+
struct vty *vty = sctx_;
vty_out(vty, "%s%s", group_description ? group_description : "" , VTY_NEWLINE);
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/27409
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I1e66bc5720dfe255b480780aa9a0b76f4c0cc1fe
Gerrit-Change-Number: 27409
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/27408 )
Change subject: Fix description of BTS_CTR_BTS_RSL_FAIL: s/OML/RSL/
......................................................................
Fix description of BTS_CTR_BTS_RSL_FAIL: s/OML/RSL/
Change-Id: Icc3e603b08ab81869955ffa5b16ddfb458e83c78
Related: OS#4848
---
M src/osmo-bsc/bts.c
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/08/27408/1
diff --git a/src/osmo-bsc/bts.c b/src/osmo-bsc/bts.c
index c3e87b3..d09aa48 100644
--- a/src/osmo-bsc/bts.c
+++ b/src/osmo-bsc/bts.c
@@ -984,7 +984,7 @@
"Received a TEI down on a OML link" },
[BTS_CTR_BTS_RSL_FAIL] = \
{ "rsl_fail",
- "Received a TEI down on a OML link" },
+ "Received a TEI down on a RSL link" },
[BTS_CTR_CODEC_AMR_F] = \
{ "codec:amr_f",
"Count the usage of AMR/F codec by channel mode requested" },
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/27408
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Icc3e603b08ab81869955ffa5b16ddfb458e83c78
Gerrit-Change-Number: 27408
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: neels, laforge, pespin, fixeria.
Hello Jenkins Builder, neels, laforge, pespin,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-bsc/+/16352
to look at the new patch set (#4).
Change subject: fix inp_sig_cb(): dispatch TS_EV_OML_DOWN to all transceivers
......................................................................
fix inp_sig_cb(): dispatch TS_EV_OML_DOWN to all transceivers
When running a multi-trx setup, upon stopping osmo-bts one can see:
DCHAN ERROR lchan_fsm.c:80 lchan(0-1-7-TCH_F-0)[0x612000010120]{UNUSED}:
(type=NONE) lchan allocation failed in state UNUSED: LCHAN_EV_TS_ERROR
DCHAN ERROR lchan_fsm.c:144 lchan(0-1-7-TCH_F-0)[0x612000010120]{UNUSED}:
(type=NONE) lchan activation failed
(lchan allocation failed in state UNUSED: LCHAN_EV_TS_ERROR)
These messages show up when the following conditions are met:
* BTS model speaks A-bis over IP (ip.access, e.g. nanoBTS), and
* BTS has more than one transceiver configured.
The problem is that unlike traditional E1 based BTS models, ip.access
ones have a single global A-bis/OML link for all transceivers. Thus
when it goes down, in inp_sig_cb() we need to notify all timeslots
*of all TRXes*, not just TRX0.
Change-Id: I3dc657ac5a2c5334747bd4f4db1a658acb323942
Fixes: OS#5479
---
M src/osmo-bsc/osmo_bsc_main.c
1 file changed, 6 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/52/16352/4
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/16352
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I3dc657ac5a2c5334747bd4f4db1a658acb323942
Gerrit-Change-Number: 16352
Gerrit-PatchSet: 4
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: neels, laforge, pespin, fixeria.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/16352 )
Change subject: fix inp_sig_cb(): dispatch TS_EV_OML_DOWN to all transceivers
......................................................................
Patch Set 3:
(1 comment)
This change is ready for review.
Patchset:
PS3:
> Patch Set 2:
>
> you need to be careful here.
> * abis/ip has one common OML link (TCP/IPA connection) and per-TRX RSL
> * other BTS models (e.g. Ericsson) have per-TRX OML and RSL links (LAPD datalinks)
Done. In the new patch I am broadcasting TS_EV_OML_DOWN to all transceivers only if is_ipaccess_bts(bts).
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/16352
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I3dc657ac5a2c5334747bd4f4db1a658acb323942
Gerrit-Change-Number: 16352
Gerrit-PatchSet: 3
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Sun, 06 Mar 2022 16:13:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: iedemam, neels, laforge.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/27081 )
Change subject: stats: new trackers for lchan life duration
......................................................................
Patch Set 14:
(1 comment)
Patchset:
PS14:
First of all, my C compiler version (probably newer) fails to compile with this patch applied, it probably hints you in the error:
"""
/osmo-bsc/src/osmo-bsc/lchan_fsm.c:490:34: error: 'active_ms_rate_ctr' may be used uninitialized in this function [-Werror=maybe-uninitialized]
490 | lchan->active_ms = (struct osmo_time_cc){
| ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
491 | .cfg = {
| ~~~~~~~~
492 | .gran_usec = 1*1000,
| ~~~~~~~~~~~~~~~~~~~~
493 | .forget_sum_usec = 1,
| ~~~~~~~~~~~~~~~~~~~~~
494 | .rate_ctr = active_ms_rate_ctr,
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
495 | .T_gran = -16,
| ~~~~~~~~~~~~~~
496 | .T_round_threshold = -17,
| ~~~~~~~~~~~~~~~~~~~~~~~~~
497 | .T_forget_sum = -18,
| ~~~~~~~~~~~~~~~~~~~~
498 | .T_defs = bts->network->T_defs,
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
499 | },
| ~~
500 | };
| ~
"""
If you want to run the tests locally:
$ make check
Then, you can see the output of the failing log under $buildir/tests/testsuite.dir/<number>/testsuite.log (or something like that, writing it by hard). Those are generated only for failing tests.
Since I think one of the VTY tests is failing too, you can run one of them for instance:
make -C tests/ vty-test VTY_TEST=power_ctrl.vty
And if you add U=u to the end, the vty file will be updated, you can use then git diff to see the difference with expected output.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/27081
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I1b0670c47cb5e0b7776eda89d1e71545ba0e3347
Gerrit-Change-Number: 27081
Gerrit-PatchSet: 14
Gerrit-Owner: iedemam <michael(a)kapsulate.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: iedemam <michael(a)kapsulate.com>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Fri, 04 Mar 2022 18:39:11 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: neels, laforge.
iedemam has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/27081 )
Change subject: stats: new trackers for lchan life duration
......................................................................
Patch Set 14:
(8 comments)
Patchset:
PS12:
> Thanks for the confidence boost. […]
Done
Patchset:
PS14:
Hi Neels,
The feedback was really helpful. I think the patch is looking more like what you have in mind now.
I am fighting a new handover test failure. Apologies for the silly question but how can I even see what is going on there? I see the expout and testsuite.log files but they don't offer any detail other than pointing out which test failed. Currently, I only know that test_max_ta.ho_vty is the failing sub-test. Obviously I'm missing something basic in the Osmo dev env / work cycle.
Many thanks again,
-Michael
File include/osmocom/bsc/gsm_data.h:
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/5d9f6d10_ab744b10
PS13, Line 771: struct osmo_time_cc timekeeper;
> here is your problem: the lchan is completely cleared out every time an lchan is activated / unused. […]
Thanks! I'm understanding the lifecycle better now.
File src/osmo-bsc/gsm_data.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/259bec1c_e6b62b68
PS13, Line 354: !&lchan->activate.timekeeper
> a) the address of a struct member is *always* non-NULL. […]
Done
File src/osmo-bsc/lchan_fsm.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/d202e612_9f1d93c4
PS13, Line 226: lchan->activate.timekeeper = (struct osmo_time_cc){
> also you probably want to do this only once during lchan allocation, i.e. […]
Done
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/65022e02_97ddbd57
PS13, Line 228: .gran_usec = 1*1000000,
> if you want milliseconds, 1000 is your factor. […]
Changed to milliseconds and changed forget_sum_usec to 1 to discard remainders.
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/2dc3c41c_a7ab9d1b
PS13, Line 237: /* TMP HACK: this fixes "make check" handover tests... */
> yeah because you re-init the lost state after lchan_reset().
Done
https://gerrit.osmocom.org/c/osmo-bsc/+/27081/comment/4d0227f9_b8723593
PS13, Line 558: if (&lchan->activate.timekeeper) {
> this condition is never false, as above. simply set the the flag without condition.
The check has been changed. I think it's still necessary as there isn't any sanity checking in osmo_time_cc_set_flag itself and not all lchans will have a timer attached.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/27081
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I1b0670c47cb5e0b7776eda89d1e71545ba0e3347
Gerrit-Change-Number: 27081
Gerrit-PatchSet: 14
Gerrit-Owner: iedemam <michael(a)kapsulate.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Fri, 04 Mar 2022 18:31:32 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: iedemam <michael(a)kapsulate.com>
Comment-In-Reply-To: neels <nhofmeyr(a)sysmocom.de>
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: comment
Attention is currently required from: iedemam.
Hello Jenkins Builder, neels, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-bsc/+/27081
to look at the new patch set (#14).
Change subject: stats: new trackers for lchan life duration
......................................................................
stats: new trackers for lchan life duration
This patch adds two stats which track cummulative lchan lifetime by
type TCH and SDCCH. These new counters will accomplish two things:
1) Provide a glanceable way to see if lchan durations look healthy. When
examining a site, short-lived (<5s) and long-lived (>30s) TCH lchans
are difficult to tell apart. If we only see short-lived TCH lchans,
there is most likely an RF or signaling problem to investigate. This
new counter will expose channel ages in the VTY output
2) Provide a more accurate count for Erlangs per site. Currently, we
are basing Erlangs on active TCH channel counts per stats period. This
method skews high very quickly. Each active TCH in that period
translates into the full 10s of activity. This counter should improve
accuracy by two orders of magnitude.
Change-Id: I1b0670c47cb5e0b7776eda89d1e71545ba0e3347
---
M include/osmocom/bsc/bts.h
M include/osmocom/bsc/gsm_data.h
M src/osmo-bsc/bts.c
M src/osmo-bsc/bts_trx_vty.c
M src/osmo-bsc/bts_vty.c
M src/osmo-bsc/gsm_data.c
M src/osmo-bsc/lchan_fsm.c
7 files changed, 94 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/81/27081/14
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/27081
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I1b0670c47cb5e0b7776eda89d1e71545ba0e3347
Gerrit-Change-Number: 27081
Gerrit-PatchSet: 14
Gerrit-Owner: iedemam <michael(a)kapsulate.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: iedemam <michael(a)kapsulate.com>
Gerrit-MessageType: newpatchset