Free How much of your firm runs on you? Take the 2-minute Key Man Score.
Lesson reading
0%

Lesson 14 / Unit 4: Load Testing

Voice Load Testing

A voice load test has to place real calls, hold them for minutes, and prove audio flowed both ways. The rig, a three-part pass rule, and what to record for every call.

A web load test fires thousands of requests and counts the successful responses. Point that idea at a voice agent and it will happily pass calls nobody could hear.

A call can be accepted, held for five minutes, and carry audio in one direction only, and there is no status code anywhere that says so. A voice load test has to place hundreds of stateful, bidirectional calls, hold them for minutes, and prove that audio actually flowed both ways. That difference in method decides whether your test can see anything at all. (For what a test that skips it looks like, silent failures opens with one.)

Call Generation

The generator places real calls: SIP INVITEs through your actual trunk path (or straight at your SIP service), with real RTP carrying scripted audio on a loop.

Signalling-only tests validate setup and teardown, but not media quality. Every catastrophic failure in these lessons happened on calls whose signalling was perfect: one-way audio from NAT, ports exhausted past the configured range, and calls that went quiet with nothing in any log.

SIP load tools do this job. SIPp, for example, runs scripted SIP scenarios, streams RTP or replays captured audio on each call, and sets the call rate with -r (see traffic control). Whatever tool you use, check three things before you trust it:

  1. It sends RTP on every call, with audio your agent will actually respond to.
  2. It counts RTP packets received per call, separately from packets sent.
  3. It lets you fix the hold time of each call.

Pass Criteria

Decide before the run what a passing call is. We use three conditions, and a call passes only if all three hold:

  1. Established. The call was answered.
  2. Held. It stayed up for the full planned duration.
  3. Media received. It received the expected audio stream, with nonzero RTP as an initial transport gate.

Nonzero RTP is necessary for this scripted test, but not sufficient: decode audio, check speech content and response timing, and record task success separately. Leave it out and a call that connected, held for five minutes and carried nothing back counts as a pass. Silent failures opens with exactly what happens then.

Call Records

Record one row per call from the generator’s side. Aggregates hide the calls you care about, so keep the rows and compute ratios later.

FieldWhy you need it
Call IDJoins the generator’s row to fleet-side logs
Start timeThe timestamp to bucket by (why it matters)
Answer time, end timeSetup delay, and whether the call held for its planned duration
Final SIP responseSeparates rejected calls from answered ones
RTP packets sent and receivedThe “heard” check, per call (RTP is what you count)
Pass or fail, with the reasonLets you count failures as instances and group them by cause

A run then reduces to a question you can answer from the rows: how many calls failed, which condition did each one fail, and when did they start?

Load Stages

Fix the hold time for a controlled experiment. In steady state, using answered calls and connected duration:

average active calls = answered calls per second x average connected duration

For example, holding 500 concurrent calls of 5 minutes each needs an arrival rate of 1.67 calls per second. Concurrency vs calls per second explains why that rate is its own capacity axis.

Then ramp in steps. Step to a target, hold long enough for pools to warm and buffers to fill, then step again. The interesting data is at the step where things bend, well before the step where they break.

Fleet Metrics

The generator sees the caller’s view. A collector samples the fleet’s view on every node: media ports in use, worker PSS, open file descriptors, and calls per node.

Sample them on a fixed interval through the whole run, tagged with the active call count, so each one becomes a per-call slope (the memory lesson has a script for PSS and descriptors). The findings live where the two views disagree: the generator says a call is up, and the fleet’s ports or memory say something else.

The generator sees the caller’s view. The collector sees the fleet’s view. The findings live where the two disagree.

Open full size

Network Coverage

Aim the generator at the path your callers use, through the carrier trunk where cost allows. NAT, firewalls and codec negotiation are half of what you are testing.

A generator inside the VPC talking to private addresses validates a network your callers will never use. It skips the public address, the security group and the carrier’s media path, which is exactly where one-way audio from NAT (unit 2) lives.

Next: concurrency vs calls per second, and the rate failure that hid inside a concurrency test.

Common questions

How do you load test a voice agent?

Place real SIP calls with real RTP audio through the same path your callers use, hold each call for a fixed duration, and verify per call that audio arrived. Ramp to a target concurrency, hold, then step again, while a collector samples the fleet side.

What counts as a passing call in a voice load test?

Decide it before the run: the call was established, held for the full planned duration, and received expected media. Nonzero packets alone do not prove speech was audible or correct; add decoded-audio and response checks.

Is a signalling-only SIP load test enough?

No. Signalling-only tests validate setup and teardown, but not media quality for a voice agent: every catastrophic failure we hit happened on calls whose signalling was perfect.

We do this work for teams shipping voice agents: Self-Hosted Voice Agent .

Edit this lesson on GitHub ↗

Discussion

Questions, corrections and war stories welcome. Sign in with GitHub to comment.

Free guide

Be The 10x Entrepreneur

Get the firm out of your head.

  • 8 chapters
  • 7 worksheets
  • 30 day plan