Documentation |
Documentation.Interface-CoreMI-3-6 HistoryHide minor edits - Show changes to markup June 21, 2023, at 08:21 PM
by
- Changed lines 171-172 from:
Get or set the level of the extra filtering applied to log messages for a specific logging "consumer"(stderror or syslog). If log_level_filter is not given, the command will print the current level filter for the specified consumer. to:
Get or set the level of the extra filtering applied to log messages for a specific logging "consumer"(stderror, syslog or event). If log_level_filter is not given, the command will print the current level filter for the specified consumer. Changed line 174 from:
to:
Changed lines 189-190 from:
Get or set the mute state (printing enabled/disabled) of a specific logging "consumer"(stderror or syslog). If mute_state is not given, the command will print the current mute state for the specified consumer. to:
Get or set the mute state (printing enabled/disabled) of a specific logging "consumer"(stderror, syslog or event). If mute_state is not given, the command will print the current mute state for the specified consumer. Changed line 192 from:
to:
May 17, 2023, at 12:23 AM
by
- Added lines 167-202:
@] log_level_filter 🔗 consumer [level_filter]Get or set the level of the extra filtering applied to log messages for a specific logging "consumer"(stderror or syslog). If log_level_filter is not given, the command will print the current level filter for the specified consumer. Arguments:
Examples of usage: # opensips-cli -x mi log_level_filter stderror { "Log level filter": 3 } # opensips-cli -x mi log_level_filter stderror 1 "OK" log_mute_state 🔗 consumer [mute_state]Get or set the mute state (printing enabled/disabled) of a specific logging "consumer"(stderror or syslog). If mute_state is not given, the command will print the current mute state for the specified consumer. Arguments:
Examples of usage: [@ # opensips-cli -x mi log_mute_state syslog { "mmute state": 0 } # opensips-cli -x mi log_mute_state syslog 1 "OK" May 15, 2023, at 02:39 PM
by
- Changed lines 720-721 from:
"expire": 1100 to:
"expire": 1100, "ttl": 1046 April 10, 2023, at 02:09 PM
by
- Added lines 577-587:
reset_all_statistics 🔗Reset (to zero) the value of all statistic variables that can be reset. Note that not all variables allow reset (depending of the nature of the information they carry - example "shmem:used_size"). Examples of usage: # opensips-cli -x mi reset_all_statistics December 08, 2022, at 10:30 AM
by
- Changed line 662 from:
to:
Changed lines 666-667 from:
# opensips-cli -x mi raise_event E_PIKE_BLOCKED 127.0.0.1 to:
# opensips-cli -x mi raise_event E_PIKE_BLOCKED 127.0.0.1 # array mode # opensips-cli -x -- mi -j raise_event event=E_PIKE_BLOCKED params='{"ip":"127.0.0.1"}' # json mode October 28, 2022, at 04:40 PM
by
- Changed lines 47-48 from:
Arguments: none\\ to:
Arguments:
October 28, 2022, at 04:25 PM
by
- Changed lines 55-60 from:
list_tcp_conns 🔗The command lists all ongoing TCP/TLS connection from OpenSIPS. to:
check_blacklists 🔗The command returns all the blacklists that match an proto:IP:port+pattern.
Output: an array with the names of each blacklist that matched. Changed lines 67-68 from:
# opensips-cli -x mi list_tcp_conns to:
# opensips-cli -x mi check_blacklists 127.0.0.1 # opensips-cli -x mi check_blacklists udp 127.0.0.1 5060 Changed lines 71-74 from:
log_level 🔗 [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process.\\ to:
check_blacklist 🔗The command check whether a proto:IP:port+pattern matches any rule of a blacklist.\\ Changed lines 75-77 from:
to:
Output: an object containing the first rule that matched, or an error if nothing matched. Changed lines 84-112 from:
# opensips-cli -x mi log_level { "Processes": [ { "PID": 10670, "Log level": 2, "Type": "attendant" }, { "PID": 10672, "Log level": 3, "Type": "MI FIFO" }, { "PID": 10673, "Log level": 1, "Type": "SIP receiver udp:193.668.3.633:5060" }, ] } # opensipsctl fifo log_level 1 { "New global log level": 1 } # opensipsctl fifo log_level 4 10670 { "Log level": 1 } to:
# opensips-cli -x mi check_blacklist net_dynamic 127.0.0.1 # opensips-cli -x mi check_blacklists net_dynamic udp 127.0.0.1 5060 Changed lines 88-94 from:
ps 🔗The command will list all all OpenSIPS processes, along with type and description. to:
add_blacklist_rule 🔗Adds a rule to a non-readonly blacklist.
Output: success or failed object. Changed lines 99-133 from:
# opensips-cli -x mi ps { "Processes": [ { "ID": 0, "PID": 27271, "Type": "attendant" }, { "ID": 1, "PID": 27272, "Type": "MI FIFO" }, { "ID": 2, "PID": 27273, "Type": "time_keeper" }, { "ID": 3, "PID": 27274, "Type": "timer" }, { "ID": 4, "PID": 27275, "Type": "SIP receiver udp:127.0.0.1:5060" }, { "ID": 5, "PID": 27276, "Type": "Timer handler" } ] } to:
# opensips-cli -x mi add_blacklist_rule net_dynamic '!tcp,127.0.0.1,5060' # opensips-cli -x mi add_blacklist_rule net_dynamic '!tcp,127.0.0.1,5060' 3600 Changed lines 103-109 from:
pwd 🔗Prints the working directory of OpenSIPS instance. to:
del_blacklist_rule 🔗Removes a rule from a non-readonly blacklist.
Output: success or failed object. Changed lines 113-116 from:
# opensips-cli -x mi pwd { "WD": "/" } to:
# opensips-cli -x mi del_blacklist_rule net_dynamic '!tcp,127.0.0.1,5060' Changed lines 116-119 from:
reload_routes 🔗Triggers the reload of the routing block (the routes) from the script during the runtime. to:
Changed lines 120-134 from:
Output: none Please note that there are some limitations of when a reload is possible or not. Depending on the initial configuration of your modules, the reload may be rejected as the usage of the functions in the new script is not compatible with the original module setting and initialization. sr_get_status 🔗The MI equivalent of the sr_check_status() script function - to get the status of an 'status/report' identifier/group. Arguments: a mandatory group and optional identifier, see the parameters of the sr_check_status() script function. Output: the readiness, the status and details of the identifier/group (see the aggregation note for the return code of the sr_check_status() script function to:
Output: an array with one object per connection with the following attributes : ID, type, state, source, destination, lifetime, alias port. Changed lines 124-138 from:
{ "Readiness": true, "Status": 1, "Details": "running" }
{ "Readiness": true, "Status": 1, "Details": "aggregated" } to:
# opensips-cli -x mi list_tcp_conns Changed lines 127-134 from:
sr_list_status 🔗Command to list the status of the identifiers within one or all 'status/report' groups. Arguments: an optional 'status/report' group, see the sr_check_status() script function for more details. Output: the readiness, the status and details for all the identifiers within the requested group, or within all defined/registered groups. to:
log_level 🔗 [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process.
Changed lines 137-138 from:
[ to:
# opensips-cli -x mi log_level Changed lines 139-140 from:
"Name": "drouting", "Identifiers": [ to:
"Processes": [ Changed lines 141-150 from:
"Name": "Default", "Readiness": true, "Status": 1, "Details": "data available" } ] }, { "Name": "test", "Identifiers": [ to:
"PID": 10670, "Log level": 2, "Type": "attendant" }, Changed lines 146-149 from:
"Name": "main", "Readiness": true, "Status": 1 } to:
"PID": 10672, "Log level": 3, "Type": "MI FIFO" }, { "PID": 10673, "Log level": 1, "Type": "SIP receiver udp:193.668.3.633:5060" }, Changed lines 156-157 from:
}, to:
} # opensipsctl fifo log_level 1 Changed lines 159-167 from:
"Name": "core", "Identifiers": [ { "Name": "main", "Readiness": true, "Status": 1, "Details": "running" } ] to:
"New global log level": 1 Changed lines 161-165 from:
] to:
# opensipsctl fifo log_level 4 10670 { "Log level": 1 } Changed lines 168-176 from:
sr_list_reports 🔗Command to list the full set of reports (logs) collected by 'status/report' identifiers. Arguments:
Output: the reports/logs for the requested identifiers, or for all identifiers within the groups. to:
ps 🔗The command will list all all OpenSIPS processes, along with type and description. Changed lines 177-178 from:
[ to:
# opensips-cli -x mi ps { "Processes": [ { "ID": 0, "PID": 27271, "Type": "attendant" }, { "ID": 1, "PID": 27272, "Type": "MI FIFO" }, { "ID": 2, "PID": 27273, "Type": "time_keeper" }, { "ID": 3, "PID": 27274, "Type": "timer" }, { "ID": 4, "PID": 27275, "Type": "SIP receiver udp:127.0.0.1:5060" }, { "ID": 5, "PID": 27276, "Type": "Timer handler" } ] } @]
pwd 🔗Prints the working directory of OpenSIPS instance. Examples of usage: [@ # opensips-cli -x mi pwd Changed lines 225-276 from:
"Name": "drouting", "Identifiers": [ { "Name": "Default", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "starting DB data loading" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "DB data loading successfully completed" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "2 gateways loaded (0 discarded), 2 carriers loaded (0 discarded), 1 rules loaded (0 discarded)" } ] } ] }, { "Name": "test", "Identifiers": [ { "Name": "main", "Reports": [] } ] }, { "Name": "core", "Identifiers": [ { "Name": "main", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initializing" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initialization completed, ready now" } ] } ] to:
"WD": "/" Deleted line 226:
] Changed lines 230-237 from:
sr_list_identifiers 🔗Command to list all the existing identifiers in OpenSIPS or only from a certain group. Arguments:
Output: an array of groups, each group being an array of identifiers . to:
reload_routes 🔗Triggers the reload of the routing block (the routes) from the script during the runtime.
Arguments: none Please note that there are some limitations of when a reload is possible or not. Depending on the initial configuration of your modules, the reload may be rejected as the usage of the functions in the new script is not compatible with the original module setting and initialization.
sr_get_status 🔗The MI equivalent of the sr_check_status() script function - to get the status of an 'status/report' identifier/group. Arguments: a mandatory group and optional identifier, see the parameters of the sr_check_status() script function. Output: the readiness, the status and details of the identifier/group (see the aggregation note for the return code of the sr_check_status() script function Changed lines 251-278 from:
to:
{ "Readiness": true, "Status": 1, "Details": "running" }
{ "Readiness": true, "Status": 1, "Details": "aggregated" } @]
sr_list_status 🔗Command to list the status of the identifiers within one or all 'status/report' groups. Arguments: an optional 'status/report' group, see the sr_check_status() script function for more details. Output: the readiness, the status and details for all the identifiers within the requested group, or within all defined/registered groups. Examples of usage: [@
Changed line 281 from:
"Group": "clusterer", to:
"Name": "drouting", Changed lines 283-288 from:
"sharing_tags" to:
{ "Name": "Default", "Readiness": true, "Status": 1, "Details": "data available" } Changed line 292 from:
"Group": "dispatcher", to:
"Name": "test", Changed lines 294-295 from:
"default;events", "default" to:
{ "Name": "main", "Readiness": true, "Status": 1 } Changed line 302 from:
"Group": "drouting", to:
"Name": "core", Changed lines 304-305 from:
"Default;events", "Default" to:
{ "Name": "main", "Readiness": true, "Status": 1, "Details": "running" } Deleted lines 310-321:
}, { "Group": "dialplan", "Identifiers": [ "default" ] }, { "Group": "core", "Identifiers": [ "main" ] Deleted lines 312-319:
{ "Group": "drouting", "Identifiers": [ "Default;events", "Default" ] } Changed lines 315-322 from:
uptime 🔗Prints various time information about OpenSIPS - when it started to run, for how long it runs. to:
sr_list_reports 🔗Command to list the full set of reports (logs) collected by 'status/report' identifiers. Arguments:
Output: the reports/logs for the requested identifiers, or for all identifiers within the groups. Changed lines 326-358 from:
# opensips-cli -x mi uptime { "Now": "Mon Jul 21 17:41:03 2008", "Up since": "Mon Jul 21 17:36:33 2008", "Up time": "270 [sec]" } @] version 🔗Prints the version string of a runningOpenSIPS. Examples of usage: # opensips-cli -x mi version { "Server": "OpenSIPS (3.6.0-dev (x86_64/linux))" } which 🔗Prints all available MI commands from the queried OpenSIPSinstance. Examples of usage: [@ # opensips-cli -x mi which to:
Deleted lines 327-364:
"get_statistics", "list_statistics", "reset_statistics", "uptime", "version", "pwd", "arg", "which", "ps", "kill", "log_level", "xlog_level", "shm_check", "cache_store", "cache_fetch", "cache_remove", "event_subscribe", "events_list", ... @] get_statistics 🔗Prints the statistics (all, group or one) realtime values.
Output: an object containing the names and values of statistic variables. Examples of usage: [@ # opensips-cli -x mi get_statistics rcv_requests { "core:rcv_requests": 35243 } # opensipsc-cli -x mi get_statistics shmem: Changed lines 329-334 from:
"shmem:total_size": 1073741824, "shmem:max_used_size": 3389232, "shmem:free_size": 1070352592, "shmem:used_size": 2808952, "shmem:real_used_size": 3389232, "shmem:fragments": 3769 to:
"Name": "drouting", "Identifiers": [ { "Name": "Default", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "starting DB data loading" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "DB data loading successfully completed" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "2 gateways loaded (0 discarded), 2 carriers loaded (0 discarded), 1 rules loaded (0 discarded)" } ] } ] }, { "Name": "test", "Identifiers": [ { "Name": "main", "Reports": [] } ] }, { "Name": "core", "Identifiers": [ { "Name": "main", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initializing" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initialization completed, ready now" } ] } ] Changed lines 382-383 from:
# opensips-cli -x mi get_statistics shmem: core: .... to:
] Changed lines 385-387 from:
to:
sr_list_identifiers 🔗Command to list all the existing identifiers in OpenSIPS or only from a certain group. Changed lines 391-392 from:
to:
Output: an array of groups, each group being an array of identifiers . Changed lines 396-431 from:
# opensips-cli -x mi list_statistics to:
[ { "Group": "clusterer", "Identifiers": [ "sharing_tags" ] }, { "Group": "dispatcher", "Identifiers": [ "default;events", "default" ] }, { "Group": "drouting", "Identifiers": [ "Default;events", "Default" ] }, { "Group": "dialplan", "Identifiers": [ "default" ] }, { "Group": "core", "Identifiers": [ "main" ] } ]
Changed lines 433-441 from:
"shmem:total_size": "non-incremental", "shmem:max_used_size": "non-incremental", "shmem:free_size": "non-incremental", "shmem:used_size": "non-incremental", "shmem:real_used_size": "non-incremental", "shmem:fragments": "non-incremental", "rpmem:rpm_total_size": "non-incremental", "rpmem:rpm_used_size": "non-incremental", ... to:
"Group": "drouting", "Identifiers": [ "Default;events", "Default" ] } Changed lines 441-447 from:
reset_statistics 🔗Reset (to zero) the value of a statistic variable. Note that not all variables allow reset (depending of the nature of the information they carry - example "shmem:used_size").
Output: none. to:
uptime 🔗Prints various time information about OpenSIPS - when it started to run, for how long it runs. Changed lines 451-459 from:
# opensips-cli -x mi get_statistics received_replies { "tm:received_replies": 14543 } # opensips-cli -x mi reset_statistics received_replies # opensips-cli -x mi get_statistics received_replies { "tm:received_replies": 0 } to:
# opensips-cli -x mi uptime { "Now": "Mon Jul 21 17:41:03 2008", "Up since": "Mon Jul 21 17:36:33 2008", "Up time": "270 [sec]" } Changed lines 459-469 from:
cache_store 🔗This command stores in a cache system a string value.
Output: none. to:
version 🔗Prints the version string of a runningOpenSIPS. Changed lines 467-471 from:
# opensips-cli -x mi cache_store local password_user1 password to:
# opensips-cli -x mi version { "Server": "OpenSIPS (3.6.0-dev (x86_64/linux))" } Changed lines 474-481 from:
cache_fetch 🔗This command queries for a stored value.
Output: object containing the value if a record is found or 'Value not found' string otherwise. to:
which 🔗Prints all available MI commands from the queried OpenSIPSinstance. Changed lines 483-503 from:
# opensips-cli -x mi cache_fetch local password_user1 to:
# opensips-cli -x mi which [ "get_statistics", "list_statistics", "reset_statistics", "uptime", "version", "pwd", "arg", "which", "ps", "kill", "log_level", "xlog_level", "shm_check", "cache_store", "cache_fetch", "cache_remove", "event_subscribe", "events_list", ... Changed lines 506-508 from:
to:
Changed lines 510-512 from:
Output: None.\\ to:
Output: an object containing the names and values of statistic variables. Changed lines 518-532 from:
# opensips-cli -x mi cache_remove local password_user1 to:
# opensips-cli -x mi get_statistics rcv_requests { "core:rcv_requests": 35243 } # opensipsc-cli -x mi get_statistics shmem: { "shmem:total_size": 1073741824, "shmem:max_used_size": 3389232, "shmem:free_size": 1070352592, "shmem:used_size": 2808952, "shmem:real_used_size": 3389232, "shmem:fragments": 3769 } # opensips-cli -x mi get_statistics shmem: core: .... Changed lines 535-538 from:
to:
Changed lines 539-542 from:
Output: None.\\ to:
Changed lines 543-553 from:
# opensips-cli -x mi event_subscribe E_PIKE_BLOCKED udp:127.0.0.1:8888 1200 to:
# opensips-cli -x mi list_statistics { "shmem:total_size": "non-incremental", "shmem:max_used_size": "non-incremental", "shmem:free_size": "non-incremental", "shmem:used_size": "non-incremental", "shmem:real_used_size": "non-incremental", "shmem:fragments": "non-incremental", "rpmem:rpm_total_size": "non-incremental", "rpmem:rpm_used_size": "non-incremental", ... Changed lines 556-560 from:
events_list 🔗Lists all the events published through the Event Interface. to:
reset_statistics 🔗Reset (to zero) the value of a statistic variable. Note that not all variables allow reset (depending of the nature of the information they carry - example "shmem:used_size").
Output: none. Changed lines 565-580 from:
# opensips-cli -x mi events_list { "Events": [ { "name": "E_CORE_THRESHOLD", "id": 0 }, { "name": "E_CORE_SHM_THRESHOLD", "id": 1 }, { "name": "E_CORE_PKG_THRESHOLD", "id": 2 }, ... to:
# opensips-cli -x mi get_statistics received_replies { "tm:received_replies": 14543 } # opensips-cli -x mi reset_statistics received_replies # opensips-cli -x mi get_statistics received_replies { "tm:received_replies": 0 } Changed lines 576-578 from:
to:
Changed lines 581-583 from:
Output: None.\\ to:
Output: none. Changed line 589 from:
# opensips-cli -x mi raise_event E_PIKE_BLOCKED 127.0.0.1 to:
# opensips-cli -x mi cache_store local password_user1 password Changed lines 592-594 from:
to:
Changed lines 596-598 from:
Output: If no parameter is specified, then the command returns information about all events and their subscribers. If the event is specified, only the external applications subscribed for that event are returned. If the socket is also specified, only one subscriber information is returned.\\ to:
Output: object containing the value if a record is found or 'Value not found' string otherwise. Changed lines 602-638 from:
# opensips-cli -x mi subscribers_list to:
# opensips-cli -x mi cache_fetch local password_user1 @]
cache_remove 🔗This command removes a record from the cache system.
Output: None. # opensips-cli -x mi cache_remove local password_user1
event_subscribe 🔗Subscribes an external application to a certain event.
Output: None. # opensips-cli -x mi event_subscribe E_PIKE_BLOCKED udp:127.0.0.1:8888 1200
events_list 🔗Lists all the events published through the Event Interface. # opensips-cli -x mi events_list Added lines 640-678:
"Events": [ { "name": "E_CORE_THRESHOLD", "id": 0 }, { "name": "E_CORE_SHM_THRESHOLD", "id": 1 }, { "name": "E_CORE_PKG_THRESHOLD", "id": 2 }, ... @]
raise_event 🔗Raises an event through the Event Interface using an MI command.
Output: None. # opensips-cli -x mi raise_event E_PIKE_BLOCKED 127.0.0.1
subscribers_list 🔗Lists information about the subscribers
Output: If no parameter is specified, then the command returns information about all events and their subscribers. If the event is specified, only the external applications subscribed for that event are returned. If the socket is also specified, only one subscriber information is returned. # opensips-cli -x mi subscribers_list { Changed line 746 from:
to:
July 14, 2022, at 12:57 PM
by
- Added lines 322-377:
@]
sr_list_identifiers 🔗Command to list all the existing identifiers in OpenSIPS or only from a certain group. Arguments:
Output: an array of groups, each group being an array of identifiers . Examples of usage: [@
[ { "Group": "clusterer", "Identifiers": [ "sharing_tags" ] }, { "Group": "dispatcher", "Identifiers": [ "default;events", "default" ] }, { "Group": "drouting", "Identifiers": [ "Default;events", "Default" ] }, { "Group": "dialplan", "Identifiers": [ "default" ] }, { "Group": "core", "Identifiers": [ "main" ] } ]
{ "Group": "drouting", "Identifiers": [ "Default;events", "Default" ] } February 10, 2022, at 04:51 PM
by
- Changed lines 17-18 from:
argto:
arg 🔗Changed lines 33-34 from:
killto:
kill 🔗Changed lines 44-45 from:
list_blackliststo:
list_blacklists 🔗Changed lines 55-56 from:
list_tcp_connsto:
list_tcp_conns 🔗Changed lines 67-68 from:
log_level [level] [pid]to:
log_level 🔗 [level] [pid]Changed lines 108-109 from:
psto:
ps 🔗Changed lines 153-154 from:
pwdto:
pwd 🔗Changed lines 169-170 from:
reload_routesto:
reload_routes 🔗Changed lines 180-181 from:
sr_get_statusto:
sr_get_status 🔗Changed lines 208-209 from:
sr_list_statusto:
sr_list_status 🔗Changed lines 254-255 from:
sr_list_reportsto:
sr_list_reports 🔗Changed lines 325-326 from:
uptimeto:
uptime 🔗Changed lines 342-343 from:
versionto:
version 🔗Changed lines 358-359 from:
whichto:
which 🔗Changed lines 389-390 from:
get_statisticsto:
get_statistics 🔗Changed lines 418-419 from:
list_statisticsto:
list_statistics 🔗Changed lines 439-440 from:
reset_statisticsto:
reset_statistics 🔗Changed lines 460-461 from:
cache_storeto:
cache_store 🔗Changed lines 475-476 from:
cache_fetchto:
cache_fetch 🔗Changed lines 488-489 from:
cache_removeto:
cache_remove 🔗Changed lines 501-502 from:
event_subscribeto:
event_subscribe 🔗Changed lines 514-515 from:
events_listto:
events_list 🔗Changed lines 539-540 from:
raise_eventto:
raise_event 🔗Changed lines 551-552 from:
subscribers_listto:
subscribers_list 🔗Changed lines 609-610 from:
mem_pkg_dumpto:
mem_pkg_dump 🔗Changed lines 625-626 from:
mem_shm_dumpto:
mem_shm_dump 🔗Changed lines 636-637 from:
shm_checkto:
shm_check 🔗Changed line 650 from:
xlog_level [level]to:
xlog_level [level] 🔗Changed lines 653-654 from:
to:
Changed line 660 from:
to:
February 09, 2022, at 11:00 AM
by
- Added lines 169-311:
sr_get_statusThe MI equivalent of the sr_check_status() script function - to get the status of an 'status/report' identifier/group. Arguments: a mandatory group and optional identifier, see the parameters of the sr_check_status() script function. Output: the readiness, the status and details of the identifier/group (see the aggregation note for the return code of the sr_check_status() script function Examples of usage: # opensips-cli -x mi sr_get_status core { "Readiness": true, "Status": 1, "Details": "running" } # opensips-cli -x mi sr_get_status drouting all { "Readiness": true, "Status": 1, "Details": "aggregated" } sr_list_statusCommand to list the status of the identifiers within one or all 'status/report' groups. Arguments: an optional 'status/report' group, see the sr_check_status() script function for more details. Output: the readiness, the status and details for all the identifiers within the requested group, or within all defined/registered groups. Examples of usage: #opensips-cli -x mi sr_list_status [ { "Name": "drouting", "Identifiers": [ { "Name": "Default", "Readiness": true, "Status": 1, "Details": "data available" } ] }, { "Name": "test", "Identifiers": [ { "Name": "main", "Readiness": true, "Status": 1 } ] }, { "Name": "core", "Identifiers": [ { "Name": "main", "Readiness": true, "Status": 1, "Details": "running" } ] } ] sr_list_reportsCommand to list the full set of reports (logs) collected by 'status/report' identifiers. Arguments:
Output: the reports/logs for the requested identifiers, or for all identifiers within the groups. Examples of usage: #bin/opensips-cli -x mi sr_list_reports [ { "Name": "drouting", "Identifiers": [ { "Name": "Default", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "starting DB data loading" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "DB data loading successfully completed" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "2 gateways loaded (0 discarded), 2 carriers loaded (0 discarded), 1 rules loaded (0 discarded)" } ] } ] }, { "Name": "test", "Identifiers": [ { "Name": "main", "Reports": [] } ] }, { "Name": "core", "Identifiers": [ { "Name": "main", "Reports": [ { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initializing" }, { "Timestamp": 1644396830, "Date": "Wed Feb 9 10:53:50 2022", "Log": "initialization completed, ready now" } ] } ] } ] October 18, 2019, at 01:42 PM
by
- Changed line 481 from:
Get or set the global xlogging level in OpenSIPS processes. If no argument is passed to the xlog_level command, it will print the current xlog_level. If a logging level is given, it will be globally set for all OpenSIPS processes. to:
Get or set the global xlogging level in OpenSIPS processes. If no argument is passed to the xlog_level command, it will print the current xlog_level. If a logging level is given, it will be globally set for all OpenSIPS processes. \\ October 18, 2019, at 01:41 PM
by
- Changed lines 316-320 from:
Arguments: to:
Arguments:
Output: object containing the value if a record is found or 'Value not found' string otherwise. Changed lines 328-330 from:
Arguments: to:
Arguments:
Changed lines 340-343 from:
Arguments: to:
Arguments:
Changed lines 357-360 from:
Event:: E_CORE_THRESHOLD id=0 Event:: E_RTPPROXY_STATUS id=1 Event:: E_PIKE_BLOCKED id=2 to:
{ "Events": [ { "name": "E_CORE_THRESHOLD", "id": 0 }, { "name": "E_CORE_SHM_THRESHOLD", "id": 1 }, { "name": "E_CORE_PKG_THRESHOLD", "id": 2 }, ... Changed lines 376-378 from:
Arguments: to:
Arguments:
Changed lines 387-389 from:
Arguments: to:
Arguments:
Changed lines 394-400 from:
Event:: E_CORE_THRESHOLD id=0 Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never Subscriber:: socket=udp:127.0.0.1:8888 expire=1100 Event:: E_PIKE_BLOCKED id=2 Subscriber:: socket=rabbitmq:guest@127.0.0.1/hello expire=never to:
{ "Events": [{ "name": "E_RTPPROXY_STATUS", "id": 1, "subscribers": [ ... ] }, { "name": "E_PIKE_BLOCKED", "id": 2, "subscribers": [ ... ] } ] } Changed lines 413-416 from:
Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never Subscriber:: socket=udp:127.0.0.1:8888 expire=1100 to:
{ "Event": { "name": "E_RTPPROXY_STATUS", "id": 1, "subscribers": [{ "socket": "unix:/tmp/event.sock", "expire": "never", }, { "socket": "udp:127.0.0.1:8888", "expire": 1100 } ] } } Changed lines 430-431 from:
Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never to:
{ "Event": { "name": "E_RTPPROXY_STATUS", "id": 1, "Subscriber": { "socket": "unix:/tmp/event.sock", "expire": "never" } } } Changed lines 444-446 from:
Arguments: to:
Arguments:
Changed lines 459-460 from:
Arguments: to:
Arguments:
Added lines 482-483:
Arguments:
October 17, 2019, at 07:45 PM
by
- Changed lines 19-22 from:
Arguments: to:
Arguments: none Changed lines 25-28 from:
./opensips -f /etc/openser/test.cfg to:
[ "./opensips", "-f", "/etc/openser/test.cfg" ] Changed lines 45-46 from:
Output: an MI tree - first level (nodes named "List") will describe the list (name, owner, flags); Second level (nodes named "Rules) will describe the rules (blacklists) for each list (IP/mask, protocol, port, matching regexp, flags) to:
Output: an array with each object describing the list (name, owner, flags); the "Rules" item is an array with each object member describing the rules (blacklists) for each list (IP/mask, protocol, port, matching regexp, flags). Changed lines 55-56 from:
Output: an MI tree - one record per connection with the following attributes : ID, state, proto, source, destination, timeout, lifetime to:
Output: an array with one object per connection with the following attributes : ID, type, state, source, destination, lifetime, alias port. Changed line 64 from:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. to:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process.\\ Changed lines 66-68 from:
to:
Changed lines 72-74 from:
Process:: PID=10670 Debug=2 Type=attendant Process:: PID=10672 Debug=3 Type=MI FIFO Process:: PID=10673 Debug=1 Type=SIP receiver udp:193.668.3.633:5060 to:
{ "Processes": [ { "PID": 10670, "Log level": 2, "Type": "attendant" }, { "PID": 10672, "Log level": 3, "Type": "MI FIFO" }, { "PID": 10673, "Log level": 1, "Type": "SIP receiver udp:193.668.3.633:5060" }, ] } Changed lines 92-94 from:
New global debug:: 1 to:
{ "New global log level": 1 } Changed lines 96-99 from:
New debug:: 4 to:
{ "Log level": 1 } Changed lines 106-107 from:
Output: multiple MI nodes (named "Process") - each node contains process ID (internal), PID (OS), Type and description to:
Output: multiple objects, each one containing a process ID (internal), PID (OS) and Type. Changed lines 111-116 from:
Process:: ID=0 PID=16224 Type=attendant Process:: ID=1 PID=16225 Type=SIP receiver udp:193.668.1.2:5060 Process:: ID=2 PID=16226 Type=timer Process:: ID=3 PID=16227 Type=MI FIFO Process:: ID=4 PID=16228 Type=TCP receiver Process:: ID=5 PID=16230 Type=TCP main to:
{ "Processes": [ { "ID": 0, "PID": 27271, "Type": "attendant" }, { "ID": 1, "PID": 27272, "Type": "MI FIFO" }, { "ID": 2, "PID": 27273, "Type": "time_keeper" }, { "ID": 3, "PID": 27274, "Type": "timer" }, { "ID": 4, "PID": 27275, "Type": "SIP receiver udp:127.0.0.1:5060" }, { "ID": 5, "PID": 27276, "Type": "Timer handler" } ] } Changed lines 150-152 from:
Output: a single MI node with name "WD" containing the working directory full path. to:
Output: a single item containing the working directory full path. Changed lines 156-158 from:
WD:: / to:
{ "WD": "/" } Changed lines 174-176 from:
Output: three MI nodes: "Now" - current time; "Up since" - start time ; "Up time" - number of seconds since started. to:
Output: three items: "Now" - current time; "Up since" - start time ; "Up time" - number of seconds since started. Changed lines 180-182 from:
Now:: Mon Jul 21 17:41:03 2008 Up since:: Mon Jul 21 17:36:33 2008 Up time:: 270 [sec] to:
{ "Now": "Mon Jul 21 17:41:03 2008", "Up since": "Mon Jul 21 17:36:33 2008", "Up time": "270 [sec]" } Changed lines 190-191 from:
Output: one MI node (named "Server") containing the version string. to:
Output: one item (named "Server") containing the version string. Changed lines 195-198 from:
Server:: OpenSIPS (1.4.0dev14-notls (i386/linux)) to:
{ "Server": "OpenSIPS (3.6.0-dev (x86_64/linux))" } Changed lines 205-206 from:
Output: multiple MI nodes (no name), each node containing (as value) the name of an available MI command. NOTE that the list of available MI commands may differ depending of what modules your OpenSIPS is using. to:
Output: an array of the names of available MI commands. NOTE that the list of available MI commands may differ depending of what modules your OpenSIPS is using. Changed lines 210-228 from:
get_statistics list_statistics reset_statistics uptime version pwd arg which ps kill debug list_blacklists ul_rm ul_rm_contact ul_dump ul_flush ul_add ul_show_contact nh_enable_ping to:
[ "get_statistics", "list_statistics", "reset_statistics", "uptime", "version", "pwd", "arg", "which", "ps", "kill", "log_level", "xlog_level", "shm_check", "cache_store", "cache_fetch", "cache_remove", "event_subscribe", "events_list", ... Changed lines 234-236 from:
Arguments: input may be "all" - print all available statistics; "group:" - print only statistics from a certain group; "name" - print only this statistic. The OpenSIPS core defines the following groups: core, shmem; Modules export groups typically named like the module itself. to:
Arguments:
Output: an object containing the names and values of statistic variables. Changed lines 244-246 from:
core:rcv_requests = 35243 to:
{ "core:rcv_requests": 35243 } Changed lines 248-254 from:
shmem:total_size = 33554432 shmem:used_size = 1686952 shmem:real_used_size = 1704592 shmem:max_used_size = 1704592 shmem:free_size = 31849840 shmem:fragments = 1 # opensips-cli -x mi get_statistics all to:
{ "shmem:total_size": 1073741824, "shmem:max_used_size": 3389232, "shmem:free_size": 1070352592, "shmem:used_size": 2808952, "shmem:real_used_size": 3389232, "shmem:fragments": 3769 } # opensips-cli -x mi get_statistics shmem: core: Changed lines 261-262 from:
Prints a list of all available statistics in the current configuration of OpenSIPS to:
Prints a list of available statistics in the current configuration of OpenSIPS. Arguments:
Changed lines 268-279 from:
shmem:total_size:: incremental shmem:used_size:: incremental shmem:real_used_size:: incremental shmem:max_used_size:: incremental shmem:free_size:: incremental shmem:fragments:: incremental core:rcv_requests:: incremental core:rcv_replies:: incremental core:fwd_requests:: incremental core:fwd_replies:: incremental core:drop_requests:: incremental .... to:
{ "shmem:total_size": "non-incremental", "shmem:max_used_size": "non-incremental", "shmem:free_size": "non-incremental", "shmem:used_size": "non-incremental", "shmem:real_used_size": "non-incremental", "shmem:fragments": "non-incremental", "rpmem:rpm_total_size": "non-incremental", "rpmem:rpm_used_size": "non-incremental", ... Changed lines 282-283 from:
Arguments: name of the variable to be reset.\\ to:
Arguments:
Changed lines 289-291 from:
core:received_replies = 14543 to:
{ "tm:received_replies": 14543 } Changed lines 294-296 from:
core:received_replies = 0 to:
{ "tm:received_replies": 0 } Changed lines 302-305 from:
Arguments: to:
Arguments:
October 04, 2019, at 05:26 PM
by
- Changed line 294 from:
Arguments: None. \\ to:
Arguments: \\ October 04, 2019, at 05:23 PM
by
- Added lines 290-300:
@] raise_eventRaises an event through the Event Interface using an MI command. # opensips-cli -x mi raise_event E_PIKE_BLOCKED 127.0.0.1 April 16, 2019, at 07:54 PM
by
- Changed line 111 from:
reload_scriptto:
reload_routesApril 16, 2019, at 07:38 PM
by
- Changed line 25 from:
# opensipsctl fifo arg to:
# opensips-cli -x mi arg Changed line 39 from:
# opensipsctl fifo kill to:
# opensips-cli -x mi kill Changed line 49 from:
# opensipsctl fifo list_blacklists to:
# opensips-cli -x mi list_blacklists Changed line 59 from:
# opensipsctl fifo list_tcp_conns to:
# opensips-cli -x mi list_tcp_conns Changed line 71 from:
# opensipsctl fifo log_level to:
# opensips-cli -x mi log_level Changed line 89 from:
# opensipsctl fifo ps to:
# opensips-cli -x mi ps Changed line 106 from:
# opensipsctl fifo pwd to:
# opensips-cli -x mi pwd Changed lines 110-111 from:
uptimePrints various time information about OpenSIPS - when it started to run, for how long it runs.\\ to:
reload_scriptTriggers the reload of the routing block (the routes) from the script during the runtime. Added lines 114-122:
Output: none Please note that there are some limitations of when a reload is possible or not. Depending on the initial configuration of your modules, the reload may be rejected as the usage of the functions in the new script is not compatible with the original module setting and initialization. uptimePrints various time information about OpenSIPS - when it started to run, for how long it runs. Changed line 128 from:
# opensipsctl fifo uptime to:
# opensips-cli -x mi uptime Changed line 141 from:
# opensipsctl fifo version to:
# opensips-cli -x mi version Changed line 153 from:
# opensipsctl fifo which to:
# opensips-cli -x mi which Changed line 182 from:
# opensipsctl fifo get_statistics rcv_requests to:
# opensips-cli -x mi get_statistics rcv_requests Changed line 184 from:
# opensipsctl fifo get_statistics shmem: to:
# opensipsc-cli -x mi get_statistics shmem: Changed line 191 from:
# opensipsctl fifo get_statistics all to:
# opensips-cli -x mi get_statistics all Changed line 200 from:
# opensipsctl fifo list_statistics to:
# opensips-cli -x mi list_statistics Changed line 222 from:
# opensipsctl fifo get_statistics received_replies to:
# opensips-cli -x mi get_statistics received_replies Changed lines 224-225 from:
# opensipsctl fifo reset_statistics received_replies # opensipsctl fifo get_statistics received_replies to:
# opensips-cli -x mi reset_statistics received_replies # opensips-cli -x mi get_statistics received_replies Changed line 240 from:
# opensipsctl fifo cache_store local password_user1 password to:
# opensips-cli -x mi cache_store local password_user1 password Changed line 252 from:
# opensipsctl fifo cache_fetch local password_user1 to:
# opensips-cli -x mi cache_fetch local password_user1 Changed line 263 from:
# opensipsctl fifo cache_remove local password_user1 to:
# opensips-cli -x mi cache_remove local password_user1 Changed line 276 from:
# opensipsctl fifo event_subscribe E_PIKE_BLOCKED udp:127.0.0.1:8888 1200 to:
# opensips-cli -x mi event_subscribe E_PIKE_BLOCKED udp:127.0.0.1:8888 1200 Changed line 285 from:
# opensipsctl fifo events_list to:
# opensips-cli -x mi events_list Changed line 300 from:
# opensipsctl fifo subscribers_list to:
# opensips-cli -x mi subscribers_list Changed line 308 from:
# opensipsctl fifo subscribers_list E_RTPPROXY_STATUS to:
# opensips-cli -x mi subscribers_list E_RTPPROXY_STATUS Changed line 313 from:
# opensipsctl fifo subscribers_list E_RTPPROXY_STATUS unix:/tmp/event.sock to:
# opensips-cli -x mi subscribers_list E_RTPPROXY_STATUS unix:/tmp/event.sock Changed line 326 from:
# opensipsctl fifo mem_pkg_dump 11854 -1 to:
# opensips-cli -x mi mem_pkg_dump 11854 -1 Changed line 340 from:
# opensipsctl fifo mem_shm_dump -1 to:
# opensips-cli -x mi mem_shm_dump -1 Changed line 352 from:
# opensipsctl fifo shm_check to:
# opensips-cli -x mi shm_check Changed line 361 from:
# opensipsctl fifo xlog_level -2 to:
# opensips-cli -x mi xlog_level -2 March 08, 2019, at 09:18 PM
by
- Added lines 345-352:
xlog_level [level]Get or set the global xlogging level in OpenSIPS processes. If no argument is passed to the xlog_level command, it will print the current xlog_level. If a logging level is given, it will be globally set for all OpenSIPS processes. Example of usage: # opensipsctl fifo xlog_level -2 March 07, 2019, at 04:44 PM
by
- Changed lines 19-20 from:
Arguments: none to:
Arguments: September 27, 2018, at 07:20 PM
by
- Added lines 330-341:
@] shm_checkOnly available with QM_MALLOC + DBG_MALLOC. Fully scans the shared memory pool in order to locate any inconsistencies. If any sign of memory corruption is detected, OpenSIPS will immediately abort. # opensipsctl fifo shm_check May 22, 2018, at 12:44 PM
by
- Changed line 307 from:
mem_pkg_dumpto:
mem_pkg_dumpChanged line 322 from:
mem_shm_dumpto:
mem_shm_dumpMay 22, 2018, at 12:44 PM
by
- Changed lines 317-322 from:
(:commentboxchrono:) to:
The processes without IPC support (like timer and per-module processes) will not be able to generate a memory dump. mem_shm_dumpTriggers a shm memory dump. The memory dump will written to OpenSIPS's log (syslog or stderr) using the 'memdump' logging level. The global 'memdump' log level may be overwritten by a custom value provided as argument to this command. # opensipsctl fifo mem_shm_dump -1 May 22, 2018, at 12:41 PM
by
- Added lines 306-318:
mem_pkg_dumpTriggers a pkg memory dump for a given process. The memory dump will written to OpenSIPS's log (syslog or stderr) using the 'memdump' logging level. The global 'memdump' log level may be overwritten by a custom value provided as argument to this command. # opensipsctl fifo mem_pkg_dump 11854 -1 March 28, 2018, at 06:01 PM
by - March 28, 2018, at 06:01 PM
by
- Deleted lines 29-33:
debug (Removed in OpenSIPS 3.6)Replaced by log_level function. March 24, 2016, at 09:02 PM
by
- Changed line 70 from:
to:
March 24, 2016, at 09:02 PM
by
- Changed lines 31-37 from:
log_level [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. Arguments:
to:
debug (Removed in OpenSIPS 3.6)Replaced by log_level function. killThe command will terminate OpenSIPS (and internal shutdown). Changed lines 43-50 from:
# opensipsctl fifo log_level Process:: PID=10670 Debug=2 Type=attendant Process:: PID=10672 Debug=3 Type=MI FIFO Process:: PID=10673 Debug=1 Type=SIP receiver udp:193.668.3.633:5060 # opensipsctl fifo log_level 1 New global debug:: 1 # opensipsctl fifo log_level 4 10670 New debug:: 4 to:
# opensipsctl fifo kill Changed lines 46-48 from:
killThe command will terminate OpenSIPS (and internal shutdown).\\ to:
list_blacklistsThe command lists all the defined (static or learned) blacklists from OpenSIPS.\\ Changed lines 49-50 from:
Output: none to:
Output: an MI tree - first level (nodes named "List") will describe the list (name, owner, flags); Second level (nodes named "Rules) will describe the rules (blacklists) for each list (IP/mask, protocol, port, matching regexp, flags) Changed line 53 from:
# opensipsctl fifo kill to:
# opensipsctl fifo list_blacklists Changed lines 56-57 from:
list_blacklistsThe command lists all the defined (static or learned) blacklists from OpenSIPS.\\ to:
list_tcp_connsThe command lists all ongoing TCP/TLS connection from OpenSIPS.\\ Changed lines 59-60 from:
Output: an MI tree - first level (nodes named "List") will describe the list (name, owner, flags); Second level (nodes named "Rules) will describe the rules (blacklists) for each list (IP/mask, protocol, port, matching regexp, flags) to:
Output: an MI tree - one record per connection with the following attributes : ID, state, proto, source, destination, timeout, lifetime Changed line 63 from:
# opensipsctl fifo list_blacklists to:
# opensipsctl fifo list_tcp_conns Changed lines 66-70 from:
list_tcp_connsThe command lists all ongoing TCP/TLS connection from OpenSIPS. to:
log_level [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. Arguments:
Changed lines 75-82 from:
# opensipsctl fifo list_tcp_conns to:
# opensipsctl fifo log_level Process:: PID=10670 Debug=2 Type=attendant Process:: PID=10672 Debug=3 Type=MI FIFO Process:: PID=10673 Debug=1 Type=SIP receiver udp:193.668.3.633:5060 # opensipsctl fifo log_level 1 New global debug:: 1 # opensipsctl fifo log_level 4 10670 New debug:: 4 Added line 84:
March 24, 2016, at 08:59 PM
by
- Changed lines 31-33 from:
debug [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. to:
log_level [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the log_level command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. Changed line 35 from:
to:
Changed line 40 from:
# opensipsctl fifo debug to:
# opensipsctl fifo log_level Changed line 44 from:
# opensipsctl fifo debug 1 to:
# opensipsctl fifo log_level 1 Changed line 46 from:
# opensipsctl fifo debug 4 10670 to:
# opensipsctl fifo log_level 4 10670 January 05, 2016, at 12:20 PM
by
- Changed line 33 from:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will be changed only for that process. to:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will change only for that process. January 05, 2016, at 12:19 PM
by
- Changed line 33 from:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is given, the logging level will be changed only for that process. to:
Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is also given, the logging level will be changed only for that process. March 13, 2015, at 08:50 PM
by
- Added line 144:
list_statistics Deleted line 161:
nh_enable_rtpp Added lines 181-200:
.... @] list_statisticsPrints a list of all available statistics in the current configuration of OpenSIPS Examples of usage: [@ # opensipsctl fifo list_statistics shmem:total_size:: incremental shmem:used_size:: incremental shmem:real_used_size:: incremental shmem:max_used_size:: incremental shmem:free_size:: incremental shmem:fragments:: incremental core:rcv_requests:: incremental core:rcv_replies:: incremental core:fwd_requests:: incremental core:fwd_replies:: incremental core:drop_requests:: incremental August 12, 2014, at 01:23 PM
by
- Changed lines 32-37 from:
debug [level]Gets or sets the value of the debug core variable. You may use it to dynamically (at runtime) change or inspect the debug level of your OpenSIPS. If no argument is passed, the function will fetch the value of the debug level. to:
debug [level] [pid]Get or set the logging level of one or all OpenSIPS processes. If no argument is passed to the debug command, it will print a table with the current logging levels of all processes. If a logging level is given, it will be set for each process. If pid is given, the logging level will be changed only for that process. Arguments:
Changed lines 41-43 from:
DEBUG:: 4 to:
Process:: PID=10670 Debug=2 Type=attendant Process:: PID=10672 Debug=3 Type=MI FIFO Process:: PID=10673 Debug=1 Type=SIP receiver udp:193.668.3.633:5060 Added lines 45-47:
New global debug:: 1 # opensipsctl fifo debug 4 10670 New debug:: 4 March 20, 2014, at 08:55 PM
by
- Added lines 1-284:
Documentation -> Manuals -> Manual devel -> Core MI Functions(:title Core MI Functions - 3.6:) (:allVersions Interface-CoreMI 3.6:)
(:toc-float Table of Content:) MI (management interface) functions which are exported by OpenSIPS core. argReturns the full list of arguments used when OpenSIPS was started. As in UNIX, the first argument is the name of executable binary. Example of usage: # opensipsctl fifo arg ./opensips -f /etc/openser/test.cfg debug [level]Gets or sets the value of the debug core variable. You may use it to dynamically (at runtime) change or inspect the debug level of your OpenSIPS. If no argument is passed, the function will fetch the value of the debug level. Examples of usage: # opensipsctl fifo debug DEBUG:: 4 # opensipsctl fifo debug 1 killThe command will terminate OpenSIPS (and internal shutdown). Examples of usage: # opensipsctl fifo kill list_blacklistsThe command lists all the defined (static or learned) blacklists from OpenSIPS. Examples of usage: # opensipsctl fifo list_blacklists list_tcp_connsThe command lists all ongoing TCP/TLS connection from OpenSIPS. Examples of usage: # opensipsctl fifo list_tcp_conns psThe command will list all all OpenSIPS processes, along with type and description. Examples of usage: # opensipsctl fifo ps Process:: ID=0 PID=16224 Type=attendant Process:: ID=1 PID=16225 Type=SIP receiver udp:193.668.1.2:5060 Process:: ID=2 PID=16226 Type=timer Process:: ID=3 PID=16227 Type=MI FIFO Process:: ID=4 PID=16228 Type=TCP receiver Process:: ID=5 PID=16230 Type=TCP main pwdPrints the working directory of OpenSIPS instance. Examples of usage: # opensipsctl fifo pwd WD:: / uptimePrints various time information about OpenSIPS - when it started to run, for how long it runs. Examples of usage: # opensipsctl fifo uptime Now:: Mon Jul 21 17:41:03 2008 Up since:: Mon Jul 21 17:36:33 2008 Up time:: 270 [sec] versionPrints the version string of a runningOpenSIPS. Examples of usage: # opensipsctl fifo version Server:: OpenSIPS (1.4.0dev14-notls (i386/linux)) whichPrints all available MI commands from the queried OpenSIPSinstance. Examples of usage: # opensipsctl fifo which get_statistics reset_statistics uptime version pwd arg which ps kill debug list_blacklists ul_rm ul_rm_contact ul_dump ul_flush ul_add ul_show_contact nh_enable_ping nh_enable_rtpp get_statisticsPrints the statistics (all, group or one) realtime values. Examples of usage: # opensipsctl fifo get_statistics rcv_requests core:rcv_requests = 35243 # opensipsctl fifo get_statistics shmem: shmem:total_size = 33554432 shmem:used_size = 1686952 shmem:real_used_size = 1704592 shmem:max_used_size = 1704592 shmem:free_size = 31849840 shmem:fragments = 1 # opensipsctl fifo get_statistics all .... reset_statisticsReset (to zero) the value of a statistic variable. Note that not all variables allow reset (depending of the nature of the information they carry - example "shmem:used_size"). Examples of usage: # opensipsctl fifo get_statistics received_replies core:received_replies = 14543 # opensipsctl fifo reset_statistics received_replies # opensipsctl fifo get_statistics received_replies core:received_replies = 0 cache_storeThis command stores in a cache system a string value. # opensipsctl fifo cache_store local password_user1 password cache_fetchThis command queries for a stored value. # opensipsctl fifo cache_fetch local password_user1 cache_removeThis command removes a record from the cache system. # opensipsctl fifo cache_remove local password_user1
event_subscribeSubscribes an external application to a certain event. # opensipsctl fifo event_subscribe E_PIKE_BLOCKED udp:127.0.0.1:8888 1200 events_listLists all the events published through the Event Interface. # opensipsctl fifo events_list Event:: E_CORE_THRESHOLD id=0 Event:: E_RTPPROXY_STATUS id=1 Event:: E_PIKE_BLOCKED id=2 subscribers_listLists information about the subscribers # opensipsctl fifo subscribers_list Event:: E_CORE_THRESHOLD id=0 Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never Subscriber:: socket=udp:127.0.0.1:8888 expire=1100 Event:: E_PIKE_BLOCKED id=2 Subscriber:: socket=rabbitmq:guest@127.0.0.1/hello expire=never # opensipsctl fifo subscribers_list E_RTPPROXY_STATUS Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never Subscriber:: socket=udp:127.0.0.1:8888 expire=1100 # opensipsctl fifo subscribers_list E_RTPPROXY_STATUS unix:/tmp/event.sock Event:: E_RTPPROXY_STATUS id=1 Subscriber:: socket=unix:/tmp/event.sock expire=never (:commentboxchrono:) |