Upgrade 3CX to v18 and get it hosted free!

Asterisk config rtp.conf

Author image

rtp.conf

Configuration of Asterisk Real Time Protocol, RTP, media channels. RTP is used for SIP communication.

Details

On your router you might want to arrange both traffic shaping (QoS) and port forwarding (in case of NAT) for the RTP range that you chose

For each RTP port, you also open RTCP port. Therefore a call can consume up to 4 RTP ports.

The first port of the range should be even, so 10001 won’t be used (use 10000 or 10002 instead); the last port must be uneven, and if you specify e.g. 10017 as last in range asterisk will actually use 10018, so be aware!

Question2:

  • maybe ports aren’t released directly by Asterisk after the call has completed?
  • does Asterisk allocate RTP ports for each member in a group dial (DIAL(SIP/device1&SIP/device2) before the actual call is established?

Check with “netstat -anup” or “netstat -anu” for open ports

Experience shows that often Asterisk seems to consume more RTP ports (or RTP port numbers) than one would expect, so it is most probably not a good idea to reduce the RTP port range to exactly 4 times the maximum number of concurrent calls…

Related issues:

  • bug 14777 and bug 11257: Error “No RTP ports remaining. Can’t setup media stream for this call.”
  • one possible cause/solution: check if ulimit is set high enough
  • possible related: bug 8036

Example

;
; RTP Configuration
;
[general]
;
; RTP start and RTP end configure start and end addresses
;
rtpstart=10000
rtpend=20000


If you have a NAT or firewall between Asterisk and the server, you need to set these up to handle forwarding of the configured ports.

Related:

  • RTP – Real Time Protocol

See also


Article Reviews

Write a Review

Your email address will not be published. Required fields are marked *

Required Field. Minimum 5 characters.

Required Field. Minimum 5 characters, maximum 50.

Required field.There is an error with this field.

Required Field.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

There are no reviews for this article. Be the first one to write a review.

Related Posts:

Get 3CX - Absolutely Free!
Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.