David Cunningham
2014-Jan-20 02:51 UTC
[asterisk-users] Asterisk not receiving call from VPN address
Hi, We have a Kamailio and Asterisk cluster, both machines being on a real 103.x IP address and also on a 172.x OpenVPN address. The problem is that when Kamailo receives a call from the VPN and forwards it to the Asterisk server on it's 103.x address, Asterisk never sees the call. If Kamailio receives a call from the VPN and forwards the call to the Asterisk server on it's 172.x address then it works. However, if the call isn't from the VPN then forwarding it to the 172.x address doesn't work. So basically the problem is going between the real network and the VPN. The question is, how can we make this work when calls are received on either network on the Kamailio server and are forwarded to Asterisk? Using ngrep on the Asterisk server we see that it does receive the INVITE, but Asterisk's logging shows no sign it at all. We guess it's a Linux networking issue rather than Asterisk's fault, but don't know where to fix it. We do have net.ipv4.ip_forward = 1 on both the Kamailio and Asterisk servers. Thanks in advance for any help. The ngrep on the Asterisk server: U 2014/01/17 13:15:15.599557 172.x.x.x:5060 -> 103.y.y.y:5060 INVITE sip:9067268 at 103.y.y.y:5060;transport=udp SIP/2.0. Record-Route: <sip:172.x.x.x;lr=on>. Via: SIP/2.0/UDP 172.x.x.x;branch=z9hG4bK50c7.f49ceb73.0. Via: SIP/2.0/UDP 192.z.z.z:5062;rport=5062;branch=z9hG4bK806710997. From: "9067271" <sip:9067271 at 172.x.x.x>;tag=198791249. To: <sip:9067268 at 172.x.x.x>. Call-ID: 1905625787 at 192.z.z.z. ... 172.x.x.x is the Kamailio server's VPN address 103.y.y.y is the Asterisk server's real address 192.z.z.z is the calling phone's LAN address -- David Cunningham, Voisonics http://voisonics.com/ USA: +1 213 221 1092 UK: +44 (0) 20 3298 1642 Australia: +61 (0) 2 8063 9019 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20140120/60dbfd4f/attachment.html>
Paul Belanger
2014-Jan-20 18:30 UTC
[asterisk-users] Asterisk not receiving call from VPN address
On Sun, Jan 19, 2014 at 9:51 PM, David Cunningham <dcunningham at voisonics.com> wrote:> Hi, > > We have a Kamailio and Asterisk cluster, both machines being on a real 103.x > IP address and also on a 172.x OpenVPN address. > > The problem is that when Kamailo receives a call from the VPN and forwards > it to the Asterisk server on it's 103.x address, Asterisk never sees the > call. > > If Kamailio receives a call from the VPN and forwards the call to the > Asterisk server on it's 172.x address then it works. However, if the call > isn't from the VPN then forwarding it to the 172.x address doesn't work. So > basically the problem is going between the real network and the VPN. > > The question is, how can we make this work when calls are received on either > network on the Kamailio server and are forwarded to Asterisk? > > Using ngrep on the Asterisk server we see that it does receive the INVITE, > but Asterisk's logging shows no sign it at all. We guess it's a Linux > networking issue rather than Asterisk's fault, but don't know where to fix > it. We do have net.ipv4.ip_forward = 1 on both the Kamailio and Asterisk > servers. > > Thanks in advance for any help. > > The ngrep on the Asterisk server: > > U 2014/01/17 13:15:15.599557 172.x.x.x:5060 -> 103.y.y.y:5060 > INVITE sip:9067268 at 103.y.y.y:5060;transport=udp SIP/2.0. > Record-Route: <sip:172.x.x.x;lr=on>. > Via: SIP/2.0/UDP 172.x.x.x;branch=z9hG4bK50c7.f49ceb73.0. > Via: SIP/2.0/UDP 192.z.z.z:5062;rport=5062;branch=z9hG4bK806710997. > From: "9067271" <sip:9067271 at 172.x.x.x>;tag=198791249. > To: <sip:9067268 at 172.x.x.x>. > Call-ID: 1905625787 at 192.z.z.z. > ... > > 172.x.x.x is the Kamailio server's VPN address > 103.y.y.y is the Asterisk server's real address > 192.z.z.z is the calling phone's LAN address >Sounds like a routing problem opposed to an application issue. You'll have to fire up tcpdump on Kamailio and see what happens to the packet. The look at the local routing tables to see where it is getting routed. If Asterisk is not receiving the patch, then Kamailio is not routing it properly. You'll be able to see everything once you have a pcap of the call. -- Paul Belanger | PolyBeacon, Inc. Jabber: paul.belanger at polybeacon.com | IRC: pabelanger (Freenode) Github: https://github.com/pabelanger | Twitter: https://twitter.com/pabelanger
Larry Moore
2014-Jan-21 06:38 UTC
[asterisk-users] Asterisk not receiving call from VPN address
Have you checked your localnet=, deny=, permit=, contactdeny= & contactpermit= settings? My 2c worth. On 20/01/2014 10:51 AM, David Cunningham wrote:> Hi, > > We have a Kamailio and Asterisk cluster, both machines being on a real > 103.x IP address and also on a 172.x OpenVPN address. > > The problem is that when Kamailo receives a call from the VPN and > forwards it to the Asterisk server on it's 103.x address, Asterisk never > sees the call. > > If Kamailio receives a call from the VPN and forwards the call to the > Asterisk server on it's 172.x address then it works. However, if the > call isn't from the VPN then forwarding it to the 172.x address doesn't > work. So basically the problem is going between the real network and the > VPN. > > The question is, how can we make this work when calls are received on > either network on the Kamailio server and are forwarded to Asterisk? > > Using ngrep on the Asterisk server we see that it does receive the > INVITE, but Asterisk's logging shows no sign it at all. We guess it's a > Linux networking issue rather than Asterisk's fault, but don't know > where to fix it. We do have net.ipv4.ip_forward = 1 on both the Kamailio > and Asterisk servers. > > Thanks in advance for any help. > > The ngrep on the Asterisk server: > > U 2014/01/17 13:15:15.599557 172.x.x.x:5060 -> 103.y.y.y:5060 > INVITE sip:9067268 at 103.y.y.y:5060;transport=udp SIP/2.0. > Record-Route: <sip:172.x.x.x;lr=on>. > Via: SIP/2.0/UDP 172.x.x.x;branch=z9hG4bK50c7.f49ceb73.0. > Via: SIP/2.0/UDP 192.z.z.z:5062;rport=5062;branch=z9hG4bK806710997. > From: "9067271" <sip:9067271 at 172.x.x.x>;tag=198791249. > To: <sip:9067268 at 172.x.x.x>. > Call-ID: 1905625787 at 192.z.z.z. > ... > > 172.x.x.x is the Kamailio server's VPN address > 103.y.y.y is the Asterisk server's real address > 192.z.z.z is the calling phone's LAN address > > -- > David Cunningham, Voisonics > http://voisonics.com/ > USA: +1 213 221 1092 > UK: +44 (0) 20 3298 1642 > Australia: +61 (0) 2 8063 9019 > >
Administrator TOOTAI
2014-Jan-22 13:42 UTC
[asterisk-users] Asterisk not receiving call from VPN address
Le 20/01/2014 03:51, David Cunningham a ?crit :> Hi, > > We have a Kamailio and Asterisk cluster, both machines being on a real > 103.x IP address and also on a 172.x OpenVPN address. > > The problem is that when Kamailo receives a call from the VPN and > forwards it to the Asterisk server on it's 103.x address, Asterisk > never sees the call. > > If Kamailio receives a call from the VPN and forwards the call to the > Asterisk server on it's 172.x address then it works. However, if the > call isn't from the VPN then forwarding it to the 172.x address > doesn't work. So basically the problem is going between the real > network and the VPN. > > The question is, how can we make this work when calls are received on > either network on the Kamailio server and are forwarded to Asterisk? > > Using ngrep on the Asterisk server we see that it does receive the > INVITE, but Asterisk's logging shows no sign it at all. We guess it's > a Linux networking issue rather than Asterisk's fault, but don't know > where to fix it. We do have net.ipv4.ip_forward = 1 on both the > Kamailio and Asterisk servers. > > Thanks in advance for any help.Hi David, if you have a 11.7.0 version try to downgrade to 11.6.0.1 See my post about similar issue with no registration of our intranet phones -- Daniel