No audio when transfering incoming calls

Hello,

I am running asterisk 12.0.0 on a server hosted by online.net (no NAT) with an OVH SIP line. Incoming and outgoing calls are working well, even simultaneously.

My problem arises when transfering incoming calls to an external phone line. The communication is well established (ring + answer) but there is no audio.

For the transfer, I simply use a dial function in the dialplan :

There is no error in the CLI. Among others I can see:

[quote]Channel SIP/ovh_incoming-00000000 joined ‘simple_bridge’ basic-bridge
Channel SIP/ovh_outgoing-00000001 joined ‘simple_bridge’ basic-bridge
[/quote]

I can’t either see anything wrong in the SIP trace. The codec negociation seems to be OK :

I tried all possible values for the “nat” parameter in sip.conf. The same dialplan works well with another SIP provider, including the transfer function. So the problem may come from OVH, but more likely from me as I am not an expert in the area. Anyway I was not able to get any feedback from OVH about this problem.

Any idea of things I should check on my side?

check the audio path with rtp set debug on command

Thanks for your reply.
Unfortunately there is no RTP trace during transfer, whereas in simple incoming or outgoing calls I can see many lines like :

In case it helps, here is my rtp.conf (I just changed rtpend from 20000 to 40000 - no impact).

Any idea?
Thx

Get a SIP trace and see what addresses are being used as the RTP destination. Consider disabling any directmedia setting.

All directmedia/canreinvite/directrtpsetup parameters are set to “no”. The “nat” parameter is currently set to “yes”, as recommended by OVH, but I have tried all other possible values.

Now regarding the SIP trace, RTP destinations seem to be OK :

[quote]Peer audio RTP is at port 91.121.129.144:31658
(…)
Peer audio RTP is at port 91.121.129.153:32848[/quote]

However I noticed OVH private addresses in “o” field of the SDP :

[quote]o=cp10 143447098789 143447098789 IN IP4 10.7.1.121
(…)
o=cp10 143447098710 143447098712 IN IP4 10.7.1.149[/quote]

May that be the cause of the problem?

[quote=“ddcc”]
However I noticed OVH private addresses in “o” field of the SDP :

[quote]o=cp10 143447098789 143447098789 IN IP4 10.7.1.121
(…)
o=cp10 143447098710 143447098712 IN IP4 10.7.1.149[/quote]

May that be the cause of the problem?[/quote]

Yes it is a problem, If the media is sent to non routable IP, you won’t have audio. Just compare a trace of a good audio call and other of no audio call

Thanks ambiorixg12 for your feedback. I thought the target address was the one in the “c” field, which in my case is a different and routable one:

[quote]o=cp10 143447098789 143447098789 IN IP4 10.7.1.121
s=SIP Call
c=IN IP4 91.121.129.144[/quote]

With another SIP provider, the same transfer operation is successfull and the IP are identical in the “o” and the “c” fields.

If this is the problem, how can I prevent it?

Post a full sip trace.

c is equal to Connection Information

Connection Information - c=IN IP4 91.121.129.144
IN = Owner’s network type, in this case “IN” for Internet.
IP4 = Owner’s address type, in this case IP version 4.
91.121.129.144 = Caller’s SIP phone’s IP address.

Here is a full SIP trace obtained while calling from my cell phone (06611#####) to a SDA hosted by OVH (01850#####) and attached to my main OVH SIP line (00332309#####). The purpose of the dialplan is to transfer the call to an external line (09508#####). The call is actually transferred but there is no audio.

Will my beautiful SIP trace inspire some kind expert? :unamused:

It looks OK. I think you need to look at the network.

What kind of things should I look after regarding the network? I have no firewall.

I had a similar problem a few weeks ago. This helped me:

[]Portforwarding
[
]progressinband=yes
[]disalow=all
[
]allow=alaw, ulaw, gsm, g726

Thank you klappenbach for your suggestion. I tried your config but unfortunately it didn’t help.

I have neither firewall nor NAT on my server, so I don’t think portforwarding is the right track.

My Asterisk server works well for incoming and outgoing calls, with OVH as SIP provider. The audio problem happens only when I try to automatically forward incoming calls to external lines.

Directmedia is disabled.

All your suggestions are Welcome! :smiley:

Is there a router, that connects you to the internet?

I’ve tried to put my asterisk server :
[ul]
[]on a dedicated server hosted by online.net[/]
[]on a virtual private server hosted by OVH[/]
[/ul]
In both cases there was :
[ul]
[]no router (at least no router I had access to)[/]
[]the same audio problem[/]
[/ul]

May the problem come from OVH SIP?
Did some of you experience call transfer toward an external line using OVH SIP line?

Any feedback on similar use cases or problems?
Thanks you all for your help.

Hi everybody,

just to let you know that I finally got a solution to my problem here (in french):
https://forum.ovh.com/archive/index.php/t-44680.html

Basically all I needed was to play a short silence before transferring the call :

exten => s,1,Background(silence/2) exten => s,2,Dial(SIP/ovh_outgoing/#####,,e)

For sure this is black magic. No idea why it works and whether the bug is on OVH or Asterisk side. But it works!