Прошу помощи, т.к. листал форум, рылся в конфигах, ничего не получилось.
Вопрос простой: есть 3 сип транка с 10 дол каждый.
Звонить они должны по порядку- закончились деньги на первом, включился в работу второй и т.д.
Я думал, что freepbx способен обрабатывать такую операцию довольно легко. Мне казалось, что в исходящий маршрут в freepbx нужно включить все эти три транка и он их будет выбирать по порядку.
На деле если при вызове номера первый транк отказывается работать по причине отсутствия денег, то на второй не перескакивает.
Пробовал и другой вариант- создаю 3 исходящих маршрута и каждому прописываю по одному транку. Происходит то же самое- первый, на котором закончились деньги дает отказ, второй не включается в работу.
Кто ни будь сталкивался с подобными проблемами?
Заранее спасибо.
Код прилагается:
ОБЩАЯ ЧАСТЬ:
Код: Выделить всё
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
-- Executing [19108874449@from-internal:1] Macro("SIP/300-0000000e", "user-callerid,SKIPTTL,") in new stack
-- Executing [s@macro-user-callerid:1] Set("SIP/300-0000000e", "AMPUSER=300") in new stack
-- Executing [s@macro-user-callerid:2] GotoIf("SIP/300-0000000e", "0?report") in new stack
-- Executing [s@macro-user-callerid:3] ExecIf("SIP/300-0000000e", "1?Set(REALCALLERIDNUM=300)") in new stack
-- Executing [s@macro-user-callerid:4] Set("SIP/300-0000000e", "AMPUSER=300") in new stack
-- Executing [s@macro-user-callerid:5] Set("SIP/300-0000000e", "AMPUSERCIDNAME=User1") in new stack
-- Executing [s@macro-user-callerid:6] GotoIf("SIP/300-0000000e", "0?report") in new stack
-- Executing [s@macro-user-callerid:7] Set("SIP/300-0000000e", "AMPUSERCID=300") in new stack
-- Executing [s@macro-user-callerid:8] Set("SIP/300-0000000e", "CALLERID(all)="User1" <300>") in new stack
-- Executing [s@macro-user-callerid:9] ExecIf("SIP/300-0000000e", "0?Set(CHANNEL(language)=)") in new stack
-- Executing [s@macro-user-callerid:10] GotoIf("SIP/300-0000000e", "1?continue") in new stack
-- Goto (macro-user-callerid,s,19)
-- Executing [s@macro-user-callerid:19] Set("SIP/300-0000000e", "CALLERID(number)=300") in new stack
-- Executing [s@macro-user-callerid:20] Set("SIP/300-0000000e", "CALLERID(name)=User1") in new stack
-- Executing [s@macro-user-callerid:21] NoOp("SIP/300-0000000e", "Using CallerID "User1" <300>") in new stack
-- Executing [19108874449@from-internal:2] NoOp("SIP/300-0000000e", "Calling Out Route: SipnetTest2") in new stack
-- Executing [19108874449@from-internal:3] Set("SIP/300-0000000e", "MOHCLASS=default") in new stack
-- Executing [19108874449@from-internal:4] Set("SIP/300-0000000e", "_NODEST=") in new stack
-- Executing [19108874449@from-internal:5] Macro("SIP/300-0000000e", "record-enable,300,OUT,") in new stack
-- Executing [s@macro-record-enable:1] GotoIf("SIP/300-0000000e", "1?check") in new stack
-- Goto (macro-record-enable,s,4)
-- Executing [s@macro-record-enable:4] ExecIf("SIP/300-0000000e", "0?MacroExit()") in new stack
-- Executing [s@macro-record-enable:5] GotoIf("SIP/300-0000000e", "0?Group:OUT") in new stack
-- Goto (macro-record-enable,s,15)
-- Executing [s@macro-record-enable:15] GotoIf("SIP/300-0000000e", "0?IN") in new stack
-- Executing [s@macro-record-enable:16] ExecIf("SIP/300-0000000e", "1?MacroExit()") in new stack
-- Executing [19108874449@from-internal:6] Macro("SIP/300-0000000e", "dialout-trunk,6,19108874449,") in new stack
-- Executing [s@macro-dialout-trunk:1] Set("SIP/300-0000000e", "DIAL_TRUNK=6") in new stack
-- Executing [s@macro-dialout-trunk:2] GosubIf("SIP/300-0000000e", "0?sub-pincheck,s,1") in new stack
-- Executing [s@macro-dialout-trunk:3] GotoIf("SIP/300-0000000e", "0?disabletrunk,1") in new stack
-- Executing [s@macro-dialout-trunk:4] Set("SIP/300-0000000e", "DIAL_NUMBER=19108874449") in new stack
-- Executing [s@macro-dialout-trunk:5] Set("SIP/300-0000000e", "DIAL_TRUNK_OPTIONS=tr") in new stack
-- Executing [s@macro-dialout-trunk:6] Set("SIP/300-0000000e", "OUTBOUND_GROUP=OUT_6") in new stack
-- Executing [s@macro-dialout-trunk:7] GotoIf("SIP/300-0000000e", "0?nomax") in new stack
-- Executing [s@macro-dialout-trunk:8] GotoIf("SIP/300-0000000e", "0?chanfull") in new stack
-- Executing [s@macro-dialout-trunk:9] GotoIf("SIP/300-0000000e", "0?skipoutcid") in new stack
-- Executing [s@macro-dialout-trunk:10] Set("SIP/300-0000000e", "DIAL_TRUNK_OPTIONS=") in new stack
-- Executing [s@macro-dialout-trunk:11] Macro("SIP/300-0000000e", "outbound-callerid,6") in new stack
-- Executing [s@macro-outbound-callerid:1] ExecIf("SIP/300-0000000e", "0?Set(CALLERPRES()=)") in new stack
-- Executing [s@macro-outbound-callerid:2] ExecIf("SIP/300-0000000e", "0?Set(REALCALLERIDNUM=300)") in new stack
-- Executing [s@macro-outbound-callerid:3] GotoIf("SIP/300-0000000e", "1?normcid") in new stack
-- Goto (macro-outbound-callerid,s,6)
-- Executing [s@macro-outbound-callerid:6] Set("SIP/300-0000000e", "USEROUTCID=") in new stack
-- Executing [s@macro-outbound-callerid:7] Set("SIP/300-0000000e", "EMERGENCYCID=") in new stack
-- Executing [s@macro-outbound-callerid:8] Set("SIP/300-0000000e", "TRUNKOUTCID=<0035313661>") in new stack
-- Executing [s@macro-outbound-callerid:9] GotoIf("SIP/300-0000000e", "1?trunkcid") in new stack
-- Goto (macro-outbound-callerid,s,12)
-- Executing [s@macro-outbound-callerid:12] ExecIf("SIP/300-0000000e", "1?Set(CALLERID(all)=<0035313661>)") in new stack
-- Executing [s@macro-outbound-callerid:13] ExecIf("SIP/300-0000000e", "0?Set(CALLERID(all)=)") in new stack
-- Executing [s@macro-outbound-callerid:14] ExecIf("SIP/300-0000000e", "0?Set(CALLERID(all)=)") in new stack
-- Executing [s@macro-outbound-callerid:15] ExecIf("SIP/300-0000000e", "0?Set(CALLERPRES()=prohib_passed_screen)") in new stack
-- Executing [s@macro-dialout-trunk:12] GosubIf("SIP/300-0000000e", "1?sub-flp-6,s,1") in new stack
-- Executing [s@sub-flp-6:1] ExecIf("SIP/300-0000000e", "1?Set(TARGET_FLP_6=79108874449)") in new stack
-- Executing [s@sub-flp-6:2] GotoIf("SIP/300-0000000e", "1?match") in new stack
-- Goto (sub-flp-6,s,4)
-- Executing [s@sub-flp-6:4] Set("SIP/300-0000000e", "DIAL_NUMBER=79108874449") in new stack
-- Executing [s@sub-flp-6:5] Return("SIP/300-0000000e", "") in new stack
-- Executing [s@macro-dialout-trunk:13] Set("SIP/300-0000000e", "OUTNUM=79108874449") in new stack
-- Executing [s@macro-dialout-trunk:14] Set("SIP/300-0000000e", "custom=SIP/sip0035313661") in new stack
-- Executing [s@macro-dialout-trunk:15] ExecIf("SIP/300-0000000e", "0?Set(DIAL_TRUNK_OPTIONS=M(setmusic^default))") in new stack
-- Executing [s@macro-dialout-trunk:16] Macro("SIP/300-0000000e", "dialout-trunk-predial-hook,") in new stack
-- Executing [s@macro-dialout-trunk-predial-hook:1] MacroExit("SIP/300-0000000e", "") in new stack
-- Executing [s@macro-dialout-trunk:17] GotoIf("SIP/300-0000000e", "0?bypass,1") in new stack
-- Executing [s@macro-dialout-trunk:18] GotoIf("SIP/300-0000000e", "0?customtrunk") in new stack
-- Executing [s@macro-dialout-trunk:19] Dial("SIP/300-0000000e", "SIP/sip0035313661/79108874449,300,") in new stack
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
Код: Выделить всё
-- Called sip0035313661/79108874449
Код: Выделить всё
-- Called sip0945311/79108874449
-- Got SIP response 603 "Declined" back from 212.53.40.40
-- SIP/sip0945311-00000011 is busy
== Everyone is busy/congested at this time (1:1/0/0)
-- Executing [s@macro-dialout-trunk:20] NoOp("SIP/300-00000010", "Dial failed for some reason with DIALSTATUS = BUSY and HANGUPCAUSE = 21") in new stack
-- Executing [s@macro-dialout-trunk:21] Goto("SIP/300-00000010", "s-BUSY,1") in new stack
-- Goto (macro-dialout-trunk,s-BUSY,1)
-- Executing [s-BUSY@macro-dialout-trunk:1] NoOp("SIP/300-00000010", "Dial failed due to trunk reporting BUSY - giving up") in new stack
-- Executing [s-BUSY@macro-dialout-trunk:2] PlayTones("SIP/300-00000010", "busy") in new stack
-- Executing [s-BUSY@macro-dialout-trunk:3] Busy("SIP/300-00000010", "20") in new stack
== Spawn extension (macro-dialout-trunk, s-BUSY, 3) exited non-zero on 'SIP/300-00000010' in macro 'dialout-trunk'
== Spawn extension (from-internal, 79108874449, 6) exited non-zero on 'SIP/300-00000010'
-- Executing [h@from-internal:1] Macro("SIP/300-00000010", "hangupcall") in new stack
-- Executing [s@macro-hangupcall:1] GotoIf("SIP/300-00000010", "1?skiprg") in new stack
-- Goto (macro-hangupcall,s,4)
-- Executing [s@macro-hangupcall:4] GotoIf("SIP/300-00000010", "1?skipblkvm") in new stack
-- Goto (macro-hangupcall,s,7)
-- Executing [s@macro-hangupcall:7] GotoIf("SIP/300-00000010", "1?theend") in new stack
-- Goto (macro-hangupcall,s,9)
-- Executing [s@macro-hangupcall:9] Hangup("SIP/300-00000010", "") in new stack
== Spawn extension (macro-hangupcall, s, 9) exited non-zero on 'SIP/300-00000010' in macro 'hangupcall'
== Spawn extension (from-internal, h, 1) exited non-zero on 'SIP/300-00000010'