All right, I think what I have learned is that the stats simply aren't
being collected for the SSRC in the endpoint that corresponds to my
"inb" (inbound) label — just the "outb" (outbound):

Here's the complete dump. Note in the MOS stats that the stats for this
SSRC are empty:

       222410830 => {}

I did note that there are two SSRCs for the more viable outbound stream,
one being RTP and the other being RTCP. The other direction also has an
RTP and an RTCP stream, but an SSRC only for one of them. 

See below:

-----8<-----8<-----8<-----8<-----8<-----
{
  created => '1518590122',
  'last signal' => '1518590124',
  tags => {
    sansay1987983383rdb28749 => {
      label => 'inb',
      medias => [
        {
          type => 'audio',
          protocol => 'RTP/AVP',
          index => '1',
          flags => [
            'initialized',
            'send',
            'recv'
          ],
          streams => [
            {
              stats => {
                packets => '1581',
                bytes => '271932',
                errors => '0'
              },
              endpoint => {
                address => '<ITSP>',
                family => 'IPv4',
                port => '38930'
              },
              'advertised endpoint' => {
                address => '<ITSP>',
                port => '38930',
                family => 'IPv4'
              },
              'last packet' => '1518590156',
              'local port' => '9078',
              flags => [
                'RTP',
                'filled',
                'confirmed',
                'kernelized'
              ],
              SSRC => '222410830'
            },
            {
              stats => {
                errors => '0',
                bytes => '0',
                packets => '0'
              },
              'advertised endpoint' => {
                family => 'IPv4',
                port => '38931',
                address => '<ITSP>'
              },
              endpoint => {
                family => 'IPv4',
                port => '38931',
                address => '<ITSP>'
              },
              'last packet' => '1518590122',
              'local port' => '9079',
              flags => [
                'RTCP',
                'filled'
              ]
            }
          ]
        }
      ],
      created => '1518590122',
      tag => 'sansay1987983383rdb28749',
      'in dialogue with' => '9C62E1A4-89AFCE63'
    },
    '9C62E1A4-89AFCE63' => {
      'in dialogue with' => 'sansay1987983383rdb28749',
      tag => '9C62E1A4-89AFCE63',
      created => '1518590122',
      medias => [
        {
          protocol => 'RTP/AVP',
          type => 'audio',
          streams => [
            {
              SSRC => '4088772468',
              flags => [
                'RTP',
                'filled',
                'confirmed',
                'kernelized'
              ],
              'local port' => '9088',
              'last packet' => '1518590156',
              endpoint => {
                family => 'IPv4',
                port => '2250',
                address => '<home IP phone>'
              },
              'advertised endpoint' => {
                address => '172.30.105.251',
                family => 'IPv4',
                port => '2250'
              },
              stats => {
                errors => '0',
                bytes => '270212',
                packets => '1571'
              }
            },
            {
              SSRC => '4088772468',
              'last packet' => '1518590152',
              'local port' => '9089',
              flags => [
                'RTCP',
                'filled',
                'confirmed'
              ],
              endpoint => {
                family => 'IPv4',
                port => '2251',
                address => '<home IP phone>'
              },
              'advertised endpoint' => {
                port => '2251',
                family => 'IPv4',
                address => '172.30.105.251'
              },
              stats => {
                errors => '0',
                bytes => '504',
                packets => '6'
              }
            }
          ],
          index => '1',
          flags => [
            'initialized',
            'send',
            'recv'
          ]
        }
      ],
      label => 'outb'
    }
  },
  created_us => '624757',
  result => 'ok',
  SSRC => {
    '4088772468' => {
      'highest MOS' => {
        'packet loss' => '0',
        'round-trip time' => '0',
        jitter => '2',
        'reported at' => '1518590127',
        MOS => '44'
      },
      'lowest MOS' => {
        'packet loss' => '0',
        'round-trip time' => '0',
        'reported at' => '1518590127',
        jitter => '2',
        MOS => '44'
      },
      'average MOS' => {
        MOS => '44',
        jitter => '2',
        samples => '6',
        'round-trip time' => '0',
        'packet loss' => '0'
      },
      'MOS progression' => {
        interval => '2',
        entries => [
          {
            'round-trip time' => '0',
            'packet loss' => '0',
            'reported at' => '1518590127',
            MOS => '44',
            jitter => '2'
          },
          {
            'packet loss' => '0',
            'round-trip time' => '0',
            'reported at' => '1518590132',
            MOS => '44',
            jitter => '3'
          },
          {
            jitter => '0',
            'reported at' => '1518590137',
            MOS => '44',
            'round-trip time' => '0',
            'packet loss' => '0'
          },
          {
            'reported at' => '1518590142',
            MOS => '44',
            jitter => '2',
            'packet loss' => '0',
            'round-trip time' => '0'
          },
          {
            'round-trip time' => '0',
            'packet loss' => '0',
            'reported at' => '1518590147',
            MOS => '44',
            jitter => '4'
          },
          {
            'round-trip time' => '0',
            'packet loss' => '0',
            'reported at' => '1518590152',
            jitter => '3',
            MOS => '44'
          }
        ]
      }
    },
    222410830 => {}
  },
  totals => {
    RTCP => {
      errors => '0',
      bytes => '504',
      packets => '6'
    },
    RTP => {
      errors => '0',
      bytes => '542144',
      packets => '3152'
    }
  }
}
----->8----->8----->8----->8----->8-----

-- Alex

On Wed, Feb 14, 2018 at 12:15:29AM -0500, Alex Balashov wrote:

