Manual › Performance

Performance and capacity

How many calls a computer can make or answer with SIP Inspector depends on the computer: the processor above all, and the network. This chapter shows what was measured on real computers and how to measure your own with the same method: capacity.py and the scenarios Perf_cps_client/server and Perf_rtp_client/server. Both are in the folder capacityTester of github.com/zcoklin/SIPInspector (and in test/ of the source); the commands below call the script test/capacity.py: give the path where you keep it.

What is measured

  • Calls per second - short calls without media: INVITE, 100, 180, 200, ACK, one second, BYE, 200. The call rate is raised step by step, each step a minute of calls, until a step fails its limits. This is the signalling a computer can carry.
  • Calls with audio at the same time - calls with G.711 (PCMU, 20 ms packets, 50 packets a second) both ways, from pcap/test.pcap. The number of calls is raised step by step; in a step all the calls are up together for a minute. Each call is two RTP streams, one each way, so 100 calls are 100 streams sent and 100 received by each computer. A stream is 80 kbit/s at the IP level (200 bytes 50 times a second), about 95 kbit/s on Ethernet: 100 calls are about 9.5 Mbit/s each way, far below what a 1 Gbit/s network carries.

One computer makes the calls and the other answers; then they change roles. The weaker computer limits each run, so the CPU load of both is sampled every two seconds: it shows which one ran out.

The limits a step must keep

LimitMeaning
asr>=99.5Answer-seizure ratio: of the calls attempted, at least 99.5 % were answered (99 % in the audio test).
p95<=50095 % of the SIP requests got their response within 500 ms.
loss<=0.5At most 0.5 % of the RTP packets that should have come did not arrive.
mos>=4.0The estimated voice quality (MOS, 1 to 4.5, calculated from loss and jitter) is at least 4.0. G.711 without loss is 4.4.

A step passes when the runs on both computers keep their limits: the caller checks the answers and the audio it receives, the answerer the audio it receives. The limit reported is the highest step that passed, narrowed down between it and the first that failed.

How a measurement runs

  • Two SIP Inspector services, driven over their API. Both computers run SIP Inspector as a service (-api); capacity.py sends each service the scenario of its side, starts the runs, samples the CPU load and the status of both every two seconds, and reads the run reports when a step is over. It needs nothing on the computers but the program and its license.
  • A warm-up first. Short runs of 20 calls of each test start Java and the threads before the first counted step.
  • Steps, low to high. Calls per second: each step is a minute of calls at one rate, each call held one second. Calls with audio: the calls of a step start at 100 a second, and all of them are up together for a minute.
  • Narrowed down. After the first failing step the limit is searched between the last step that passed and that one, three times (halving the gap each time). The limit reported is the highest step that passed.
  • Without the checks of every message (-noChecks): a step measures the computers, not the SIP/SDP checks.
Note: Start with low steps. Java compiles the code of SIP Inspector while it runs: in the first minute after the services start, a computer does less than later. On the J5005 the same rate of 500 calls a second failed as the first step after a start and passed when the steps started at 100.

Measured

The computers side by side. Each number is the highest step that kept every limit; each computer's steps follow below. Where both sides ran on one computer, that computer made and answered every call: between two computers each one does half of that work. Java heap used is the most the two services held at one time, sampled every two seconds; Java lets the heap fill up before it collects the garbage, so it is more than the calls needed. Memory limits a computer only when the heap used comes near the heap Java may take: a quarter of the memory of the computer for each service.

