You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
kamailio/modules/cfgt/README

160 lines
3.4 KiB

cfgt Module
Victor Seva
sipwise.com
Edited by
Victor Seva
<linuxmaniac@torreviejawireless.org>
Copyright © 2015 Victor Seva (sipwise.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. basedir (string)
3.2. mask (int)
3.3. callid_prefix (string)
4. Usage
List of Examples
1.1. Set cfgtrace parameter
1.2. Set mask parameter
1.3. Set callid_prefix 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. basedir (string)
3.2. mask (int)
3.3. callid_prefix (string)
4. Usage
1. Overview
This module provides a report of the way Kamailio SIP Server Platform
configuration has been executed as part of a unit test for different
SIP scenarios.
In order to identify different scenarios a prefix string should be used
inside the Call-ID header.
2. Dependencies
2.1. Kamailio Modules
2.2. External Libraries or Applications
2.1. Kamailio Modules
The following modules must be loaded before this module:
* None.
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. basedir (string)
3.2. mask (int)
3.3. callid_prefix (string)
3.1. basedir (string)
Control where the config reports should be stored. The dir must exist
and Kamailio SIP Server Platform must have permissions to write on it.
Default value is “/tmp”.
Example 1.1. Set cfgtrace parameter
...
modparam("cfgt", "basedir", "/var/run/kamailio/cfgtest")
...
3.2. mask (int)
mask - Control the type of vars it should display in the report:
* 1 - dump null values
* 2 - dump avp vars
* 4 - dump script vars
* 8 - dump xavp vars
* 16 - dump DP_OTHER vars
* 32 - dump ALL vars
Default value is “32” (ALL).
Example 1.2. Set mask parameter
...
# dump xavp(8) and avp(4) vars
modparam("cfgt", "mask", 12)
...
3.3. callid_prefix (string)
Prefix used to identify test scenario messages. Last char of the string
will be used as delimiter for the scenario ID. With parameter set to
“NGCP%” and Call-ID “NGCP%123%456” the scenario identified will be
“123”.
Default value is “NGCP%” (using “%” as delimiter).
Example 1.3. Set callid_prefix parameter
...
# using '%' as delimiter
modparam("cfgt", "callid_prefix", "TEST-ID%")
...
4. Usage
This module is used by the debugger module, so it must be loaded first.
To enable the generation of the reports, the debugger module must be
configured by setting the cfgtest parameter to "1".
Example of configuration:
...
#!ifdef WITH_DEBUG
loadmodule "cfgt.so"
loadmodule "debugger.so"
#!endif
...
#!ifdef WITH_DEBUG
# ----- cfgt params -----
modparam("cfgt", "basedir", "/tmp/kamailio/cfgtest")
modparam("cfgt", "callid_prefix", "TRACE-ID%")
modparam("cfgt", "mask", 32)
# ----- debugger params -----
modparam("debugger", "cfgtrace", 1)
modparam("debugger", "log_level_name", "exec")
modparam("debugger", "cfgtest", 1)
#!endif
...