how do i redirect a call

Discussion in 'General' started by mattrh, Jul 9, 2009.

  1. mattrh

    Joined:
    Jul 15, 2008
    Messages:
    175
    Likes Received:
    0
    Hello all,

    ok here is where I am at.

    I have a DID that comes into the elastix system. From that point i need to to call outside they system to an external number. how would i go about doing this.

    i have tried to make an inbound path that connects to a ring group and put the external number in were the extension with a # at the end buit it will not dial out.

    any ideas?

    thnaks
     
  2. biggy213

    Joined:
    May 24, 2009
    Messages:
    40
    Likes Received:
    0
    How is your outbound route? How about your trunking setting?How many channel do you have?
     
  3. mattrh

    Joined:
    Jul 15, 2008
    Messages:
    175
    Likes Received:
    0
    when i press 602 internal it works just doesn't work from the DID.

    outbound route
    1800NXXXXXX
    1866NXXXXXX
    1877NXXXXXX
    1888NXXXXXX
    1NXXNXXXXXX
    NXXNXXXXXX
    NXXXXXX

    trunking setting
    1818+NXXXXXX
    1+NXXNXXXXXX
    1NXXNXXXXXX

    many channel do you have
    12
     
  4. jgutierrez

    Joined:
    Feb 28, 2008
    Messages:
    5,737
    Likes Received:
    0
    Paste the cli output, when you try to do what you want. Have you set on your trunk configuration the option that says: "Never Override CallerID" ? That will help a lot, since voip provider blocks calls when you want to dial out with a CID that your provider hasn't assigned you (If you use that feature, put a valid CID)
     
  5. mattrh

    Joined:
    Jul 15, 2008
    Messages:
    175
    Likes Received:
    0
    i do not have that option selected, i have 100 number on this account and that is not the issue

    Code:
        -- Executing [s@macro-dial:20] NoOp("Zap/1-1", "Returned from dialparties with hunt groups to dial ") in new stack
        -- Executing [s@macro-dial:21] Set("Zap/1-1", "HuntLoop=0") in new stack
        -- Executing [s@macro-dial:22] GotoIf("Zap/1-1", "1?a30") in new stack
        -- Goto (macro-dial,s,26)
        -- Executing [s@macro-dial:26] Set("Zap/1-1", "HuntMember=HuntMember0") in new stack
        -- Executing [s@macro-dial:27] GotoIf("Zap/1-1", "1?a32:a35") in new stack
        -- Goto (macro-dial,s,28)
        -- Executing [s@macro-dial:28] Set("Zap/1-1", "CT_EXTEN=18183957979") in new stack
        -- Executing [s@macro-dial:29] Set("Zap/1-1", "DB(CALLTRACE/18183957979)=8183957979") in new stack
        -- Executing [s@macro-dial:30] Goto("Zap/1-1", "s|a42") in new stack
        -- Goto (macro-dial,s,38)
        -- Executing [s@macro-dial:38] Dial("Zap/1-1", "Local/18183957979@from-internal/n|20|m(rad)tM(auto-blkvm)") in new stack
        -- Called 18183957979@from-internal/n
        -- Started music on hold, class 'rad', on channel 'Zap/1-1'
        -- Executing [18183957979@from-internal:1] Macro("Local/18183957979@from-internal-ba35,2", "user-callerid|SKIPTTL|") in new stack
        -- Executing [s@macro-user-callerid:1] Set("Local/18183957979@from-internal-ba35,2", "AMPUSER=8183957979") in new stack
        -- Executing [s@macro-user-callerid:2] GotoIf("Local/18183957979@from-internal-ba35,2", "1?report") in new stack
        -- Goto (macro-user-callerid,s,11)
        -- Executing [s@macro-user-callerid:11] GotoIf("Local/18183957979@from-internal-ba35,2", "1?continue") in new stack
        -- Goto (macro-user-callerid,s,20)
        -- Executing [s@macro-user-callerid:20] NoOp("Local/18183957979@from-internal-ba35,2", "Using CallerID "8183957979" <8183957979>") in new stack
        -- Executing [18183957979@from-internal:2] Set("Local/18183957979@from-internal-ba35,2", "_NODEST=") in new stack
        -- Executing [18183957979@from-internal:3] Macro("Local/18183957979@from-internal-ba35,2", "record-enable|8183957979|OUT|") in new stack
        -- Executing [s@macro-record-enable:1] GotoIf("Local/18183957979@from-internal-ba35,2", "1?check") in new stack
        -- Goto (macro-record-enable,s,4)
        -- Executing [s@macro-record-enable:4] AGI("Local/18183957979@from-internal-ba35,2", "recordingcheck|20090709-174851|1247186931.36065") in new stack
        -- Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
      recordingcheck|20090709-174851|1247186931.36065: No AMPUSER db entry for 8183957979. Not recording
        -- AGI Script recordingcheck completed, returning 0
        -- Executing [s@macro-record-enable:5] MacroExit("Local/18183957979@from-internal-ba35,2", "") in new stack
        -- Executing [18183957979@from-internal:4] Macro("Local/18183957979@from-internal-ba35,2", "dialout-trunk|1|18183957979||") in new stack
        -- Executing [s@macro-dialout-trunk:1] Set("Local/18183957979@from-internal-ba35,2", "DIAL_TRUNK=1") in new stack
        -- Executing [s@macro-dialout-trunk:2] GosubIf("Local/18183957979@from-internal-ba35,2", "0?sub-pincheck|s|1") in new stack
        -- Executing [s@macro-dialout-trunk:3] GotoIf("Local/18183957979@from-internal-ba35,2", "0?disabletrunk|1") in new stack
        -- Executing [s@macro-dialout-trunk:4] Set("Local/18183957979@from-internal-ba35,2", "DIAL_NUMBER=18183957979") in new stack
        -- Executing [s@macro-dialout-trunk:5] Set("Local/18183957979@from-internal-ba35,2", "DIAL_TRUNK_OPTIONS=tr") in new stack
        -- Executing [s@macro-dialout-trunk:6] Set("Local/18183957979@from-internal-ba35,2", "OUTBOUND_GROUP=OUT_1") in new stack
        -- Executing [s@macro-dialout-trunk:7] GotoIf("Local/18183957979@from-internal-ba35,2", "1?nomax") in new stack
        -- Goto (macro-dialout-trunk,s,9)
        -- Executing [s@macro-dialout-trunk:9] GotoIf("Local/18183957979@from-internal-ba35,2", "0?skipoutcid") in new stack
        -- Executing [s@macro-dialout-trunk:10] Set("Local/18183957979@from-internal-ba35,2", "DIAL_TRUNK_OPTIONS=") in new stack
        -- Executing [s@macro-dialout-trunk:11] Macro("Local/18183957979@from-internal-ba35,2", "outbound-callerid|1") in new stack
        -- Executing [s@macro-outbound-callerid:1] ExecIf("Local/18183957979@from-internal-ba35,2", "1|SetCallerPres|allowed_not_screened") in new stack
        -- Executing [s@macro-outbound-callerid:2] ExecIf("Local/18183957979@from-internal-ba35,2", "1|Set|REALCALLERIDNUM=8183957979") in new stack
        -- Executing [s@macro-outbound-callerid:3] GotoIf("Local/18183957979@from-internal-ba35,2", "0?normcid") in new stack
        -- Executing [s@macro-outbound-callerid:4] Set("Local/18183957979@from-internal-ba35,2", "USEROUTCID=8183957979") in new stack
        -- Executing [s@macro-outbound-callerid:5] GotoIf("Local/18183957979@from-internal-ba35,2", "1?bypass") in new stack
        -- Goto (macro-outbound-callerid,s,7)
        -- Executing [s@macro-outbound-callerid:7] Set("Local/18183957979@from-internal-ba35,2", "EMERGENCYCID=") in new stack
        -- Executing [s@macro-outbound-callerid:8] Set("Local/18183957979@from-internal-ba35,2", "TRUNKOUTCID=8187574555") in new stack
        -- Executing [s@macro-outbound-callerid:9] GotoIf("Local/18183957979@from-internal-ba35,2", "1?trunkcid") in new stack
        -- Goto (macro-outbound-callerid,s,12)
        -- Executing [s@macro-outbound-callerid:12] ExecIf("Local/18183957979@from-internal-ba35,2", "1|Set|CALLERID(all)=8187574555") in new stack
        -- Executing [s@macro-outbound-callerid:13] ExecIf("Local/18183957979@from-internal-ba35,2", "1|Set|CALLERID(all)=8183957979") in new stack
        -- Executing [s@macro-outbound-callerid:14] ExecIf("Local/18183957979@from-internal-ba35,2", "0|SetCallerPres|prohib_passed_screen") in new stack
        -- Executing [s@macro-dialout-trunk:12] ExecIf("Local/18183957979@from-internal-ba35,2", "1|AGI|fixlocalprefix") in new stack
        -- Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
      ==  fixlocalprefix: Dialpattern 1NXXNXXXXXX matched. 18183957979 -> 18183957979
        -- AGI Script fixlocalprefix completed, returning 0
        -- Executing [s@macro-dialout-trunk:13] Set("Local/18183957979@from-internal-ba35,2", "OUTNUM=18183957979") in new stack
        -- Executing [s@macro-dialout-trunk:14] Set("Local/18183957979@from-internal-ba35,2", "custom=ZAP/g0") in new stack
        -- Executing [s@macro-dialout-trunk:15] ExecIf("Local/18183957979@from-internal-ba35,2", "1|Set|DIAL_TRUNK_OPTIONS=M(setmusic^uptemposmoothjazz)") in new stack
        -- Executing [s@macro-dialout-trunk:16] Macro("Local/18183957979@from-internal-ba35,2", "dialout-trunk-predial-hook|") in new stack
        -- Executing [s@macro-dialout-trunk-predial-hook:1] MacroExit("Local/18183957979@from-internal-ba35,2", "") in new stack
        -- Executing [s@macro-dialout-trunk:17] GotoIf("Local/18183957979@from-internal-ba35,2", "0?bypass|1") in new stack
        -- Executing [s@macro-dialout-trunk:18] GotoIf("Local/18183957979@from-internal-ba35,2", "0?customtrunk") in new stack
        -- Executing [s@macro-dialout-trunk:19] Dial("Local/18183957979@from-internal-ba35,2", "ZAP/g0/18183957979|300|M(setmusic^uptemposmoothjazz)") in new stack
        -- Requested transfer capability: 0x00 - SPEECH
        -- Called g0/18183957979
        -- Zap/2-1 is proceeding passing it to Local/18183957979@from-internal-ba35,2
        -- Local/18183957979@from-internal-ba35,1 is proceeding passing it to Zap/1-1
        -- Channel 0/2, span 1 got hangup request, cause 1
        -- Hungup 'Zap/2-1'
      == Everyone is busy/congested at this time (1:0/0/1)
        -- Executing [s@macro-dialout-trunk:20] Goto("Local/18183957979@from-internal-ba35,2", "s-CHANUNAVAIL|1") in new stack
        -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,1)
        -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:1] GotoIf("Local/18183957979@from-internal-ba35,2", "1?noreport") in new stack
        -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,3)
        -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:3] NoOp("Local/18183957979@from-internal-ba35,2", "TRUNK Dial failed due to CHANUNAVAIL (hangupcause: 1) - failing through to other trunks") in new stack
        -- Executing [18183957979@from-internal:5] Macro("Local/18183957979@from-internal-ba35,2", "outisbusy|") in new stack
        -- Executing [s@macro-outisbusy:1] Playback("Local/18183957979@from-internal-ba35,2", "all-circuits-busy-now|noanswer") in new stack
        -- <Local/18183957979@from-internal-ba35,2> Playing 'all-circuits-busy-now' (language 'en')
        -- Executing [s@macro-outisbusy:2] Playback("Local/18183957979@from-internal-ba35,2", "pls-try-call-later|noanswer") in new stack
        -- <Local/18183957979@from-internal-ba35,2> Playing 'pls-try-call-later' (language 'en')
        -- Executing [s@macro-outisbusy:3] Macro("Local/18183957979@from-internal-ba35,2", "hangupcall") in new stack
        -- Executing [s@macro-hangupcall:1] ResetCDR("Local/18183957979@from-internal-ba35,2", "vw") in new stack
        -- Executing [s@macro-hangupcall:2] NoCDR("Local/18183957979@from-internal-ba35,2", "") in new stack
        -- Executing [s@macro-hangupcall:3] GotoIf("Local/18183957979@from-internal-ba35,2", "1?skiprg") in new stack
        -- Goto (macro-hangupcall,s,6)
        -- Executing [s@macro-hangupcall:6] GotoIf("Local/18183957979@from-internal-ba35,2", "1?skipblkvm") in new stack
        -- Goto (macro-hangupcall,s,9)
        -- Executing [s@macro-hangupcall:9] GotoIf("Local/18183957979@from-internal-ba35,2", "1?theend") in new stack
        -- Goto (macro-hangupcall,s,11)
        -- Executing [s@macro-hangupcall:11] Hangup("Local/18183957979@from-internal-ba35,2", "") in new stack
      == Spawn extension (macro-hangupcall, s, 11) exited non-zero on 'Local/18183957979@from-internal-ba35,2' in macro 'hangupcall'
      == Spawn extension (macro-hangupcall, s, 11) exited non-zero on 'Local/18183957979@from-internal-ba35,2' in macro 'outisbusy'
      == Spawn extension (macro-hangupcall, s, 11) exited non-zero on 'Local/18183957979@from-internal-ba35,2'
      == Everyone is busy/congested at this time (1:0/0/1)
        -- Stopped music on hold on Zap/1-1
        -- Executing [s@macro-dial:39] Set("Zap/1-1", "HuntLoop=1") in new stack
        -- Executing [s@macro-dial:40] GotoIf("Zap/1-1", "1?a46") in new stack
        -- Goto (macro-dial,s,42)
        -- Executing [s@macro-dial:42] Set("Zap/1-1", "HuntMembers=2") in new stack
        -- Executing [s@macro-dial:43] Goto("Zap/1-1", "s|a22") in new stack
        -- Goto (macro-dial,s,22)
        -- Executing [s@macro-dial:22] GotoIf("Zap/1-1", "1?a30") in new stack
        -- Goto (macro-dial,s,26)
        -- Executing [s@macro-dial:26] Set("Zap/1-1", "HuntMember=HuntMember1") in new stack
        -- Executing [s@macro-dial:27] GotoIf("Zap/1-1", "1?a32:a35") in new stack
        -- Goto (macro-dial,s,28)
        -- Executing [s@macro-dial:28] Set("Zap/1-1", "CT_EXTEN=4002") in new stack
        -- Executing [s@macro-dial:29] Set("Zap/1-1", "DB(CALLTRACE/4002)=8183957979") in new stack
        -- Executing [s@macro-dial:30] Goto("Zap/1-1", "s|a42") in new stack
        -- Goto (macro-dial,s,38)
        -- Executing [s@macro-dial:38] Dial("Zap/1-1", "SIP/4002|20|m(rad)tM(auto-blkvm)") in new stack
        -- Called 4002
        -- Started music on hold, class 'rad', on channel 'Zap/1-1'
        -- Got SIP response 486 "Busy Here" back from 192.168.0.33
        -- SIP/4002-0988e320 is busy
      == Everyone is busy/congested at this time (1:1/0/0)
        -- Stopped music on hold on Zap/1-1
        -- Executing [s@macro-dial:39] Set("Zap/1-1", "HuntLoop=2") in new stack
        -- Executing [s@macro-dial:40] GotoIf("Zap/1-1", "1?a46") in new stack
        -- Goto (macro-dial,s,42)
        -- Executing [s@macro-dial:42] Set("Zap/1-1", "HuntMembers=1") in new stack
        -- Executing [s@macro-dial:43] Goto("Zap/1-1", "s|a22") in new stack
        -- Goto (macro-dial,s,22)
        -- Executing [s@macro-dial:22] GotoIf("Zap/1-1", "1?a30") in new stack
        -- Goto (macro-dial,s,26)
        -- Executing [s@macro-dial:26] Set("Zap/1-1", "HuntMember=HuntMember2") in new stack
        -- Executing [s@macro-dial:27] GotoIf("Zap/1-1", "1?a32:a35") in new stack
        -- Goto (macro-dial,s,28)
        -- Executing [s@macro-dial:28] Set("Zap/1-1", "CT_EXTEN=4013") in new stack
        -- Executing [s@macro-dial:29] Set("Zap/1-1", "DB(CALLTRACE/4013)=8183957979") in new stack
        -- Executing [s@macro-dial:30] Goto("Zap/1-1", "s|a42") in new stack
        -- Goto (macro-dial,s,38)
        -- Executing [s@macro-dial:38] Dial("Zap/1-1", "SIP/4013|20|m(rad)tM(auto-blkvm)") in new stack
        -- Called 4013
        -- Started music on hold, class 'rad', on channel 'Zap/1-1'
        -- SIP/4013-0985d828 is ringing
    

    so when the nuber is called it should call out 18183957979 but the error is TRUNK Dial failed due to CHANUNAVAIL (hangupcause: 1) - failing through to other trunks
     
  6. mattrh

    Joined:
    Jul 15, 2008
    Messages:
    175
    Likes Received:
    0
    wow i'm a dumb shit! i check the box next to Never Override CallerID, and now it works. thanks for the heads up
     
  7. biggy213

    Joined:
    May 24, 2009
    Messages:
    40
    Likes Received:
    0
    I am glad you got everything working
     

Share This Page