ComputerProcessorCores, memoryOperating system, JavaSIP threadsCalls per secondCalls with audio at the same timeJava heap used at most (A + B)
Pentium Silver J5005Intel(R) Pentium(R) Silver J5005 CPU @ 1.50GHz4, 7.3 GBLinux 6.8.0-138-generic, Java 23.0.121,0001,3750.7 GB of 7.3 GB (heap at most 3.7 GB)
Core i9-1390013th Gen Intel(R) Core(TM) i9-1390032, 15.3 GBLinux 7.0.0-38-generic, Java 21.0.12.1422,000 or more17,5005.6 GB of 15.3 GB (heap at most 7.7 GB)
  • Pentium Silver J5005: limited by the processor. Above 1,000 calls a second the computer was at 86 to 89 % and the SIP answers came late (p95 over 1.6 s); with 1 SIP thread instead of 2 it made 962. With audio, 1,375 calls (about 66,000 RTP packets a second received by each side) passed; from 1,500 calls fewer than 99 % of the streams flowed at the same time, with the computer at 95 %. Memory was not the limit: the two services held at most 0.7 GB of Java heap together (each could take 1.8 GB) of the computer's 7.3 GB.
  • Core i9-13900: 22,000 calls a second was the highest step tried and passed with the computer at 42 % at most, so it can do more (with 8 SIP threads instead of 4 it made 20,500). At 22,000 calls a second about 27,700 calls were up at the same time, near the 29,767 media ports of -lrtp 6000: a higher rate needs a lower -lrtp. With audio, 17,500 calls (about 860,000 RTP packets a second received by each side) passed; at 20,000 calls only about 17,100 to 17,400 streams flowed at the same time, with the computer at 91 %. Memory was not the limit: at 22,000 calls a second the two services held at most 5.6 GB of Java heap together (each could take 3.8 GB, and Java lets the heap fill with garbage before it collects it) of the computer's 15.3 GB; with audio they held about 1.1 GB.

Pentium Silver J5005, 2026-10-21 21:41, both sides on one computer (loopback)

Transport UDP; every step 60 s of calls; run 1 time(s); SIP threads 2.

ComputerProcessorCoresMemoryOperating systemJava
Pentium Silver J5005 (A and B)Intel(R) Pentium(R) Silver J5005 CPU @ 1.50GHz47.3 GBLinux 6.8.0-138-generic amd64Oracle Corporation 23.0.1
Caller → answererCalls per secondCalls with audio at the same timeCPU of the computer at the limit (max)
A → B1000 calls/s1375 calls (1375 RTP streams each way)cps: 85.0 %
RTP: 94.7 %

The one computer was caller and answerer at the same time: at a rate of n calls a second it made n calls a second and answered the same n, and in the audio test it sent and received both streams of every call. Between two computers each one carries only its side, so expect more from the same computer there.

Calls per second, every step: p95 is the SIP response time of the caller; calls up at most counts the calls that were up at one time, which grows when the answers are late; Java heap used is the most each service held.

Calls/sCalls up at mostASRp95CPU avg / maxJava heap used A / BStep
500518100.0 %4 ms38.5 / 58.6 %194 / 166 MBpass
10001855100.0 %372 ms71.4 / 85.0 %256 / 184 MBpass
10623236100.0 %1684 ms76.1 / 87.4 %309 / 261 MBfail
11253425100.0 %1609 ms77.1 / 86.8 %262 / 261 MBfail
12503800100.0 %2114 ms76.4 / 89.0 %351 / 218 MBfail
15004549100.0 %2707 ms77.5 / 87.6 %379 / 319 MBfail

Calls with audio, every step: packets received by both sides together, the loss and jitter of the side that did worse, the lowest MOS of a call.

CallsPackets receivedLoss (worst side)JitterMOS (lowest)CPU avg / maxJava heap used A / BStep
10007,470,7130.107 %4.75 ms4.3972.1 / 95.8 %329 / 144 MBpass
12509,739,1120.103 %5.41 ms4.3878.4 / 94.6 %153 / 140 MBpass
137510,445,7070.106 %7.65 ms4.3877.6 / 94.7 %129 / 113 MBpass
150011,019,9770.11 %8.24 ms4.3778.8 / 95.0 %162 / 122 MBfail
200012,238,5800.131 %13.81 ms4.3682.9 / 96.9 %143 / 122 MBfail

Core i9-13900, 2026-10-21 20:47, both sides on one computer (loopback)

Transport UDP; every step 60 s of calls; run 1 time(s); SIP threads 4.

ComputerProcessorCoresMemoryOperating systemJava
Core i9-13900 (A and B)13th Gen Intel(R) Core(TM) i9-139003215.3 GBLinux 7.0.0-38-generic amd64Ubuntu 21.0.12.1
Caller → answererCalls per secondCalls with audio at the same timeCPU of the computer at the limit (max)
A → B22000 calls/s (or more: the last step passed)17500 calls (17500 RTP streams each way)cps: 41.5 %
RTP: 88.3 %

