Freeswitch is the best open source VoIP Platform for production use . Adding Kamailio or OpenSIPS nodes in front of freeswitch makes VoIP networks more scalable and secure . It's practically a necessity for VoIP admins or engineers to learn some basic freeswitch commands to manage and troubleshoot calls on freeswitch.
We will learn some important freeswitch commands which come in handy . Type in fs_cli to connect to freeswitch console .
#sofia status
Sofia is the core sip stack used in freeswitch . sofia status command output the status of sip profiles status information .
#sofia status profile internal
This will display a specific sipprofile details . In above command it prints internal sip profile details.
#sofia status profile default reg
Above command will display current registration details on default profile .
#show registrations
Above command will display all registrations
#sofia_contact 1234
Above command will show registartion contact header details of user '1234 '
# load modulename
Above command is to load a module from console .Example : load mod_cdr_pg_csv .
#fsctl loglevel
This will show current log level . And if you want to set console log level use command console loglevel 0-7
To set sip trace log use command sofia global siptrace on
# sofia profile external siptrace on
Above command activates siptrace for external profile
#fsctl shutdown restart
Above command will restart freeswitch
#reload mod_xml_curl
Above command will reload xml_curl module.
#reloadxml
Sometimes you may want reload configuration to activate new configuration settings such as sipprofile settings etc.,
So to reload xml configurations issue above command
#reloadacl
When you change any freeswitch ACL configuration in freeswitch/autoload_configs/acl.conf.xml , You may want to reload new ACL using above command
#eval ${variable_name}
Global variables for freeswitch are defined in freeswitch/vars.xml. Use above command to show global variables such as domain , external_rtp_ip , external_sip_ip
of freeswitch from command prompt .
Example: eval ${domain}
#show channels
Above command displays individual call legs
#show calls
This will display call legs grouped by complete call legs A&B
#hupall
Use Above command to HangUp All calls
To exit from freeswitch console use keyboard short cut Ctrl+D
We will learn some important freeswitch commands which come in handy . Type in fs_cli to connect to freeswitch console .
#sofia status
Sofia is the core sip stack used in freeswitch . sofia status command output the status of sip profiles status information .
#sofia status profile internal
This will display a specific sipprofile details . In above command it prints internal sip profile details.
#sofia status profile default reg
Above command will display current registration details on default profile .
#show registrations
Above command will display all registrations
#sofia_contact 1234
Above command will show registartion contact header details of user '1234 '
# load modulename
Above command is to load a module from console .Example : load mod_cdr_pg_csv .
#fsctl loglevel
This will show current log level . And if you want to set console log level use command console loglevel 0-7
To set sip trace log use command sofia global siptrace on
# sofia profile external siptrace on
Above command activates siptrace for external profile
#fsctl shutdown restart
Above command will restart freeswitch
#reload mod_xml_curl
Above command will reload xml_curl module.
#reloadxml
Sometimes you may want reload configuration to activate new configuration settings such as sipprofile settings etc.,
So to reload xml configurations issue above command
#reloadacl
When you change any freeswitch ACL configuration in freeswitch/autoload_configs/acl.conf.xml , You may want to reload new ACL using above command
#eval ${variable_name}
Global variables for freeswitch are defined in freeswitch/vars.xml. Use above command to show global variables such as domain , external_rtp_ip , external_sip_ip
of freeswitch from command prompt .
Example: eval ${domain}
#show channels
Above command displays individual call legs
#show calls
This will display call legs grouped by complete call legs A&B
#hupall
Use Above command to HangUp All calls
To exit from freeswitch console use keyboard short cut Ctrl+D