No RTP ports remaining

Output after 1 our of making 35 call every 10 seconds (each calls last around 20 seconds) and receiving arround 3750 per our. It seems that channels for outgoing calls are not being destroyed if tried to put in the outgoing call operator codec rtptimeout = 30 and rtpholdtimeout = 30 and canreinvite=no with no improvement
also try to increment to rtp channel range from 5000 - 51000 and no improvement
please help… this is on asterisk 1.4.26 and if i upgrade to 1.6 asterisk will self reboot every 15 minutes with this load.

when i get this error i can only accept around 2 calls per minute

server spect 16Gb Ram //// 8 cores (2 X Intel® Xeon® CPU E5405 @ 2.00GHz)

sip show channels
5000

- Attempting call on SIP/xxxxxxxxx@cc-push2 for hungup@push:1 (Retry 1)
[Sep  7 15:21:51] ERROR[23352]: rtp.c:2020 ast_rtp_new_with_bindaddr: No RTP ports remaining. Can't setup media stream for this call.
[Sep  7 15:21:51] WARNING[23352]: chan_sip.c:4607 sip_alloc: Unable to create RTP audio  session: Address already in use
[Sep  7 15:21:51] ERROR[23352]: chan_sip.c:17032 sip_request_call: Unable to build sip pvt data for 'xxxxxxxxx@cc-push2' (Out of memory or socket error)
[Sep  7 15:21:51] NOTICE[23352]: channel.c:3220 __ast_request_and_dial: Unable to request channel SIP/xxxxxxxxx@cc-push2
    -- Executing [failed@push:1] AGI("OutgoingSpoolFailed", "failed.php") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/failed.php
    -- Attempting call on SIP/xxxxxxxxx@cc-push2 for hungup@push:1 (Retry 1)
    -- Attempting call on SIP/xxxxxxxxx@cc-push2 for hungup@push:1 (Retry 1)
[Sep  7 15:21:51] ERROR[23356]: rtp.c:2020 ast_rtp_new_with_bindaddr: No RTP ports remaining. Can't setup media stream for this call.
[Sep  7 15:21:51] WARNING[23356]: chan_sip.c:4607 sip_alloc: Unable to create RTP audio  session: Address already in use
[Sep  7 15:21:51] ERROR[23356]: chan_sip.c:17032 sip_request_call: Unable to build sip pvt data for 'xxxxxxxxx@cc-push2' (Out of memory or socket error)
[Sep  7 15:21:51] NOTICE[23356]: channel.c:3220 __ast_request_and_dial: Unable to request channel SIP/xxxxxxxxx@cc-push2
    -- AGI Script failed.php completed, returning 0
    -- Executing [failed@push:1] AGI("OutgoingSpoolFailed", "failed.php") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/failed.php
[Sep  7 15:21:51] ERROR[23355]: rtp.c:2020 ast_rtp_new_with_bindaddr: No RTP ports remaining. Can't setup media stream for this call.
[Sep  7 15:21:52] WARNING[23355]: chan_sip.c:4607 sip_alloc: Unable to create RTP audio  session: Address already in use
[Sep  7 15:21:52] ERROR[23355]: chan_sip.c:17032 sip_request_call: Unable to build sip pvt data for 'xxxxxxxxx@cc-push2' (Out of memory or socket error)
[Sep  7 15:21:52] NOTICE[23355]: channel.c:3220 __ast_request_and_dial: Unable to request channel SIP/xxxxxxxxx@cc-push2
  == Auto fallthrough, channel 'OutgoingSpoolFailed' status is 'UNKNOWN'
    -- Executing [failed@push:1] AGI("OutgoingSpoolFailed", "failed.php") in new stack
    --
CODEC for incomming calls
[Callsin]
type=peer
host=xxx.xx.xx.xx
qualify=yes
nat=no
context=in
incominglimit=4000
canreinvite=yes
insecure=port

CODEC FOR OUTGOING CALLS
[ccOUT]
type=peer
host=xxx.xx.xx.xxx
username=xxxxxx
secret=xxxxxx
disallow=all
allow=g723
allow=ulaw
allow=alaw
canreinvite=no

thanks for the help…

35 every 10 seconds seems a bit much. Why don’t you spread this across multiple machines ? I don’t think it’s Asterisk as much as it is the OS.