The one computer was caller and answerer at the same time: at a rate of n calls a second it made n calls a second and answered the same n, and in the audio test it sent and received both streams of every call. Between two computers each one carries only its side, so expect more from the same computer there.

Calls per second, every step: p95 is the SIP response time of the caller; calls up at most counts the calls that were up at one time, which grows when the answers are late; Java heap used is the most each service held.

Calls/sCalls up at mostASRp95CPU avg / maxJava heap used A / BStep
90009097100.0 %2 ms10.8 / 13.7 %2055 / 2214 MBpass
95009610100.0 %2 ms11.8 / 15.8 %1470 / 1688 MBpass
1000010125100.0 %3 ms12.5 / 16.3 %1541 / 1779 MBpass
1100011119100.0 %4 ms13.3 / 16.4 %1638 / 1800 MBpass
1200012273100.0 %6 ms15.4 / 20.6 %1725 / 1995 MBpass
1500015427100.0 %15 ms19.5 / 24.5 %2714 / 2881 MBpass
1800018698100.0 %28 ms25.4 / 33.8 %2097 / 2680 MBpass
2000021914100.0 %42 ms27.5 / 34.4 %2553 / 2886 MBpass
2200027732100.0 %177 ms31.8 / 41.5 %2649 / 3125 MBpass

Calls with audio, every step: packets received by both sides together, the loss and jitter of the side that did worse, the lowest MOS of a call.

CallsPackets receivedLoss (worst side)JitterMOS (lowest)CPU avg / maxJava heap used A / BStep
15000426,693,2980.084 %4.71 ms4.3852.9 / 83.7 %485 / 493 MBpass
17500550,661,4190.076 %6.15 ms4.3858.2 / 88.3 %482 / 587 MBpass
20000654,118,3120.074 %8.08 ms4.3761.8 / 90.7 %529 / 586 MBfail

Measuring your own computers

  1. On both computers, in the program folder, start SIP Inspector as a service, with the address the other computer reaches it at. The program folder needs only pcap/test.pcap and the license; the script sends the scenarios.
  2. Where Python 3 runs (either computer or a third one), start capacity.py with the API addresses of both services.
  3. The results are in capacity_<date>/: summary.md has the tables, steps.csv every step with its numbers and CPU load.
// Linux and macOS: on each computer
./SIPInspDlx -api 8080 -apiHost 0.0.0.0 -apiToken <token> -lip <its address> \
             -lp 5060 -lrtp 10000 -np -d ERROR
// then, on any computer that reaches both
python3 test/capacity.py --a http://<A>:8080 --b http://<B>:8080 --token <token> \
                         --a-name Laptop --b-name Server --repeat 3

The same on Windows, in a Command Prompt (each command on one line; py is the Python launcher):

SIPInspDlxCLI.exe -api 8080 -apiHost 0.0.0.0 -apiToken <token> -lip <its address> -lp 5060 -lrtp 10000 -np -d ERROR
py test\capacity.py --a http://<A>:8080 --b http://<B>:8080 --token <token> --a-name Laptop --b-name Server --repeat 3
Note: Close other programs on both computers, use a wired network, and open the firewall for the API port, the SIP port and the RTP ports (from -lrtp up). Each service may take up to a quarter of the memory of the computer, which was enough for every measurement above.
Debugging level: Start every service with -d ERROR. Without -d a service takes the debugging level the GUI saved last (both copies of the program folder share it), and at VERBOSE it writes about 27 lines of SIPInspector.log for every call: the steps then measure the log as well, and the limits come out lower. GET /system gives the level a service runs at (logLevel), and capacity.py warns when it is above ERROR. The first line of SIPInspector.log says it too (log level=...).

Both services on one computer

