macOS Testing and Diagnostics
This page describes basic testing and diagnostics of FreeSWITCH™ on macOS. It is part of the FreeSWITCH™ macOS documentation.
- 1 Testing FreeSWITCH
- 1.1 Startup FreeSWITCH
- 1.2 Test the FreeSWITCH™ Command Prompt
- 1.3 Test A Phone
- 1.4 Test Two Phones
- 1.5 Test Additional Phones
- 1.6 Shutdown FreeSWITCH™
- 1.7 What Next?
- 2 Diagnosing Problems
Before testing FreeSWITCH™ verify that the installation was completed normally. If using macFI open the installation log folder on the desktop then open the "make" log and scroll to the bottom. If there are errors they must be resolved. If you performed a manual installation each step should have been checked before proceeding to the next step.
Regardless of how FreeSWITCH™ was installed it can be started from the command line or from macFI by selecting the "Test FreeSWITCH" option.
Startup From the Command Line
Start FreeSWITCH™ in a Terminal window using these commands:
There are many startup messages ending with some text boxes containing the names of the developers.
Test the FreeSWITCH™ Command Prompt
After all startup messages are displayed a command prompt appears, messages may continue as the prompt remains. Try a few FreeSWITCH™ commands:
If the commands return responses FreeSWITCH™ is working and you can continue with the next step.
Test A Phone
Test using a physical SIP phone or soft phone such as Bria Desktop or Bria for iPhone, or search the macOS App Store for "SIP" for a free download of Telephone. Then follow these steps:
- Setup the phone using the IP address of the Mac FreeSWITCH™ is running on as the server address. If macFI was used, it displayed this address after installation.
- Set the phones server port to 5060
- Set the phone's user ID to 1000 and the password to 1234.
- Once the phone is registered dial 9198, a song will play using test tones.
Test Two Phones
To establish a connection between phones, a second phone must be setup as follows:
- Setup the phone as above except use 1001 as the user ID.
- Once the phone is registered dial 1000 from 1001 or dial 1001 from 1000 and answer the call.
Test Additional Phones
User IDs 1000-1019 with password 1234 are pre-configured so up to 20 phones can be tested. To experience the potential of FreeSWITCH™ perform some functions found in Test Calls.
Issue the following command in the FreeSWITCH™ Terminal window:
Once FreeSWITCH™ has been tested it's time to customize macOS. The macOS Customization instructions will keep you busy!
If there is a problem you may need to provide diagnostic information to the developers. For instance, to see if your phones are registered during testing using the following command:
sofia status profile internal reg
FreeSWITCH™ Diagnostic Tools
There is a limited Troubleshooting Freeswitch and Troubleshooting Debugging information page available on the wiki. However, if you report a problem you will be asked for traces and log options. It will help to have them in advance if possible so you should become familiar with some of the following debugging commands:
console loglevel debug
sofia loglevel all 9
sofia profile profname(external..) siptrace on/off
sofia status [profilename}
sofia global siptrace on
sofia profile <name> restart
fsctl debug_level 1
fsctl send_sighup # <- To force the freeswitch.log file to segment.
TCP and SIP Diagnostic Tools
You may be asked for traces of the actual network data on the lan connection. The most common tools for this purpose are:
- Packet trace - Find information on how to perform it on macOS here.
- Wireshark - Great network tool to examine TCP and SIP data. Download the macOS version here. Note: You should install the Wireshark application in the Applications folder and you must run Wireshark as root so it must be run from Terminal, see line below. A "Wireshark folder" was also created to hold other Wireshark supplied items.
macOS Diagnostic Tools
All of these tools are supplied with macOS.
- CPU and memory utilization - Run the Activity Monitor in Applications/Utilities
- Find source paths to running processes - Open Terminal and type the command:
- Detailed resource usage dynamically updated - Open Terminal and type the command (-u sorts by processor utilization):
To terminate press control+z.