Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a trixbox server and every works find except the external SIPs. Inside net all sound goes fine, but if I use a SIP phone outside the net, I can connect, I can receive calls but I there is no sound.

I have this text in the sip_nat.conf:

nat=yes
externhost=xxxxx.dyndns.org
localnet=192.168.1.0/255.255.255.0
localhost=192.168.1.210
externrefresh=10
qualify=yes

And I have the ports from 5036 to 5082, 4569 and from 10000 to 20000 redirected to 192.168.1.210 on TCP and UDP.

What's wrong?

share|improve this question
add comment

2 Answers

You may need to configure the RTP ports, the reason you can initiate the call and you cannot hear is because SIP uses one port for data (5060) and a random one for voice (RTP).

In /etc/asterisk/rtp.conf:

[general]
;
; RTP start and RTP end configure start and end addresses
;
rtpstart=10000
rtpend=20000
share|improve this answer
    
The configuration file is like that and it still not working =( –  Leandro Vidal Jun 25 '11 at 10:11
    
Are you sure the nat for UDP ports is working? –  ghm1014 Jun 27 '11 at 15:39
    
yes, I've tried to put the pc with asterisk in the DMZ, and it doesn't work... I don't understand anything... –  Leandro Vidal Jun 28 '11 at 6:41
    
Ok, it was a router problem. I opened the ports for TCP and UDP. I've changed Both to UDP and it works! Thanks :) –  Leandro Vidal Jul 1 '11 at 13:31
add comment

Try specifying the external ip address:

nat=yes
externip = X.X.X.X
externhost=xxxxx.dyndns.org
localnet=192.168.1.0/255.255.255.0
localhost=192.168.1.210
externrefresh=10
qualify=yes

And restart asterisk.

share|improve this answer
    
Also, if you're opening up, make absolutely sure that your internet SIPs have strong secrets! Install APF and BFD as shown here: packtpub.com/article/securing-your-trixbox-server –  Yottatron Jun 24 '11 at 10:44
    
I had a trixbox install at my previous workplace connected to an ISDN30 line. I opened it up so they could have some home workers and over night one night, because I forgot to give 1 extension a secret, someone managed to connect and make twenty hours worth of calls over an 8 hour period costing the company £750 . Luckily they weren't too bothered but I hear folks have been seeing £10,000+ bills from toll theft recently. –  Yottatron Jun 24 '11 at 10:47
    
I can't specify the external IP because y dynamic, this is why I use externhost with the dyndns address –  Leandro Vidal Jun 24 '11 at 12:37
    
And you're able to resolve DNS queries? –  Yottatron Jun 24 '11 at 13:20
1  
Did you find out if you can resolve DNS queries from your trixbox server? Type dig xxxx.dyndns.org into your terminal and see if you get the right IP address back. Apparently Asterisk's handling of externhost is rather flakey and might not work correctly. –  Yottatron Jul 2 '11 at 2:25
show 3 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.