<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Probably is like 10 years since I deployed snmpstats module for
kamailio, as far as I can remember, SNMP works with static
mappings of MIBs, probably each new metric exported by Kamailio
needs C code and a defined MIB value. So right now only what was
coded in snmpstats is available.<br>
</p>
<p>On the other hand, the new counters/stats should also be
available via rpc stats.fetchn (or its variants). So you can pull
them from kamailio via jsonrpc (or xmlrpc) and push them to your
monitoring system using a converting script -- typically such
scripts are easy to build with python, I guess python has
libraries for snmp, if you need to go this way.</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div class="moz-cite-prefix">On 06.04.21 12:14, Marat Gareev wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAGBFc1U_K9ByzKYdLnKHPOq+W9nrv+=Un4yahZ=tweu1ZTD5JA@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">It looks like custom metrics are only available
in xHTTP_PROM module.</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">вт, 6 апр. 2021 г. в 10:25,
Daniel-Constantin Mierla <<a
href="mailto:miconda@gmail.com" moz-do-not-send="true">miconda@gmail.com</a>>:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div>
<p>Just for sake of completion of the knowledge here in the
mailing list archive: do custom counters become available
in snmpstats?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div>On 30.03.21 13:55, Marat Gareev wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">Thanks, Daniel.
<div><br>
</div>
<div>In this case I'll define a custom counter.</div>
<div><br>
</div>
<div>Marat</div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">вт, 30 мар. 2021 г. в
14:06, Daniel-Constantin Mierla <<a
href="mailto:miconda@gmail.com" target="_blank"
moz-do-not-send="true">miconda@gmail.com</a>>:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px
0px 0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div>
<p>Hello,</p>
<p>the statistics from the core are only for
stateless forwarding.</p>
<p>You can check if tmx module offers the numbers
you are looking for (load the module and check the
output of 'kamctl stats').</p>
<p>If not, you can also define new statistics in the
config with the module:</p>
<p> * <a
href="https://www.kamailio.org/docs/modules/stable/modules/statistics.html"
target="_blank" moz-do-not-send="true">https://www.kamailio.org/docs/modules/stable/modules/statistics.html</a></p>
<p>An you can incremented when you use t_relay().
Alternative, you can use onsend_route for
requests.</p>
<p>On the other hand, I do not use snmp module to
see if there is any option to export
config-defined stats to snmp.</p>
<p>Firthermore, maybe you can switch to statsd
module for pushing out the stats or pull them via
rpc.<br>
</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div>On 25.03.21 16:45, Marat Gareev wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">Hello,
<div><br>
</div>
<div>I'm trying to get the total number of SIP
request messages sent out by the proxy with <b>kamailioSIPSummaryOutRequest</b> scalar.</div>
<div>But the value doesn't increase if I use
t_relay() (with forward() counter works).</div>
<div><br>
</div>
<div>Related <a
href="https://opensips.org/pipermail/users/2012-December/024045.html"
target="_blank" moz-do-not-send="true">thread</a>.</div>
<div><br>
</div>
<div>Is there another SNMP counter which
contains a total number of OUT requests?</div>
<div><br>
</div>
<div>Marat</div>
</div>
<br>
<fieldset></fieldset>
<pre>_______________________________________________
Kamailio (SER) - Users Mailing List
<a href="mailto:sr-users@lists.kamailio.org" target="_blank" moz-do-not-send="true">sr-users@lists.kamailio.org</a>
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" target="_blank" moz-do-not-send="true">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<pre cols="72">--
Daniel-Constantin Mierla -- <a href="http://www.asipto.com" target="_blank" moz-do-not-send="true">www.asipto.com</a>
<a href="http://www.twitter.com/miconda" target="_blank" moz-do-not-send="true">www.twitter.com/miconda</a> -- <a href="http://www.linkedin.com/in/miconda" target="_blank" moz-do-not-send="true">www.linkedin.com/in/miconda</a>
Funding: <a href="https://www.paypal.me/dcmierla" target="_blank" moz-do-not-send="true">https://www.paypal.me/dcmierla</a></pre>
</div>
</blockquote>
</div>
</blockquote>
<pre cols="72">--
Daniel-Constantin Mierla -- <a href="http://www.asipto.com" target="_blank" moz-do-not-send="true">www.asipto.com</a>
<a href="http://www.twitter.com/miconda" target="_blank" moz-do-not-send="true">www.twitter.com/miconda</a> -- <a href="http://www.linkedin.com/in/miconda" target="_blank" moz-do-not-send="true">www.linkedin.com/in/miconda</a>
Funding: <a href="https://www.paypal.me/dcmierla" target="_blank" moz-do-not-send="true">https://www.paypal.me/dcmierla</a></pre>
</div>
</blockquote>
</div>
</blockquote>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a>
<a class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Funding: <a class="moz-txt-link-freetext" href="https://www.paypal.me/dcmierla">https://www.paypal.me/dcmierla</a></pre>
</body>
</html>