> Well, both the 'query' command and final logging confirm that the labels
> are correct for the respective from-tags:
> 
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: Final packet stats:
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --- Tag 'F00E08C8-2966E6E7' (label 
> 'outbound'), created 0:34 ago for branch '', in dialogue with 
> 'sansay1987955648rdb39660'
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: ------ Media #1 (audio over RTP/AVP) 
> using PCMU/8000
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --------- Port    4.5.6.7:8118  <>   
> 47.39.154.156:2234 , SSRC 4149441922, 112 p, 19264 b, 0 e, 30 ts
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --------- Port    4.5.6.7:8119  <>   
> 47.39.154.156:2235  (RTCP), SSRC 4149441922, 1 p, 84 b, 0 e, 30 ts
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --- Tag 'sansay1987955648rdb39660' (label 
> 'inbound'), created 0:34 ago for branch '', in dialogue with 
> 'F00E08C8-2966E6E7'
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: ------ Media #1 (audio over RTP/AVP) 
> using PCMU/8000
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --------- Port    4.5.6.7:8098  <>   
> 8.9.10.11:63736, SSRC 790287681, 438 p, 75336 b, 0 e, 24 ts
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --------- Port    4.5.6.7:8099  <>   
> 8.9.10.11:63737 (RTCP), SSRC 0, 0 p, 0 b, 0 e, 34 ts
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: --- SSRC 4149441922
> Feb 14 05:10:32 evaristesys-legacy rtpengine[7354]: INFO: 
> [c6fa30199831602c397d627d5a2662d3]: ------ Average MOS 4.4, lowest MOS 4.4 
> (at 0:03), highest MOS 4.4 (at 0:03)
> 
> But for some reason, the "B" PVs just aren't being populated, even
> though I use the labels: 
> 
>       if(check_route_param("proxy_media=yes")) {
>               $avp(rtpengine_a_label) = 'outbound';
>               $avp(rtpengine_b_label) = 'inbound';
> 
>               rtpengine_delete();
> 
>               route(LOG_RTPENGINE_STATS);
>       }
> 
> And have the PVs referenced:
> 
>       modparam("rtpengine", "mos_A_label_pv", "$avp(rtpengine_a_label)")
>       modparam("rtpengine", "mos_B_label_pv", "$avp(rtpengine_b_label)")
> 
> This is using rtpengine:mr5.5.3 and kamailio:5.1 latest clone.
> 
> -- Alex
> 
> On Tue, Feb 13, 2018 at 09:39:59PM -0500, Alex Balashov wrote:
> 
> > Ah, okay, coercing it to use Convert::Bencode (for lack of CentOS
> > rh524-perl Bencode module) was not a productive thing to do. :-)
> > 
> > On Tue, Feb 13, 2018 at 09:29:49PM -0500, Alex Balashov wrote:
> > 
> > > After I finally got the Perl client to work, unfortunately it raised
> > > more questions than answers. :-)
> > > 
> > > [root@evaristesys-legacy rtpengine]# perl utils/rtpengine-ng-client list
> > > Result dictionary:
> > > -----8<-----8<-----8<-----8<-----8<-----
> > > {
> > >   result => 'ok',
> > >   calls => [
> > >     '835853f6cbf2a03ac8329bb92b0d1c8a'
> > >   ]
> > > }
> > > ----->8----->8----->8----->8----->8-----
> > > 
> > > [root@evaristesys-legacy rtpengine]# perl utils/rtpengine-ng-client query 
> > > --call-id=835853f6cbf2a03ac8329bb92b0d1c8a
> > > Error reason: "Unknown call-id" at 
> > > /opt/rh/rh-perl524/root/usr/share/perl5/NGCP/Rtpengine.pm line 43.
> > > 
> > > Feb 14 02:28:38 evaristesys-legacy rtpengine[29025]: WARNING: 
> > > [SCALAR(0x855cd8)]: Protocol error in packet from 127.0.0.1:58000: 
> > > Unknown call-id [d7:call-id16:SCALAR(0x855cd8)7:command5:querye]
> > > 
> > > -- Alex
> > > 
> > > On Tue, Feb 13, 2018 at 07:34:30PM -0500, Richard Fuchs wrote:
> > > 
> > > > On 2018-02-13 07:32 PM, Alex Balashov wrote:
> > > > > Hi Richard,
> > > > > 
> > > > > On Tue, Feb 13, 2018 at 06:34:53PM -0500, Richard Fuchs wrote:
> > > > > 
> > > > > > It's the min, max, and average between the two call legs (and other
> > > > > > contributing sources that may have been involved in the call).
> > > > > When you say "between", do you mean the average of the values of the 
> > > > > two
> > > > > respective legs?
> > > > 
> > > > The average is the average between the two, the min is the min between 
> > > > the
> > > > two, and the max is the max between the two.
> > > > 
> > > > Cheers
> > > > 
> > > > _______________________________________________
> > > > Kamailio (SER) - Users Mailing List
> > > > sr-users@lists.kamailio.org
> > > > https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
> > > 
> > > -- 
> > > Alex Balashov | Principal | Evariste Systems LLC
> > > 
> > > Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
> > > Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
> > > 
> > > _______________________________________________
> > > Kamailio (SER) - Users Mailing List
> > > sr-users@lists.kamailio.org
> > > https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
> > 
> > -- 
> > Alex Balashov | Principal | Evariste Systems LLC
> > 
> > Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
> > Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
> > 
> > _______________________________________________
> > Kamailio (SER) - Users Mailing List
> > sr-users@lists.kamailio.org
> > https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
> 
> -- 
> Alex Balashov | Principal | Evariste Systems LLC
> 
> Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
> Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
> 
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

-- 
Alex Balashov | Principal | Evariste Systems LLC

Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

Reply via email to