Freeswitch fs cli commands

From 탱이의 잡동사니
Revision as of 14:12, 15 June 2017 by Pchero (talk | contribs) (→‎Basic)
Jump to navigation Jump to search

Overview

Freeswitch fs_cli command 내용 정리

Basic

[                 ...]	[                 acl]	[               alias]	[              banner]	
[           bg_system]	[               bgapi]	[               break]	[                chat]	
[            coalesce]	[            complete]	[                cond]	[             console]	
[    console_complete]	[console_complete_xml]	[         create_uuid]	[            db_cache]	
[       domain_exists]	[                echo]	[              escape]	[                eval]	
[          event_sink]	[              expand]	[         file_exists]	[       find_user_xml]	
[               fsctl]	[             gethost]	[       global_getvar]	[       global_setvar]	
[          group_call]	[                help]	[         host_lookup]	[            hostname]	
[              hupall]	[            in_group]	[        interface_ip]	[         is_lan_addr]	
[                json]	[    limit_hash_usage]	[limit_interval_reset]	[         limit_reset]	
[        limit_status]	[         limit_usage]	[          list_users]	[                load]	
[                 log]	[                 md5]	[       module_exists]	[              msleep]	
[             nat_map]	[           originate]	[                page]	[               pause]	
[            presence]	[               pyrun]	[              python]	[     quote_shell_arg]	
[             reg_url]	[               regex]	[              reload]	[           reloadacl]	
[           reloadxml]	[             replace]	[          say_string]	[           sched_api]	
[     sched_broadcast]	[           sched_del]	[        sched_hangup]	[      sched_transfer]	
[                show]	[            shutdown]	[               sofia]	[       sofia_contact]	
[     sofia_count_reg]	[           sofia_dig]	[  sofia_gateway_data]	[ sofia_presence_data]	
[   sofia_username_of]	[          sql_escape]	[              status]	[            strepoch]	
[            strftime]	[         strftime_tz]	[       strmicroepoch]	[                stun]	
[          switchname]	[              system]	[           time_test]	[          timer_test]	
[         tone_detect]	[              unload]	[         unsched_api]	[          url_decode]	
[          url_encode]	[           user_data]	[         user_exists]	[         uuid_answer]	
[          uuid_audio]	[          uuid_break]	[         uuid_bridge]	[      uuid_broadcast]	
[        uuid_buglist]	[           uuid_chat]	[    uuid_debug_media]	[        uuid_deflect]	
[       uuid_displace]	[        uuid_display]	[  uuid_dual_transfer]	[           uuid_dump]	
[       uuid_early_ok]	[         uuid_exists]	[        uuid_fileman]	[     uuid_flush_dtmf]	
[         uuid_getvar]	[           uuid_hold]	[   uuid_jitterbuffer]	[           uuid_kill]	
[          uuid_limit]	[  uuid_limit_release]	[       uuid_loglevel]	[          uuid_media]	
[    uuid_media_reneg]	[uuid_outgoing_answer]	[           uuid_park]	[          uuid_pause]	
[    uuid_phone_event]	[     uuid_pre_answer]	[     uuid_preprocess]	[         uuid_record]	
[uuid_recovery_refresh]	[      uuid_recv_dtmf]	[     uuid_ring_ready]	[      uuid_send_dtmf]	
[      uuid_send_info]	[   uuid_send_message]	[uuid_session_heartbeat]	[uuid_set_media_stats]	
[         uuid_setvar]	[   uuid_setvar_multi]	[       uuid_simplify]	[       uuid_transfer]	
[  uuid_video_refresh]	[    uuid_zombie_exec]	[             version]	[     xml_flush_cache]	
[          xml_locate]	[            xml_wrap]	[        uuid_warning]	

acl

Usage: acl <ip> <list_name>

acl,<ip> <list_name>,Compare an ip to an acl list,mod_commands

fsctl

fsctl 은 Freeswitch 에 control 메시지를 전송하는 명령어이다.

freeswitch@internal> fsctl 

[     calibrate_clock]	[               crash]	[         debug_level]	[          debug_pool]	
[           debug_sql]	[default_dtmf_duration]	[    flush_db_handles]	[              hupall]	
[            last_sps]	[            loglevel]	[   max_dtmf_duration]	[        max_sessions]	
[   min_dtmf_duration]	[        min_idle_cpu]	[               pause]	[         pause_check]	
[         ready_check]	[         reclaim_mem]	[             recover]	[              resume]	
[        save_history]	[         send_sighup]	[            shutdown]	[      shutdown_check]	
[                 sps]	[          sync_clock]	[      verbose_events]	

freeswitch@internal> fsctl 
-USAGE: [recover|send_sighup|hupall|pause [inbound|outbound]|resume [inbound|outbound]|shutdown\
 [cancel|elegant|asap|now|restart]|sps|sps_peak_reset|sync_clock|sync_clock_when_idle|reclaim_mem|max_sessions|\
min_dtmf_duration [num]|max_dtmf_duration [num]|default_dtmf_duration [num]|min_idle_cpu|loglevel [level]|debug_level [level]]

shutdown

Freeswitch 를 종료 및 재시작한다. 뒤에 따르는 옵션 값으로 현재 active 상태인 콜들에 대한 처리를 지정할 수 있다.

Usage: fsctl shutdown [cancel|elegant|asap|restart|now]
  • cancel : Discontinue a previous shutdown request. 이미 진행되고 있는 shutdown request 를 취소한다.
  • elegant : Wait for all traffic to stop; do not prevent new traffic. 모든 콜 들이 종료될 때 까지 기다린다. 새로 인입되는 콜을 허용한다.
  • asap : Wait for all traffic to stop; do not allow new traffic. 모든 콜 들이 종료될 때 까지 기다린다. 새로 인인되는 콜을 허용하지 않는다.
  • restart : Restart freeswitch immediately following the shutdown. Freeswitch 종료 후 곧바로 다시 시작한다.
  • now : Shutdown freeswitch immediately. Freeswitch 를 즉시 종료한다.

"elegant", "asap", "now" 옵션의 경우, "restart" 명령과 같이 사용될 수 있다.

Usage: fsctl shutdown [elegant|asap|now] restart

Example

$ fs_cli -x "fsctl shutdown asap restart"

See also

See also

See also