Hello,
in our company we use Cisco Callmanager as telephony server. We have a sip trunk to an asterisk server to play a greeting message to external callers before transferring them into the waiting queue on the Cisco Callmanager.
The dialrule is as follows:
exten => 70003,1,Wait,1
exten => 70003,2,Playback(greeting)
exten => 70003,3,transfer(SIP/79801@10.10.164.21)
exten => 70003,4,Hangup
This worked fine using asterisk 1.2.7.1. Since we installed a new box using asterisk 1.4.17, the transfer fails and the user is disconnected. Using dial() instead of transfer() is not an option as dial holds the connection on the asterisk server while transfer removes asterisk from the rtp stream (which is essential as the calls would go across the WAN line when coming in on remote locations).
When debugging sip, the main difference seems to be that asterisk 1.4 sends the line: “Supported: replaces”, which asterisk 1.2 does not (see below).
Has anyone an idea how to get transfer working agein?
Thanks in advance,
Tom.
1.2 (working):
set_destination: Parsing sip:001728167939@10.10.164.21:5060 for address/port to send to
set_destination: set destination to 10.10.164.21, port 5060
Reliably Transmitting (no NAT) to 10.10.164.21:5060:
REFER sip:001728167939@10.10.164.21:5060 SIP/2.0
Via: SIP/2.0/UDP 3.6.165.21:5060;branch=z9hG4bK100813be;rport
From: sip:70003@3.6.165.21;tag=as1705c0f9
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37359948
Contact: sip:70003@3.6.165.21
Call-ID: baf97500-8201173b-24247-15a40a0a@10.10.164.21
CSeq: 102 REFER
User-Agent: Asterisk PBX
Max-Forwards: 70
Refer-To: sip:79801@10.10.164.21
Referred-By: sip:70003@3.6.165.21
1.4: (Not working)
set_destination: Parsing sip:001728167939@10.10.164.21:5060 for address/port to send to
set_destination: set destination to 10.10.164.21, port 5060
Reliably Transmitting (no NAT) to 10.10.164.21:5060:
REFER sip:001728167939@10.10.164.21:5060 SIP/2.0
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK096863e7;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Contact: sip:70003@10.10.164.50
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 REFER
User-Agent: Asterisk PBX
Max-Forwards: 70
Max-Forwards: 70
Refer-To: sip:79801@10.10.164.21
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
Referred-By: <sip:70003@10.10.164.5
The full debug of the failed transfer is as follows:
-- Executing [70003@callmanager:4] Transfer("SIP/10.10.164.21-082039e8", "SIP/79801@10.10.164.21") in new stack
set_destination: Parsing sip:001728167939@10.10.164.21:5060 for address/port to send to
set_destination: set destination to 10.10.164.21, port 5060
Reliably Transmitting (no NAT) to 10.10.164.21:5060:
REFER sip:001728167939@10.10.164.21:5060 SIP/2.0
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK096863e7;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Contact: sip:70003@10.10.164.50
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 REFER
User-Agent: Asterisk PBX
Max-Forwards: 70
Max-Forwards: 70
Refer-To: sip:79801@10.10.164.21
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
Referred-By: sip:70003@10.10.164.50
== Auto fallthrough, channel ‘SIP/10.10.164.21-082039e8’ status is 'UNKNOWN’
Scheduling destruction of SIP dialog ‘643f6b80-820114fc-2420d-15a40a0a@10.10.164.21’ in 6400 ms (Method: ACK)
set_destination: Parsing sip:001728167939@10.10.164.21:5060 for address/port to send to
set_destination: set destination to 10.10.164.21, port 5060
Reliably Transmitting (no NAT) to 10.10.164.21:5060:
BYE sip:001728167939@10.10.164.21:5060 SIP/2.0
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK5e9237e6;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 103 BYE
User-Agent: Asterisk PBX
Max-Forwards: 70
Content-Length: 0
[May 6 10:21:23] ERROR[4730]: cdr_csv.c:313 csv_log: Unable to re-open master file /var/log/asterisk//cdr-csv//Master.csv : No such file or directory
dephoastp01*CLI>
<— SIP read from 10.10.164.21:5060 —>
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK5e9237e6;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Date: Tue, 06 May 2008 08:21:23 GMT
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 103 BYE
Content-Length: 0
<------------->
— (8 headers 0 lines) —
SIP Response message for INCOMING dialog BYE arrived
dephoastp01*CLI>
<— SIP read from 10.10.164.21:5060 —>
NOTIFY sip:70003@10.10.164.50:5060 SIP/2.0
Via: SIP/2.0/UDP 10.10.164.21:5060;branch=z9hG4bK711e323af9ee
From: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
To: sip:70003@10.10.164.50;tag=as1fe258f8
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 NOTIFY
Max-Forwards: 70
Date: Tue, 06 May 2008 08:21:23 GMT
User-Agent: Cisco-CCM6.0
Event: refer
Subscription-State: terminated;reason=deactivated
Contact: sip:001728167939@10.10.164.21:5060
Content-Length: 0
<------------->
— (13 headers 0 lines) —
dephoastp01*CLI>
<— Transmitting (no NAT) to 10.10.164.21:5060 —>
SIP/2.0 400 Bad request
Via: SIP/2.0/UDP 10.10.164.21:5060;branch=z9hG4bK711e323af9ee;received=10.10.164.21
From: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
To: sip:70003@10.10.164.50;tag=as1fe258f8
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 NOTIFY
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog ‘643f6b80-820114fc-2420d-15a40a0a@10.10.164.21’ in 6400 ms (Method: NOTIFY)
Retransmitting #1 (no NAT) to 10.10.164.21:5060:
REFER sip:001728167939@10.10.164.21:5060 SIP/2.0
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK096863e7;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Contact: sip:70003@10.10.164.50
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 REFER
User-Agent: Asterisk PBX
Max-Forwards: 70
Max-Forwards: 70
Refer-To: sip:79801@10.10.164.21
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
Referred-By: sip:70003@10.10.164.50
dephoastp01*CLI>
<— SIP read from 10.10.164.21:5060 —>
SIP/2.0 500 Internal Server Error
Via: SIP/2.0/UDP 10.10.164.50:5060;branch=z9hG4bK096863e7;rport
From: sip:70003@10.10.164.50;tag=as1fe258f8
To: sip:001728167939@10.10.164.21;tag=f81a686a-1d87-4876-8b1d-18cb927f5997-37356342
Call-ID: 643f6b80-820114fc-2420d-15a40a0a@10.10.164.21
CSeq: 102 REFER
Reason: Q.850;cause=100
Content-Length: 0