-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Tim Panton
Sent: 21 November 2006 19:16
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Hairping calls and Originating CLI
On 21 Nov 2006, at 10:08, Adrian Marsh wrote:
Hi,
I'm trying to track down what happened to some calls to a mobile
today between 9:00 and 9:15
(I've modified the log to mask IPs/Passwds/Phone #, etc.
127.111.200.* is our PSTN provider - Gradwell, the extension is
configured to ring 3 SIP connections, then divert to a mobile).
Below is our IAX log from our Asterisk box. The log has raised 2
questions. heres the call-flow as I understand it:
First question:
1) A call comes in from 127.111.200.135, we try contacting various
SIP clients, and timeout
2) After the timeout we then place an outbound call to a mobile,
via 127.111.200.135, but the call is accepted by 127.111.201.75
(is this a cluster?)
3) The mobile is answered, and both call-legs are marked as ready
to transfer..
At this point: Who hairpins the call? i.e., is the call handed
back to Gradwell ?
The next message in the log is Releasing the two calls, rather
than any message about joining them, and then we see hangup messages.
Second question: In the outbound leg (our A*k - mobile), we set
the CallerID number to the public PSTN of the local extension
here.. Is there any reason why we can't set this to be the
originating CLI from the first leg (the incoming call) ?
Example scenario: Bob calls Tracy, Bobs CLI gives his originating
number.. The A*k box makes an outbound call to Tracys mobile.
Theres little point in putting the second-leg originating CLI as
Tracy's office number (herself calling herself). Instead, we need
to put Bobs CLI as the originating digits, and the join the two
legs of the call.
I'm going to post this out to the A*k maillist, and see what comes
back, but I thought I'd get your view..
ubiphone*CLI
-- Accepting AUTHENTICATED call from 127.111.200.135:
requested format = ulaw,
requested prefs = (),
actual format = ulaw,
host prefs = (ulaw|alaw),
priority = mine
ubiphone*CLI
-- Executing GotoIf(IAX2/127.111.200.135:4569-4, 0?20) in
new stack
-- Executing Dial(IAX2/127.111.200.135:4569-4, SIP/204SIP/
404IAX2/20004:[EMAIL PROTECTED]/20004|15|r) in new stack
-- Called 204
Nov 21 09:07:14 NOTICE[1333]: app_dial.c:1049 dial_exec_full:
Unable to create channel of type 'SIP' (cause 3 - No route to
destination)
ubiphone*CLI
-- Called 20004:[EMAIL PROTECTED]/20004
ubiphone*CLI
-- SIP/204-088ac6b0 is ringing
ubiphone*CLI
-- Call accepted by 194.192.14.200 (format alaw)
-- Format for call is alaw
ubiphone*CLI
-- IAX2/194.192.14.200:4569-6 is ringing
ubiphone*CLI
-- Nobody picked up in 15000 ms
-- Hungup 'IAX2/194.192.14.200:4569-6'
-- Executing Macro(IAX2/127.111.200.135:4569-4, call-mobile|
2004|x25) in new stack
-- Executing Set(IAX2/127.111.200.135:4569-4, CALLERID
(number)=404) in new stack
-- Executing Dial(IAX2/127.111.200.135:4569-4, IAX2/
iaxout:[EMAIL PROTECTED]/x25|30|r) in new stack
ubiphone*CLI
-- Called iaxout:[EMAIL PROTECTED]/x25
ubiphone*CLI
-- Call accepted by 127.111.201.75 (format ulaw)
-- Format for call is ulaw
ubiphone*CLI
Nov 21 09:07:32 ERROR[13825]: chan_sip.c:10990
handle_request_subscribe: Got SUBSCRIBE for extension [EMAIL PROTECTED]
from 192.168.1.2, but there is no hint for that extension
ubiphone*CLI
-- IAX2/127.111.201.75:4569-3 is ringing
ubiphone*CLI
-- IAX2/127.111.201.75:4569-3 is making progress passing it to
IAX2/127.111.200.135:4569-4
ubiphone*CLI
-- IAX2/127.111.201.75:4569-3 answered IAX2/127.111.200.135:4569-4
-- Attempting native bridge of IAX2/127.111.200.135:4569-4 and
IAX2/127.111.201.75:4569-3
ubiphone*CLI
-- Channel 'IAX2/127.111.200.135:4569-4' ready to transfer
ubiphone*CLI
-- Channel 'IAX2/127.111.201.75:4569-3' ready to transfer
-- Releasing IAX2/127.111.201.75:4569-3 and
IAX2/127.111.200.135:4569-4
ubiphone*CLI
-- Hungup 'IAX2/127.111.201.75:4569-3'
== Spawn extension (macro-call-mobile, s, 2) exited non-zero on
'IAX2/127.111.200.135:4569-4' in macro 'call-mobile'
== Spawn extension (macro-call-mobile, s, 2) exited non-zero on
'IAX2/127.111.200.135:4569-4'
-- Hungup 'IAX2/127.111.200.135:4569-4'
To answer your questions:
At this point: Who hairpins the call? i.e., is the call handed
back to Gradwell ?
Your asterisk box hairpins it. Unless you have notransfer=yes in
iax.conf asterisk will
always _try_ and transfer a call where both endpoints are IAX so