About what?
Placing individual IT services with hosting providers is not a new idea,
and today I will talk about testing the decision made in the title.
The server, with the installed IP PBX, is located in one of
our racks in the Netherlands,
the width of the server channel in the world is 1 Gbit / s.
The office of N is located in Russia, the channel to the world is 40 Mbit / s.

Testing method
- Connect to one of the VoIP providers in Russia (in this case, I used the “Multiphone” from the operator “Megaphone”), check the quality of communication.
- Let's simulate a large number of “real” calls with the sipp utility, check the quality.
- Determine the number of losses and jitter with the help of the iperf utility.
- Let us find out the peak value of the number of one-time calls in the context of the server used and the sipp script.
')
OS, software, hardware
- The hardware component will provide Dell 860 c 4GB of RAM and Soft RAID 1.
- In the role of IP PBX soloist Asterisk 11.8.1.
- OS - Debian GNU / Linux 7.4 (wheezy).
Tests
"Multiphone"
As expected, at this stage there was no hint of any problems.
I registered “Multiphone” on Asterisk and created a pair of internal peers.
Then I installed a Linphone softphone, connected to an IP PBX from a company N computer, as an internal subscriber, and made several calls.
The sound quality is wonderful, no distortion of the voice, nor I, nor my interlocutors noticed.
Let's load the system with “real” calls
Screenshot before the start:
top left - loading server network interface,
right - server load
bottom left - console Asterisk,
on the right is the sipp start command (details below).

The test initiates a computer company N in Russia.
Test team and description./sipp 188.42.243.252 -s 2005 -i 89.189.163.20 -d 120s -l 120 -aa -mi 89.189.163.20 -rtp_echo -nd -r 10 -m 1000 -trace_screen -bg
Where
188.42.243.252
- IP address of the IP PBX server Asterisk
-s 2005
- the number that sipp will call
-i 89.189.163.20
- sets this IP for the headers 'Contact:', 'Via:', and 'From:'
-d 120s
- call duration 2 minutes
-aa
- automatically send 200 OK to INFO, UPDATE and NOTIFY messages
-mi 89.189.163.20
- we specify IP for RTP
-rtp_echo
- dialogue imitation, we
-rtp_echo
back every rtp packet
-nd
- disables standard behavior in unexpected situations (sipp will interrupt calls if incorrect SIP messages are received)
-r 10
- 10 calls in 1 second
-m 1000
- complete the test after making 1000 calls
-trace_screen
- save the log
-bg
- sipp will be launched in the background
According to Asterisk's dialplan, for each caller in 2005, an audio file from MOH is played.
Extention 2005:
exten => 2005,1,Answer() same => n,Playback(/var/lib/asterisk/moh/reno_project-system) same => n,Hangup(
The test is running.
Let's see what kind of load created by the used sipp script.
As can be seen in the screenshot, sipp loaded the network at ~ 10Mbit / s in both directions, the CPU is used by 31%, and LA ~ 1.7.
At the bottom left we see connected peers - this is a Multiphone and a softphone connected via 3G from a smartphone.
The results of the sipp:


All calls ended successfully, the average response time in all calls was within 100 - 150 ms.
During testing, I made a call with Linphone installed on the smartphone, the voice quality did not change at all, the audibility is wonderful.
Additionally, I periodically connected to the current "dialogues" through ChanSpy for quality control, at this stage no problems were found.
Losses and jitter
Test the channel using the utility iperf.
Check from the IP telephony server to the computer of company N.
And now from computer to server.
In these tests, the server part of iperf listens to a UDP socket and displays information every 30 seconds.
The client part within 3 minutes sends to the server UDP packets of 172 bytes in size, the speed is set to 10Mbps.
* 10Mbps is just about 120 calls (G711), it is convenient to use
Asterisk Bandwidth Calculator for counting
The packet size of 172 bytes is taken from a dump during the sipp testing.
The results are good and speak for themselves:
there are meager packet losses in the direction of the server -> computer, jitter in both directions is very small.
Gaza to failure. We will load the server on full
Increase the number of one-time calls to 400.
The network progruzilas up to ~ 33Mbps, the CPU loaded almost "in the shelf", LA ~ 9.
But even with such a load, I successfully made a call via 3G from a smartphone (all the same Linphone).
Observing “conversations” through ChanSpy also did not detect sound distortion.
The results of the sipp at 400 calls.
All challenges again ended in success.
The average response time in 999, and of them was packed in 100 - 150 ms, and in the first call in 150 - 200 ms.
Some wheezing, dips and other troubles in hearing, as well as abuse in the Asterisk console, appeared when the number of one-time calls> = 450.
The peak for this server was the value of 501 calls.
Conclusion
As the test showed, it is possible to mix on the hosting not only web projects, but also services such as IP PBX.
A backup channel to the Internet in the office of the company N will provide fault tolerance of the channel to the server,
and properly configured QoS, on the border router, is the desired voice quality.
If you have an interesting script for the test, then we are waiting for you in the comments!
Thank you for attention!
Useful links:
1.
sipp.sourceforge.net/doc/reference.html2.
www.voxlink.ru/kb/asterisk-configuration/asterisk-test-sipp3.
www.pbxware.ru/wiki/testirovanie_nagruzki_na_asterisk_server_pri_pomoshchi_sippPosted by:
fessaectan