Audio problem between two sip trunk interfaces and wan / lan

Dears, I have a problem and I hope you can help me

I have two network interfaces on my server

eth0 -> LAN AND INTERNET
eth1 -> to my sip provider

previously I could make or receive calls without problems from and to the internet with softphone or by VPN with the public ip that goes to the eth0 network, this was until I changed the parameter (external address) because I changed my analog lines to digital and in this parameter I had the public ip that goes to the eth0 network and I changed it to the public ip that has the inferred eth1 due to audio problems, obviously I preferred to use the ip of eth1 since there are cell phone calls coming and going , local phones, other companies etc.

image

now the phones that are on the internet or vpn register to the server, make and receive calls, but do not have audio, it is probably a routeo / nat problem but I don’t know how to solve it.

Has anyone had any experience with this problem?

If Asterisk must present a public IP address to external extensions and also present a different public IP address to the trunking provider, you will need to have separate transports. One way is to use chan_sip for the trunk and pjsip for extensions (or vice versa); it is also possible to set up multiple transports on pjsip.

Alternatively, if you can use VPN for all external extensions, no NAT is required and Asterisk can be configured with the eth1 public address.

Or, if the trunking provider’s SIP and media servers are on private addresses accessible from eth1, it should be possible to set up Local Networks to include those addresses and only the eth0 public address could be used.

What would be the best way to solve this?

I currently have pjsip for extensions and for the truncal of my SIP provider

Should I leave the ip that goes on the eth1 interface as an external ip?

Is there no way to add two external ip?

I had not had this problem before because I only used my eth0 interface for the lan since I had a gateway with fxo lines within the same network and everything worked fine

I could solve the problem by changing the config the SIP provider to sip_chan and leaving the extensions as pjsip, in the sip configuration I added the public internet ip and lan to the pjsip in the external ip parameter and the public ip of the eth1 interface to the configuration sip_chan in the same way on the external ip and everything is working perfectly. Thank you

Relying on Chan_SIP as a solution is not the way to do this. Chan_SIP is basically dead, it’s deprecated and is now on the list for removal (could happen within the next 4 years). One of the big points this year at AstriCon was this fact and people being softly/kindly reminded to not wait 4 years to deal with this and do it now.

So what would be the best solution to this? Now I realize that no calls come from the sip server

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.