<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
I'm currently using version 4.4.2 and am having trouble trying to reset the statistics in the TMX module. According to its documentation, all statistics except
<span class="quote">“<span class="quote">inuse_transactions</span>”</span> can be reset.
<br>
<div style="color: rgb(0, 0, 0);">
<div>
<div id="divtagdefaultwrapper" style="font-size:12pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif">
<p><br>
</p>
<p>Checking the tmx_mod.c files for the statistics definition, I saw that the <span>
STAT_NO_RESET</span> flag wasn't used for any statistic listed there (which seems odd because I think it should have been set for the
<i>inuse_transactions</i> statistic):</p>
<p><br>
</p>
<div><i>static stat_export_t mod_stats[] = {<br>
        {"UAS_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_uas_trans   },<br>
        {"UAC_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_uac_trans   },<br>
        {"2xx_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_trans_2xx   },<br>
        {"3xx_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_trans_3xx   },<br>
        {"4xx_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_trans_4xx   },<br>
        {"5xx_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_trans_5xx   },<br>
        {"6xx_transactions",    STAT_IS_FUNC, (stat_var**)tmx_stats_trans_6xx   },<br>
        {"inuse_transactions",  STAT_IS_FUNC, (stat_var**)tmx_stats_trans_inuse },<br>
        {"active_transactions", STAT_IS_FUNC, (stat_var**)tmx_stats_trans_active},<br>
        {"rpl_received",        STAT_IS_FUNC, (stat_var**)tmx_stats_rcv_rpls    },<br>
        {"rpl_absorbed",        STAT_IS_FUNC, (stat_var**)tmx_stats_abs_rpls    },<br>
        {"rpl_generated",       STAT_IS_FUNC, (stat_var**)tmx_stats_rld_loc_rpls},<br>
        {"rpl_relayed",         STAT_IS_FUNC, (stat_var**)tmx_stats_rld_rcv_rpls},<br>
        {"rpl_sent",            STAT_IS_FUNC, (stat_var**)tmx_stats_rld_tot_rpls},<br>
        {0, 0, 0}<br>
};</i><br>
<br>
</div>
<p></p>
<p>All seems ok, but when I try to reset the stats, the command simply doesn't work. The values remain unaltered. The
<i>clear </i>command doesn't work either, it just returns the current values.</p>
<p><br>
</p>
<p>Can anyone help me trying to debug this problem, I'm very new to Kamailio and its code, and don't have a good understanding of how it the statistics gathering/reset works.</p>
<p><br>
</p>
<p>Thanks.</p>
<p><br>
</p>
<p>Atila Moretto<br>
</p>
</div>
</div>
</div>
</div>
</body>
</html>