One-Way Audio with phones from Outside via SIP. HELP!

csievert
Posts: 13
Member Since:
2007-01-05

Why is SIP / NAT not working properly on Trixbox 2.0
I currently have a Trixbox 2.0 system running in production using (70)Linksys 942 phones for standard users. We have it connected to a 100M pipe to the internet, T-1 PRI and 4-analog lines. When I was running Asterisk@Home as our production box I had no problems placing Linksys phones remotely and connecting back into the system via SIP.
We have now migrated to Trixbox 2.0 box. It was a clean build and everything was configured. The system overall is running quite smoothly except for one MAJOR issue.
When placing the Linksys phones outside (via SIP), I am getting one-way audio when I call from the outside phone to another extension. However, if I place an outbound call from the outside phone audio works perfectly. Also, if I call the outside phone from one of the phones located on the local network, I get the audio both ways also.
The issue seems to only occur when initiated from the phone residing on the outside of the network.
I have gone through every file I thought possible to make sure everything is correct and have yet to find a reason.
In addition to the conf files, I also have my firewall set to allow all traffic in and out of my server.
Hopefully someone can shed light or possibly Trixbox can send us a helping light on this issue. (Kerry Help!)

Here is my config to compare with everyone (I have added all the files I know of that relate to network/nat/sip...):

host.conf
order hosts,bind
************************************************
hosts (not to be confused with host.conf)
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost
127.0.0.1 mypbx.mydomain.com mypbx.localhost
***************************************************************
SIP.conf
[general]
port = 5060 ; Port to bind to (SIP is 5060)
bindaddr = 0.0.0.0 ; Address to bind to (all addresses on machine)
disallow=all
allow=ulaw
allow=alaw
allow=gsm
allow=ilbc
context = from-sip-external ; Send unknown SIP callers to this context
callerid = Unknown
tos=0x68
nat=1 (I had net=yes but see no difference)
#include sip_nat.conf
#include sip_custom.conf
#include sip_additional.conf
****************************
SIP_additional.conf
[4305]
type=friend
secret=xxxx
record_out=Adhoc
record_in=Adhoc
qualify=yes
port=5060
nat=yes
mailbox=4305@default
host=dynamic
dtmfmode=rfc2833
dial=SIP/4305
context=from-internal
canreinvite=no
callerid=device
*******************************
SIP_nat.conf
[general]
externip=xxx.xxx.xxx.xxx
externhost = mypbx.mydomain.com
localnet=192.168.1.0/255.255.255.0
nat=yes
externrefresh=10
********************************
dnsmgr.conf
[general]
;enable=yes ; enable creation of managed DNS lookups
; default is 'no'
;refreshinterval=1200 ; refresh managed DNS lookups every seconds
; default is 300 (5 minutes)
*************************************
resolv.conf
(you should make sure to add all your nameservers if you have more than one)
nameserver 192.168.1.249
nameserver 192.168.1.254
**************************************
network (under etc/sysconfig)
NETWORKING=yes
HOSTNAME=mypbx.mydomain.com
**************************************
Sincerely,
Chris



verdexus
Posts: 62
Member Since:
2006-06-05
Re: One-Way Audio with phones from Outside via SIP. HELP!

I'm seeing the same (or at least very similar) problem with all my SIP clients outside the firewall where my Asterisk is located not working. Specifically, they register, but audio doesn't work properly - at least one way of the audio connection is not there.

Like Chris, they stopped working when I upgraded - in my case from Trixbox 1.1.1/Asterisk 1.2.9 to Trixbox 2.0/Asterisk 1.2.14 (note, that I subsequently upgraded Asterisk to 1.2.17, but the same problem persists).

My SIP clients work great inside the firewall.

The problem is that I get one way audio not working - e.g. call voicemail (*97) and I hear nothing but the log shows it going through the motions. Likewise with outside calls and *63 where it reads the weather forecast.

I've tried almost every conceivable combination of config files (sip.conf & sip_nat.conf) to fix this, but all to no avail.



Undrhil
Posts: 264
Member Since:
2006-06-25
Try a network sniffer on the

Try a network sniffer on the network where you are trying to use the SIP phone. Take a look at what ports that phone is trying to use for RTP. I bet you will find that the RTP ports the phone is trying to use are not open on your firewall. Or, your externip isn't current.



csievert
Posts: 13
Member Since:
2007-01-05
Found ISSUE with SIP_NAT causing ONE WAY AUDIO

Hi Randall,

I got it...
While comparing my configs from the old A@H server and the new Trixbox 2.0 I noticed something.
In the old config, the SIP_NAT only had:

externip=x.x.x.x
localnet:=x.x.x.x/255.255.255.0

On the Trixbox one, I had:

[GENERAL]
externip=x.x.x.x
localnet=x.x.x.x/255.255.255.0

By simply removing the " [GENERAL] " and saving/updating the Trixbox server, all the ONE WAY issues went away. Let me know if you had the same issue...

