Сменили провайдера, у предыдущего на его стороне было настроено, что бы можно было звонить на 495 без международного кода (т.е. вместо 74951234567 набираем просто 1234567 и соединяемся с 74951234567). У нового провайдера автоматом это не настроено, правильней прописать это в диалплане. Вроде прописал правильно, но номер не подставляется (в логах идет звонок на набранный номер (1234567), а не 74951234567).
Прошу помощи разобраться, почему правило не работает. При этом подмена 8 на 7 работает.
PRIME_BBCODE_SPOILER_SHOW PRIME_BBCODE_SPOILER: Extensions.conf:
[number]
exten => _X.,1,Macro(recording,${CALLERID(num)},${EXTEN}) ;_X., означает, что для ЛЮБЫХ исходящих номеров начинает определятся название файла
exten => _[23]XX,2,Dial(SIP/gagarin/${EXTEN},30,Tt)
exten => 100,2,Dial(SIP/102&SIP/103,30,t&m)
exten => _xxx,2,Dial(SIP/${EXTEN},,t)
exten => _ZXXXXXX,2,Dial(SIP/7495${EXTEN}@number) ;звонок на 495 без кода города
exten => _8XX.,2,Dial(SIP/7${EXTEN:1}@number) ;преобразование 8 в наборе на 7
exten => _7XX.,2,Dial(SIP/${EXTEN}@number) ;без преобразования на россию
exten => _+7X.,2,Dial(SIP/${EXTEN:1}@number) ; преобразование с +7 на 7 (для мобильных)
exten => _X.,2,Dial(SIP/4951283939/${EXTEN})
exten => _X.,3,Hangup()
exten => _X.,1,Macro(recording,${CALLERID(num)},${EXTEN}) ;_X., означает, что для ЛЮБЫХ исходящих номеров начинает определятся название файла
exten => _[23]XX,2,Dial(SIP/gagarin/${EXTEN},30,Tt)
exten => 100,2,Dial(SIP/102&SIP/103,30,t&m)
exten => _xxx,2,Dial(SIP/${EXTEN},,t)
exten => _ZXXXXXX,2,Dial(SIP/7495${EXTEN}@number) ;звонок на 495 без кода города
exten => _8XX.,2,Dial(SIP/7${EXTEN:1}@number) ;преобразование 8 в наборе на 7
exten => _7XX.,2,Dial(SIP/${EXTEN}@number) ;без преобразования на россию
exten => _+7X.,2,Dial(SIP/${EXTEN:1}@number) ; преобразование с +7 на 7 (для мобильных)
exten => _X.,2,Dial(SIP/4951283939/${EXTEN})
exten => _X.,3,Hangup()
PRIME_BBCODE_SPOILER_SHOW PRIME_BBCODE_SPOILER: лог звонка:
== Using SIP RTP CoS mark 5
> 0x7f02ec005520 -- Strict RTP learning after remote address set to: 10.0.10.20:5004
-- Executing [7755888@4951283939:1] Macro("SIP/102-00000085", "recording,102,7755888") in new stack
-- Executing [s@macro-recording:1] GotoIf("SIP/102-00000085", "1?mp3") in new stack
-- Goto (macro-recording,s,3)
-- Executing [s@macro-recording:3] Set("SIP/102-00000085", "fname=1579954477.1107-2020-01-25-15_14-102-7755888") in new stack
-- Executing [s@macro-recording:4] Set("SIP/102-00000085", "monopt=nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"") in new stack
-- Executing [s@macro-recording:5] Set("SIP/102-00000085", "CDR(filename)=1579954477.1107-2020-01-25-15_14-102-7755888.mp3") in new stack
-- Executing [s@macro-recording:6] Set("SIP/102-00000085", "CDR(realdst)=7755888") in new stack
-- Executing [s@macro-recording:7] Set("SIP/102-00000085", "CDR(remoteip)=10.0.10.20") in new stack
-- Executing [s@macro-recording:8] MixMonitor("SIP/102-00000085", "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav,b,nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"") in new stack
== Begin MixMonitor Recording SIP/102-00000085
-- Executing [s@macro-recording:9] Goto("SIP/102-00000085", "no") in new stack
-- Goto (macro-recording,s,16)
-- Executing [s@macro-recording:16] Verbose("SIP/102-00000085", "Exit record") in new stack
Exit record
-- Executing [7755888@4951283939:2] Dial("SIP/102-00000085", "SIP/7755888@4951283939") in new stack
== Using SIP RTP CoS mark 5
-- Called SIP/7755888@4951283939
-- Got SIP response 486 "Busy" back from 185.45.152.161:5060
-- SIP/4951283939-00000086 is busy
== Everyone is busy/congested at this time (1:1/0/0)
-- Executing [7755888@4951283939:3] Hangup("SIP/102-00000085", "") in new stack
== Spawn extension (4951283939, 7755888, 3) exited non-zero on 'SIP/102-00000085'
== MixMonitor close filestream (mixed)
== Executing [nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"]
== End MixMonitor Recording SIP/102-00000085
> 0x7f02ec005520 -- Strict RTP learning after remote address set to: 10.0.10.20:5004
-- Executing [7755888@4951283939:1] Macro("SIP/102-00000085", "recording,102,7755888") in new stack
-- Executing [s@macro-recording:1] GotoIf("SIP/102-00000085", "1?mp3") in new stack
-- Goto (macro-recording,s,3)
-- Executing [s@macro-recording:3] Set("SIP/102-00000085", "fname=1579954477.1107-2020-01-25-15_14-102-7755888") in new stack
-- Executing [s@macro-recording:4] Set("SIP/102-00000085", "monopt=nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"") in new stack
-- Executing [s@macro-recording:5] Set("SIP/102-00000085", "CDR(filename)=1579954477.1107-2020-01-25-15_14-102-7755888.mp3") in new stack
-- Executing [s@macro-recording:6] Set("SIP/102-00000085", "CDR(realdst)=7755888") in new stack
-- Executing [s@macro-recording:7] Set("SIP/102-00000085", "CDR(remoteip)=10.0.10.20") in new stack
-- Executing [s@macro-recording:8] MixMonitor("SIP/102-00000085", "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav,b,nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"") in new stack
== Begin MixMonitor Recording SIP/102-00000085
-- Executing [s@macro-recording:9] Goto("SIP/102-00000085", "no") in new stack
-- Goto (macro-recording,s,16)
-- Executing [s@macro-recording:16] Verbose("SIP/102-00000085", "Exit record") in new stack
Exit record
-- Executing [7755888@4951283939:2] Dial("SIP/102-00000085", "SIP/7755888@4951283939") in new stack
== Using SIP RTP CoS mark 5
-- Called SIP/7755888@4951283939
-- Got SIP response 486 "Busy" back from 185.45.152.161:5060
-- SIP/4951283939-00000086 is busy
== Everyone is busy/congested at this time (1:1/0/0)
-- Executing [7755888@4951283939:3] Hangup("SIP/102-00000085", "") in new stack
== Spawn extension (4951283939, 7755888, 3) exited non-zero on 'SIP/102-00000085'
== MixMonitor close filestream (mixed)
== Executing [nice -n 19 /usr/bin/lame -b 32 --silent "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3" && rm -f "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.wav" && chmod o+r "/records/callrecords/1579954477.1107-2020-01-25-15_14-102-7755888.mp3"]
== End MixMonitor Recording SIP/102-00000085
Спасибо!