To try the method out, or to see what one computer does as caller and answerer at the same time, both services can run on one computer and talk over the loopback. Each needs its own API port, its own copy of the program folder, and RTP ports of its own: every call of a step takes the next RTP port, two apart, counted up from -lrtp. Where the ports of the two sides meet on one address, one side gets the RTP of the other, and the loss and MOS of the step are wrong.

  • Best: an address for each. A on -lip 127.0.0.1, B on -lip 127.0.0.2: their ports can never meet, at any number of calls, and both may use -lrtp 10000. Linux and Windows answer on every 127.x.x.x address; macOS answers on 127.0.0.1 only until the address is added (see the note below).
  • Or one address with the RTP ports far apart. A on -lrtp 10000 and B on -lrtp 20000 stay apart up to about 5000 calls with audio a step. The same -lrtp for both makes every step wrong.
  • Keep the RTP ports below 32768. From there up (49152 on Windows and macOS) the system gives ports to other programs, such as a browser, and a port another program holds leaves its call without audio.
macOS: The loopback of macOS has only 127.0.0.1. Add 127.0.0.2 before B starts, with sudo ifconfig lo0 alias 127.0.0.2 up, and check it with ifconfig lo0 (it lists inet 127.0.0.2). The address is gone after every restart of the Mac: add it again then. A service started before the address was there could not open its SIP port on it, and the INVITEs of A reach nothing: start B again. lsof -nP -iUDP:5070 shows java on 127.0.0.2:5070 when B listens there.

Linux and macOS, in three terminals (the measurements above were made this way):

// once: the second program folder
cp -r SIPInspector SIPInspector_B
// A: SIP 127.0.0.1:5060, API 8080
cd SIPInspector
./SIPInspDlx -api 8080 -apiToken <token> -lip 127.0.0.1 -lp 5060 -lrtp 10000 -np -d ERROR
// B: SIP 127.0.0.2:5070, API 8081
cd SIPInspector_B
./SIPInspDlx -api 8081 -apiToken <token> -lip 127.0.0.2 -lp 5070 -lrtp 10000 -np -d ERROR
// then: both APIs are on 127.0.0.1, whatever -lip says
python3 test/capacity.py --a http://127.0.0.1:8080 --b http://127.0.0.1:8081 --token <token> --roles ab

The same on Windows, in three Command Prompt windows:

xcopy /e /i SIPInspector SIPInspector_B
cd SIPInspector
SIPInspDlxCLI.exe -api 8080 -apiToken <token> -lip 127.0.0.1 -lp 5060 -lrtp 10000 -np -d ERROR
cd SIPInspector_B
SIPInspDlxCLI.exe -api 8081 -apiToken <token> -lip 127.0.0.2 -lp 5070 -lrtp 10000 -np -d ERROR
py test\capacity.py --a http://127.0.0.1:8080 --b http://127.0.0.1:8081 --token <token> --roles ab

The script calls each side at the SIP address and port its service was started with (-lip and -lp, given by GET /system), so A calls 127.0.0.2:5070 and B calls 127.0.0.1:5060. Without -apiHost the API listens on 127.0.0.1 only, which is all one computer needs, and --roles ab is enough: B calling A measures the same again. The script checks the RTP ports of the two sides before every step; when they would meet it stops and says which -lrtp or -lip to use. A service also counts the media ports it could not open because another program holds them (rtp.portErrors in its run report), and the script stops then too, as the numbers of that step are not those of the computer.

SIP is read by a thread of its own and RTP by several (-rtpThreads, half the cores by default, --rtp-threads of capacity.py), so the speed of one core no longer limits the calls with audio. The SIP messages are handled by several threads too (-sipThreads, a quarter of the cores by default, --sip-threads of capacity.py), each call on one of them, so one core no longer limits the calls a second. capacity.py starts its runs with -noChecks, so a step measures the computers and not the SIP/SDP checks; --checks keeps them on. A service counts the packets it lost itself because its UDP buffers were full: local.sipDrops and local.rtpDrops in its run report (Linux). When they are above 0 the result says tester overloaded, and capacity.py marks the step as measuring SIP Inspector, not the other computer; it does the same when an RTP thread was at 95 % or more (tester in GET /status). SIP Inspector asks for 8 MB buffers for SIP and 256 KB for each media port; Linux grants at most net.core.rmem_max, and SIPInspector.log then gives the sysctl command that raises it.