Hooray!!!!! no more one-way issues...

Chris



csievert
Posts: 13
Member Since:
2007-01-05
Thanks

Thanks Undrhil, As I expected, nothing had changed on the network from before, so i was pretty confident that it was not network related.... After all this time searching, it turns out to be a simple " [GENERAL] " line...

Till the next exciting turn.

Thanks Again,
Chris



verdexus
Posts: 62
Member Since:
2006-06-05
Found ISSUE with SIP_NAT causing ONE WAY AUDIO

Congratulations Chris.

Unfortunately, my sip_nat.conf didn't have any context defined, so my problem must be in a different place - it just had the externip and localnet definitions. So, what does your sip_nat.conf, in the end, look like?

I'm going to have to keep looking at other causes of this strange problem.

Randall



csievert
Posts: 13
Member Since:
2007-01-05
In the end all I have are

In the end all I have are two lines in the SIP_NAT nothing else:
externip=x.x.x.x
localnet:=x.x.x.x/255.255.255.0

If you want post all your conf files (cleaned) to go through them...

Chris



yerks
Posts: 3
Member Since:
2006-08-21
Sip_nat is Blank

My sip_nat is also blank. perhaps adding this line to the file will help?



verdexus
Posts: 62
Member Since:
2006-06-05
MY Config Files

Chris,
At the end of this message are my SIP Config Files, with config for just one extension (a Softphone outside the Firewall that doesn't work with this or any config on the latest Asterisk/FreePBX version). Let me know if you see anything bad in these. Also, note that using externip as an IP address doesn't seem to work, but i get better performance with the FQDN you see in SIP_NAT.CONF. - Randall
_________________________________________
SIP.CONF:
[general]

bindport = 5060 ; Port to bind to (SIP is 5060)
bindaddr = 0.0.0.0 ; Address to bind to (all addresses on machine)
; defaultexpirey=180 ; normally 120, but this is for GRNVoIP
registertimeout=120 ; also for GRNVoIP: default=20 - time between registration attempts
disallow=all
allow=ulaw
allow=alaw
; If you need to answer unauthenticated calls, you should change this
; next line to 'from-trunk', rather than 'from-sip-external'.
; You'll know this is happening if when you call in you get a message
; saying "The number you have dialed is not in service. Please check the
; number and try again."
context = from-sip-external ; Send unknown SIP callers to this context
callerid = Unknown
tos=0x68

; #, in this configuration file, is NOT A COMMENT. This is exactly
; how it should be.
#include sip_nat.conf
#include sip_custom.conf
#include sip_additional.conf
_____________________________________
SIP_NAT.CONF:
; nat=yes ; Note that either this line, or next make it break
; externip=216.16.241.168 ; internal is 10.50.0.149
externip=veasterisk.verdexus.com
localnet=10.50.0.0/255.255.255.0 ; pattern of IP for other SIP on LAN
____________________________________
SIP_ADDITIONAL.CONF: [This is settings for an extension OUTSIDE Firewall]

[22315]
type=friend
secret=xxxx
record_out=Adhoc
record_in=Adhoc
qualify=no
port=5060
nat=yes
mailbox=2231@device
host=dynamic
dtmfmode=rfc2833
dial=SIP/22315
context=from-internal
canreinvite=no
callerid=device
accountcode=xxxx



csievert
Posts: 13
Member Since:
2007-01-05
SIP issue could reside on Firewall or DNS server...

Hi Randall.. They look okay. the two first lines in the SIP_NAT with the ";" in front. Do you have that in the actual file? If so, I would remove and leave it as basic as possible.

Additionally, have you looked at other files on the system like "hosts"?

hosts (not to be confused with host.conf)
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost
127.0.0.1 mypbx.mydomain.com mypbx.localhost

Also have you compared my other configs from above to your system? If it is all correct and updated, then you are back to firewall or DNS if your DNS is set to look at another server. Remember files like hosts, resolv... do not auto update easily and may keep default strings rather than the ones you actually need in there...

Let me know,
Chris



driver28
Posts: 171
Member Since:
2006-06-05
I have no problems but an empty sip_nat.conf

Hi!

i have a completely blank sip_nat.conf, but frequently use my softphone without problems outside the firewall. I had some problems before until I looked at firewall logs and sat RTP traffic blocked because of having a too narrow port range for RTP go through resulting in no sound or one-way sound. I'm on TB 1.2.3 if that makes any difference...

On the other hand I have the 2 lines externip and localnet in my sip.conf...

/Hasse

--

/Hasse



surferride
Posts: 1
Member Since:
2010-05-04
One way audio problems

I am also facing this one way audio problems, I dont know what is going on, people can listen to me but I cant listen to anyone.

I´ve opened all ports in FireWall and checked for the SIP_NAT.conf with the Externip and localip...but no luck.

Anyone? Thanks!

--
Surferride
Buenos Aires - Argentina

--

--
Surferride
Buenos Aires - Argentina



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.