Hi Omar,
On Tue, Jul 11, 2017 at 08:01:37AM -0700, Omar Ramadan wrote:
1) Query(or push) CDRs for active data sessions
push (aka CTRL TRAP) is not implemented at this point.
Getting the counters should be possible, given that we have
* a complete set of 'rate_ctr' for the SGSN:
** number of {packets,bytes} {in,out} for each MM context (Subscriber)
** number of {packets,bytes} {in,out} for each PDP context
* libosmocore contains a generic + automatic exposure of all rate_ctr
via CTRL, see libosmocore/src/ctrl/control_if.c get_rate_ctr() & Co
The format shoudl be something like
"rate_ctr.{abs,per_sec,per_min,per_hour,per_day}.GROUP.IDX.NAME"
where GROUP is sgsn.pdpctx + IDX=NSAPI with NAME in
* udata.packets.in
* udata.packets.out
* udata.bytes.in
* udata.bytes.out
or where GROUP is sgsn.mmctx + IDX=TLLI and NAME in
* udata.packets.in
* udata.packets.out
* udata.bytes.in
* udata.bytes.out
Now the problem is that the group name contains a '.', and this is the
same character used for tokenizing the individual parts of the CTRL
interface command.
So what we have here is a nicely defined generic architecture for (rate)
counters, and an equally generic way to export them - but they will fail
in this specific example based on bad choice of naming, and no
verification if invalid names (prefixes) are registered.
As a result, a lot of counters that we previously assumed to be
exported automatically are thus currently unreachable from the CTRL
interface :(
I've created
https://osmocom.org/issues/2362 for this. Once that is
fixed, the mechanism should work as expected.
Regards,
Harald
--
- Harald Welte <laforge(a)gnumonks.org>
http://laforge.gnumonks.org/
============================================================================
"Privacy in residential applications is a desirable marketing option."
(ETSI EN 300 175-7 Ch. A6)