Kamailio-开源SIP软交换平台

中国第一个专注Kamailio SIP 软交换技术分享平台

用户工具

站点工具


statsc_statistics_collector_providing_reports_released

差别

这里会显示出您选择的修订版和当前版本之间的差别。

到此差别页面的链接

statsc_statistics_collector_providing_reports_released [2017/09/11 17:20] (当前版本)
james_zhu 创建
行 1: 行 1:
 +====== STATSC Module ======
  
 +==== Daniel-Constantin Mierla ====
 +
 +''<​[[miconda@gmail.com|miconda@gmail.com]]>''​
 +
 +=== Edited by ===
 +
 +==== Daniel-Constantin Mierla ====
 +
 +''<​[[miconda@gmail.com|miconda@gmail.com]]>''​
 +
 +Copyright © 2016 asipto.com
 +
 +----
 +
 +**Table of Contents**
 +
 +  * **1. Admin Guide** ​
 +    * **1. Overview** ​
 +    * **2. Dependencies** ​
 +      * **2.1. Kamailio Modules** ​
 +      * **2.2. External Libraries or Applications** ​
 +    * **3. Parameters** ​
 +      * **3.1. interval (int)** ​
 +      * **3.2. items (int)** ​
 +      * **3.3. track (str)** ​
 +    * **4. RPC Commands** ​
 +      * **4.1. statsc.exec** ​
 +
 +**List of Examples**
 +
 +  * **1.1. Set interval parameter** ​
 +  * **1.2. Set items parameter** ​
 +  * **1.3. Set track parameter** ​
 +
 +====== Chapter 1. Admin Guide ======
 +
 +**Table of Contents**
 +
 +  * **1. Overview** ​
 +  * **2. Dependencies** ​
 +    * **2.1. Kamailio Modules** ​
 +    * **2.2. External Libraries or Applications** ​
 +  * **3. Parameters** ​
 +    * **3.1. interval (int)** ​
 +    * **3.2. items (int)** ​
 +    * **3.3. track (str)** ​
 +  * **4. RPC Commands** ​
 +    * **4.1. statsc.exec** ​
 +
 +===== 1. Overview =====
 +
 +This module provides a statistics collector engine. It can track the values of various internal Kamailio statistics for a specific period of time, allowing to retrieve them or a report over them via RPC commands.
 +
 +===== 2. Dependencies =====
 +
 +==== 2.1. Kamailio Modules ====
 +
 +The following modules must be loaded along this module:
 +
 +  * various - for getting access to the statistics exported by these modules. ​
 +
 +==== 2.2. External Libraries or Applications ====
 +
 +The following libraries or applications must be installed before running Kamailio with this module loaded:
 +
 +  * none 
 +
 +===== 3. Parameters =====
 +
 +==== 3.1. interval (int) ====
 +
 +Timer interval when to record the value for statistics.
 +
 +Default value is 900 (15min).
 +
 +**Example 1.1. Set ''​interval''​ parameter**
 +
 +<​code>​
 +...
 +modparam("​statsc",​ "​interval",​ 300)
 +...
 +</​code>​
 +
 +\\ ==== 3.2. items (int) ====
 +
 +How many items to store for each statistic.
 +
 +Default value is 100.
 +
 +**Example 1.2. Set ''​items''​ parameter**
 +
 +<​code>​
 +...
 +modparam("​statsc",​ "​items",​ 200)
 +...
 +</​code>​
 +
 +\\ ==== 3.3. track (str) ====
 +
 +Specify the statistics to track. The parameter can be set many times and one value can speficy many statistics.
 +
 +The format is "​rname=sname",​ where the rname is the name for report and sname is internal Kamailio statistic name.
 +
 +Next statistics are tracked by default:
 +
 +  * shm.free - the internal statistc '​free_size'​ (from group '​shmem'​). ​
 +  * shm.used - the internal statistc '​used_size'​ (from group '​shmem'​). ​
 +  * shm.real_used - the internal statistc '​real_used_size'​ (from group '​shmem'​). ​
 +
 +Default value is ""​.
 +
 +**Example 1.3. Set ''​track''​ parameter**
 +
 +<​code>​
 +...
 +modparam("​statsc",​ "​track",​ "​req.received=rcv_requests"​)
 +modparam("​statsc",​ "​track",​ "​req.received=rcv_requests;​rpl.received=rcv_replies"​)
 +...
 +</​code>​
 +
 +\\ ===== 4. RPC Commands =====
 +
 +==== 4.1. statsc.exec ====
 +
 +Get the report of recorded statistics.
 +
 +Name: statsc.report
 +
 +Parameters:
 +
 +  * _type_ : “list”: list recorded values “diff”: show diff between recorded values ​
 +  * _name_: (optional) name of the statistic to show the report for. If missing or set to '​all',​ then the reports for all recorded statistics are done. 
 +  * _limit_: (optional) how many items to be included in the report ​
 +
 +Example:
 +
 +<​code>​
 +...
 +# prototype: kamcmd statsc.report _type_ _name_ _limit_
 +kamcmd statsc.report list
 +kamcmd statsc.report list all 10
 +kamcmd statsc.report diff
 +...
 +</​code>​
statsc_statistics_collector_providing_reports_released.txt · 最后更改: 2017/09/11 17:20 由 james_zhu