I tried with the following dial string formats and getting similar results,
PJSIP/+91962039****@airtel
PJSIP/91962039****@airtel
With an without the +
Logs,
Please note that
{{caller}}
is the phone number of user
{{sip_number}}
is the number that is being dialed by user
{{mobile_number}}
is the phone number where I am trying forward the calls from user
Replaced with above for privacy
<--- Received SIP request (1228 bytes) from UDP:10.232.139.146:5060 --->
INVITE sip:{{sip_number}}@ims.airtel.in SIP/2.0
Via: SIP/2.0/UDP 10.232.139.146:5060;branch=z9hG4bK1t0sfp5ht7h45h3h41r55trpt;Role=3;Hpt=8fc2_36;TRC=ffffffff-ffffffff
Call-ID: asbc7k618m4n5gmz8ku8qqn6mnukuh76qg97@B.5.42.ims.airtel.in
From: <sip:{{caller}}@ims.airtel.in>;tag=02br0ygx
To: <sip:{{sip_number}}@ims.airtel.in>
CSeq: 1 INVITE
Allow: INVITE,ACK,OPTIONS,BYE,CANCEL,INFO,PRACK,NOTIFY,MESSAGE,REFER,UPDATE
Contact: <sip:10.232.139.146:5060;Dsp=eb9a-200;Dpt=77d8-400;Hpt=8fc2_16;CxtId=4;TRC=ffffffff-ffffffff>
Max-Forwards: 64
Supported: timer,100rel,histinfo
Session-Expires: 1800
Min-SE: 600
P-Asserted-Identity: <sip:0{{caller}}@ims.airtel.in>
P-Charging-Vector: icid-value=AE888F23F92CDD2022128194033;orig-ioi=10.232.136.242;term-ioi=Magicl_8046897600
P-Early-Media: gated
Content-Length: 380
Content-Type: application/sdp
v=0
o=- 185426899 185426899 IN IP4 10.232.139.147
s=SBC call
c=IN IP4 10.232.139.147
t=0 0
m=audio 22612 RTP/AVP 108 102 8 0 18 116
a=rtpmap:108 AMR/8000
a=fmtp:108 mode-change-neighbor=1;mode-change-period=2
a=rtpmap:102 AMR/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:18 G729/8000
a=rtpmap:116 telephone-event/8000
a=ptime:20
a=maxptime:20
a=3gOoBTC
== Setting global variable 'SIPDOMAIN' to 'ims.airtel.in'
<--- Transmitting SIP response (412 bytes) to UDP:10.232.139.146:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.232.139.146:5060;rport=5060;received=10.232.139.146;branch=z9hG4bK1t0sfp5ht7h45h3h41r55trpt;Role=3;Hpt=8fc2_36;TRC=ffffffff-ffffffff
Call-ID: asbc7k618m4n5gmz8ku8qqn6mnukuh76qg97@B.5.42.ims.airtel.in
From: <sip:{{caller}}@ims.airtel.in>;tag=02br0ygx
To: <sip:{{sip_number}}@ims.airtel.in>
CSeq: 1 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0
-- Executing [{{sip_number}}@from-external:1] Goto("PJSIP/airtel-00000002", "forward-to-mobile,s,1") in new stack
-- Goto (forward-to-mobile,s,1)
-- Executing [s@forward-to-mobile:1] Dial("PJSIP/airtel-00000002", "PJSIP/{{mobile_number}}@airtel,40") in new stack
-- Called PJSIP/{{mobile_number}}@airtel
<--- Transmitting SIP request (927 bytes) to UDP:10.232.139.146:5060 --->
INVITE sip:{{mobile_number}}@ims.airtel.in SIP/2.0
Via: SIP/2.0/UDP 100.120.68.206:5060;rport;branch=z9hG4bKPj6259add8-76df-4e0a-8250-40823af4346c
From: <sip:{{caller}}@192.168.0.152>;tag=eac85f37-7818-487b-853c-5e9a922a5415
To: <sip:{{mobile_number}}@ims.airtel.in>
Contact: <sip:asterisk@100.120.68.206:5060>
Call-ID: 23d81fe1-0ba2-4042-8329-564283cfbfe3
CSeq: 32465 INVITE
Allow: OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, REFER, MESSAGE
Supported: 100rel, timer, replaces, norefersub
Session-Expires: 1800
Min-SE: 90
Max-Forwards: 70
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Type: application/sdp
Content-Length: 239
v=0
o=- 300513503 300513503 IN IP4 100.120.68.206
s=Asterisk
c=IN IP4 100.120.68.206
t=0 0
m=audio 15786 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv
<--- Received SIP response (327 bytes) from UDP:10.232.139.146:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 100.120.68.206:5060;branch=z9hG4bKPj6259add8-76df-4e0a-8250-40823af4346c;rport=5060
Call-ID: 23d81fe1-0ba2-4042-8329-564283cfbfe3
From: <sip:{{caller}}@192.168.0.152>;tag=eac85f37-7818-487b-853c-5e9a922a5415
To: <sip:{{mobile_number}}@ims.airtel.in>
CSeq: 32465 INVITE
Content-Length: 0
<--- Received SIP response (437 bytes) from UDP:10.232.139.146:5060 --->
SIP/2.0 604 Does Not Exist Anywhere
Via: SIP/2.0/UDP 100.120.68.206:5060;branch=z9hG4bKPj6259add8-76df-4e0a-8250-40823af4346c;rport=5060
Call-ID: 23d81fe1-0ba2-4042-8329-564283cfbfe3
From: <sip:{{caller}}@192.168.0.152>;tag=eac85f37-7818-487b-853c-5e9a922a5415
To: <sip:{{mobile_number}}@ims.airtel.in>;tag=j98cqbxb
CSeq: 32465 INVITE
Warning: 399 5244.683.B.261.5.30.0.14.24839.0.0.ims.airtel.in "Unknown caller"
Content-Length: 0
<--- Transmitting SIP request (422 bytes) to UDP:10.232.139.146:5060 --->
ACK sip:{{mobile_number}}@ims.airtel.in SIP/2.0
Via: SIP/2.0/UDP 100.120.68.206:5060;rport;branch=z9hG4bKPj6259add8-76df-4e0a-8250-40823af4346c
From: <sip:{{caller}}@192.168.0.152>;tag=eac85f37-7818-487b-853c-5e9a922a5415
To: <sip:{{mobile_number}}@ims.airtel.in>;tag=j98cqbxb
Call-ID: 23d81fe1-0ba2-4042-8329-564283cfbfe3
CSeq: 32465 ACK
Max-Forwards: 70
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0
== Everyone is busy/congested at this time (1:0/0/1)
-- Executing [s@forward-to-mobile:2] Hangup("PJSIP/airtel-00000002", "") in new stack
== Spawn extension (forward-to-mobile, s, 2) exited non-zero on 'PJSIP/airtel-00000002'
<--- Transmitting SIP response (479 bytes) to UDP:10.232.139.146:5060 --->
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 10.232.139.146:5060;rport=5060;received=10.232.139.146;branch=z9hG4bK1t0sfp5ht7h45h3h41r55trpt;Role=3;Hpt=8fc2_36;TRC=ffffffff-ffffffff
Call-ID: asbc7k618m4n5gmz8ku8qqn6mnukuh76qg97@B.5.42.ims.airtel.in
From: <sip:{{caller}}@ims.airtel.in>;tag=02br0ygx
To: <sip:{{sip_number}}@ims.airtel.in>;tag=63a807a4-4629-4266-967d-444b6e3d4731
CSeq: 1 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Reason: Q.850;cause=1
Content-Length: 0
<--- Received SIP request (413 bytes) from UDP:10.232.139.146:5060 --->
ACK sip:{{sip_number}}@ims.airtel.in SIP/2.0
Via: SIP/2.0/UDP 10.232.139.146:5060;branch=z9hG4bK1t0sfp5ht7h45h3h41r55trpt;Role=3;Hpt=8fc2_36;TRC=ffffffff-ffffffff
Call-ID: asbc7k618m4n5gmz8ku8qqn6mnukuh76qg97@B.5.42.ims.airtel.in
From: <sip:{{caller}}@ims.airtel.in>;tag=02br0ygx
To: <sip:{{sip_number}}@ims.airtel.in>;tag=63a807a4-4629-4266-967d-444b6e3d4731
CSeq: 1 ACK
Max-Forwards: 70
Content-Length: 0
However my mobile number is not busy and has complete network signals. What could I have been going wrong here?