VOIP no voice answering after 4 rings/20 seconds

Hi, I have been banging my head on an issue for a while. I have an OpenWRT router, conntrack support included. NAT enabled.
On the LAN end I have a Grandstream HT802.
The VOIP service is supplied by the fibre network provider. In Italy with FTTC you have to have a voip phone because FTTC takes the whole bandwidth, so no physical phone line anymore, or rather the copper pair is 100% broadband).

Making phone calls: ALL GOOD.
Receiving phone calls: works fine if I answer within the 4th ring or approximately 20 seconds, if a wait longer to answer then the call takes place, but there is no sound on either end.

I thought this could be due to conntrack timeouts so I increased them in /etc/sysctl.conf as follows:
net.netfilter.nf_conntrack_udp_timeout=180. (default is 60)
net.netfilter.nf_conntrack_udp_timeout_stream=300 (default is 180)

But it has not made any difference.

I was wondering if anyone could kindly help.

Do other people with the same service have the same problem? The ISP may be programmed to give up on the call after 4 rings to potentially send it to voicemail.

1 Like

Check your SIP and RTP traffic and/or ask your provider to do the same. Before that OpenWrt is not guilty by default.

2 Likes

My provider is Vodafone in Italy, and as you may guess, they don't provide any such kind of support when customers don't use their supplied modem/router.
When using their Vodafone router (it has a phone socket behind it) there are no issues, as you would expect.
The issues are linked to using an openwrt router (BT Home Hub 5) with a Grandstream HT802 for VOIP.

I was hoping to get some clues from the community to tweak my openwrt router configuration. Since VOIP is behind a NAT, and all is good when I answer within 20 seconds, I am betting on some conntrack RTP timeout happening, which is why I tweaked the two parameters above, unfortunately with no effect.

seems to be not you only:
https://forums.grandstream.com/t/ht802-disconnecting-outbound-calls-after-20-seconds/31130/14

try using a sip client instead of the grandstream ata or an ip phone directly and see if the issue persist

2 Likes

Do you have the kmod-nf-nathelper-extra package installed?

If you do, have you enabled it in sysctl.conf?

net.netfilter.nf_conntrack_helper=1

Analyze your traffic first, then "tweak router configuration".
There is no single technical evidence yet that your router is doing something wrong.
OpenWrt is an IP router, but your problem description "there is no sound on either end" has nothing to do with IP. Once you will see that some TCP or UDP packets are lost, misrouted, etc - then it will be appropriate to discuss this here.

I have kmod-nf-nathelper-extra, without it, SIP/RTP would not work at all.
By default this module adds the following file in /etc/sysctl.d:

11-nf-conntrack.conf 
# Do not edit, changes to this file will be lost on upgrades
# /etc/sysctl.conf can be used to customize sysctl settings

net.netfilter.nf_conntrack_acct=1
net.netfilter.nf_conntrack_checksum=0
net.netfilter.nf_conntrack_max=16384
net.netfilter.nf_conntrack_tcp_timeout_established=7440
net.netfilter.nf_conntrack_udp_timeout=60
net.netfilter.nf_conntrack_udp_timeout_stream=180

the parameter you suggested isn't there, but the module must be enabled because otherwise SIP/RTP would not work.

AFAIK, and from what I have read, the conntrack helper is not enabled by default.

Conntrack helper should work by default in the LAN-to-WAN direction:

iptables-save -t raw

It requires to restart the firewall service after installing the package:
https://openwrt.org/packages/pkgdata/kmod-nf-nathelper-extra
But it may not be enough in some cases which can be covered by sysctl.

I tried too with a Grandstream DP715 phone, same result

I do not know how many times I restarted since I included nathelper a year ago. Beside I prefer to build my own firmware selecting packages in the firmware configuration

It must be, because if I build the firmware without it, VOIP does not work behind NAT

Not that hard to just try and find out if you are correct

Hello, I use a Cisco SPA 112 it is very similar, if you connect your device by ethernet you should not have a problem of any kind, verify in connections that the IP of the device is connected to an udp port in my case 5060, if so, no It is a problem of the router, it is a problem of the provisioning of the device {configuration}. ask your ISP for access credentials and be sure to modify the phone's tone numbers before stopping. With a stateful firewall, this is not the problem

Some ISP's never reveal VoIP setup details to customers so we are forced to get them sniffing VoIP traffic.

I had ling time VoIP NAT issues similar to the OP but after installing the stated kernel netfilter modules it seems to be solved, touch wood.

1 Like

Hello, I hope you are lucky and everything works fine. Is the problem strange, does it work with its own router behind the ISP's router?

With the ISP’s router it works perfect.

Now you are with your router, behind the ISP router?
In what environment do you work?
(ISP Router) ----- (Your Router) ----- (Voip)

ONT —- Openwrt router + VoIP adapter

The ISP’s router also when used connects to the ONT.