Trunk issue- zap and IAX

Discussion in 'General' started by tfunk, Jun 23, 2008.

  1. tfunk

    Joined:
    Jun 22, 2008
    Messages:
    17
    Likes Received:
    0
    Hi All,

    I'm working on replacing current PBXIF system w/ Elastix, but I'm having real trouble getting the trunks to work.

    I have two IAX2 trunks and 1 zaptel trunk.

    The system worked great using the other software, so I believe the trunks (on the provider end) and firewall, etc are okay (or the other system wouldn't work)

    Also, the zap channel isn't working either.

    I'm hoping I'm just missing something silly.

    Anytime I try to dial out I with the verbosity set to 13 I can see it hitting the trunk, but then I see an error about the channel being unavailable.

    I spent several hours working with the VoIP provider thinking it was something on their end, but if I shut this system off, and power the old one back up everything works.

    Here is some debug output from a sample call out of one of the IAX trunks...(the phone number dialed has been changed to a false number ;)


    elastix*CLI>
    -- Executing [82222222@from-internal:1] Macro("SIP/5001-09d9fda0", "dialout-trunk|2|2222222||") in new stack
    -- Executing [s@macro-dialout-trunk:1] Set("SIP/5001-09d9fda0", "DIAL_TRUNK=2") in new stack
    -- Executing [s@macro-dialout-trunk:2] Set("SIP/5001-09d9fda0", "DIAL_NUMBER=2222222") in new stack
    -- Executing [s@macro-dialout-trunk:3] Set("SIP/5001-09d9fda0", "ROUTE_PASSWD=") in new stack
    -- Executing [s@macro-dialout-trunk:4] GotoIf("SIP/5001-09d9fda0", "1?noauth") in new stack
    -- Goto (macro-dialout-trunk,s,6)
    -- Executing [s@macro-dialout-trunk:6] GotoIf("SIP/5001-09d9fda0", "0?disabletrunk|1") in new stack
    -- Executing [s@macro-dialout-trunk:7] Set("SIP/5001-09d9fda0", "_NODEST=") in new stack
    -- Executing [s@macro-dialout-trunk:8] Set("SIP/5001-09d9fda0", "DIAL_TRUNK_OPTIONS=tr") in new stack
    -- Executing [s@macro-dialout-trunk:9] Set("SIP/5001-09d9fda0", "GROUP()=OUT_2") in new stack
    -- Executing [s@macro-dialout-trunk:10] Macro("SIP/5001-09d9fda0", "user-callerid|SKIPTTL") in new stack
    -- Executing [s@macro-user-callerid:1] NoOp("SIP/5001-09d9fda0", "user-callerid: device 5001") in new stack
    -- Executing [s@macro-user-callerid:2] Set("SIP/5001-09d9fda0", "AMPUSER=5001") in new stack
    -- Executing [s@macro-user-callerid:3] GotoIf("SIP/5001-09d9fda0", "0?report") in new stack
    -- Executing [s@macro-user-callerid:4] GotoIf("SIP/5001-09d9fda0", "0?start") in new stack
    -- Executing [s@macro-user-callerid:5] Set("SIP/5001-09d9fda0", "REALCALLERIDNUM=5001") in new stack
    -- Executing [s@macro-user-callerid:6] NoOp("SIP/5001-09d9fda0", "REALCALLERIDNUM is 5001") in new stack
    -- Executing [s@macro-user-callerid:7] Set("SIP/5001-09d9fda0", "AMPUSER=5001") in new stack
    -- Executing [s@macro-user-callerid:8] Set("SIP/5001-09d9fda0", "AMPUSERCIDNAME=5001") in new stack
    -- Executing [s@macro-user-callerid:9] GotoIf("SIP/5001-09d9fda0", "0?report") in new stack
    -- Executing [s@macro-user-callerid:10] Set("SIP/5001-09d9fda0", "AMPUSERCID=5001") in new stack
    -- Executing [s@macro-user-callerid:11] Set("SIP/5001-09d9fda0", "CALLERID(all)="5001" <5001>") in new stack
    -- Executing [s@macro-user-callerid:12] Set("SIP/5001-09d9fda0", "REALCALLERIDNUM=5001") in new stack
    -- Executing [s@macro-user-callerid:13] NoOp("SIP/5001-09d9fda0", "TTL: ARG1: SKIPTTL") in new stack
    -- Executing [s@macro-user-callerid:14] GotoIf("SIP/5001-09d9fda0", "1?continue") in new stack
    -- Goto (macro-user-callerid,s,23)
    -- Executing [s@macro-user-callerid:23] NoOp("SIP/5001-09d9fda0", "Using CallerID "5001" <5001>") in new stack
    -- Executing [s@macro-dialout-trunk:11] Macro("SIP/5001-09d9fda0", "record-enable|5001|OUT") in new stack
    -- Executing [s@macro-record-enable:1] GotoIf("SIP/5001-09d9fda0", "0?2:4") in new stack
    -- Goto (macro-record-enable,s,4)
    -- Executing [s@macro-record-enable:4] AGI("SIP/5001-09d9fda0", "recordingcheck|20080622-103614|1214145373.8") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
    recordingcheck|20080622-103614|1214145373.8: Outbound recording not enabled
    -- AGI Script recordingcheck completed, returning 0
    -- Executing [s@macro-record-enable:5] NoOp("SIP/5001-09d9fda0", "No recording needed") in new stack
    -- Executing [s@macro-dialout-trunk:12] GotoIf("SIP/5001-09d9fda0", "0?skipoutcid") in new stack
    -- Executing [s@macro-dialout-trunk:13] Set("SIP/5001-09d9fda0", "DIAL_TRUNK_OPTIONS=") in new stack
    -- Executing [s@macro-dialout-trunk:14] Macro("SIP/5001-09d9fda0", "outbound-callerid|2") in new stack
    -- Executing [s@macro-outbound-callerid:1] GotoIf("SIP/5001-09d9fda0", "1?start") in new stack
    -- Goto (macro-outbound-callerid,s,3)
    -- Executing [s@macro-outbound-callerid:3] NoOp("SIP/5001-09d9fda0", "REALCALLERIDNUM is 5001") in new stack
    -- Executing [s@macro-outbound-callerid:4] GotoIf("SIP/5001-09d9fda0", "1?normcid") in new stack
    -- Goto (macro-outbound-callerid,s,9)
    -- Executing [s@macro-outbound-callerid:9] Set("SIP/5001-09d9fda0", "USEROUTCID=") in new stack
    -- Executing [s@macro-outbound-callerid:10] Set("SIP/5001-09d9fda0", "EMERGENCYCID=") in new stack
    -- Executing [s@macro-outbound-callerid:11] Set("SIP/5001-09d9fda0", "TRUNKOUTCID="NAME" <3173333333>") in new stack
    -- Executing [s@macro-outbound-callerid:12] GotoIf("SIP/5001-09d9fda0", "1?trunkcid") in new stack
    -- Goto (macro-outbound-callerid,s,16)
    -- Executing [s@macro-outbound-callerid:16] GotoIf("SIP/5001-09d9fda0", "0?usercid") in new stack
    -- Executing [s@macro-outbound-callerid:17] Set("SIP/5001-09d9fda0", "CALLERID(all)=NAME <3173333333>") in new stack
    -- Executing [s@macro-outbound-callerid:18] GotoIf("SIP/5001-09d9fda0", "1?report") in new stack
    -- Goto (macro-outbound-callerid,s,22)
    -- Executing [s@macro-outbound-callerid:22] NoOp("SIP/5001-09d9fda0", "CallerID set to "Name" <3173333333>") in new stack
    -- Executing [s@macro-dialout-trunk:15] GotoIf("SIP/5001-09d9fda0", "0?nomax") in new stack
    -- Executing [s@macro-dialout-trunk:16] GotoIf("SIP/5001-09d9fda0", "0?chanfull") in new stack
    -- Executing [s@macro-dialout-trunk:17] AGI("SIP/5001-09d9fda0", "fixlocalprefix") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
    > fixlocalprefix: Using pattern 1NXXNXXXXXX
    > fixlocalprefix: Using pattern 1+NXXNXXXXXX
    > fixlocalprefix: Using pattern 1317+NXXXXXX
    == fixlocalprefix: Dialpattern 1317+NXXXXXX matched. 2222222 -> 13172222222
    -- AGI Script fixlocalprefix completed, returning 0
    -- Executing [s@macro-dialout-trunk:18] Set("SIP/5001-09d9fda0", "OUTNUM=13172222222") in new stack
    -- Executing [s@macro-dialout-trunk:19] Set("SIP/5001-09d9fda0", "custom=IAX2/voipstreet") in new stack
    -- Executing [s@macro-dialout-trunk:20] GotoIf("SIP/5001-09d9fda0", "1?gocall") in new stack
    -- Goto (macro-dialout-trunk,s,24)
    -- Executing [s@macro-dialout-trunk:24] GotoIf("SIP/5001-09d9fda0", "0?customtrunk") in new stack
    -- Executing [s@macro-dialout-trunk:25] Dial("SIP/5001-09d9fda0", "IAX2/voipstreet/13172222222|300|") in new stack
    == Everyone is busy/congested at this time (1:0/0/1)
    -- Executing [s@macro-dialout-trunk:26] Goto("SIP/5001-09d9fda0", "s-CHANUNAVAIL|1") in new stack
    -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,1)
    -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:1] GotoIf("SIP/5001-09d9fda0", "1?noreport") in new stack
    -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,3)
    -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:3] NoOp("SIP/5001-09d9fda0", "TRUNK Dial failed due to CHANUNAVAIL - failing through to other trunks") in new stack
    -- Executing [82222222@from-internal:2] Macro("SIP/5001-09d9fda0", "outisbusy|") in new stack
    -- Executing [s@macro-outisbusy:1] Playback("SIP/5001-09d9fda0", "all-circuits-busy-now|noanswer") in new stack
    -- <SIP/5001-09d9fda0> Playing 'all-circuits-busy-now' (language 'en')
    == Spawn extension (macro-outisbusy, s, 1) exited non-zero on 'SIP/5001-09d9fda0' in macro 'outisbusy'
    == Spawn extension (macro-outisbusy, s, 1) exited non-zero on 'SIP/5001-09d9fda0'
    elastix*CLI>





    Here is the same debug output when trying to dial out of the pots line...



    elastix*CLI>
    -- Executing [72222222@from-internal:1] Macro("SIP/5001-09d9fda0", "dialout-trunk|1|2222222||") in new stack
    -- Executing [s@macro-dialout-trunk:1] Set("SIP/5001-09d9fda0", "DIAL_TRUNK=1") in new stack
    -- Executing [s@macro-dialout-trunk:2] Set("SIP/5001-09d9fda0", "DIAL_NUMBER=2222222") in new stack
    -- Executing [s@macro-dialout-trunk:3] Set("SIP/5001-09d9fda0", "ROUTE_PASSWD=") in new stack
    -- Executing [s@macro-dialout-trunk:4] GotoIf("SIP/5001-09d9fda0", "1?noauth") in new stack
    -- Goto (macro-dialout-trunk,s,6)
    -- Executing [s@macro-dialout-trunk:6] GotoIf("SIP/5001-09d9fda0", "0?disabletrunk|1") in new stack
    -- Executing [s@macro-dialout-trunk:7] Set("SIP/5001-09d9fda0", "_NODEST=") in new stack
    -- Executing [s@macro-dialout-trunk:8] Set("SIP/5001-09d9fda0", "DIAL_TRUNK_OPTIONS=tr") in new stack
    -- Executing [s@macro-dialout-trunk:9] Set("SIP/5001-09d9fda0", "GROUP()=OUT_1") in new stack
    -- Executing [s@macro-dialout-trunk:10] Macro("SIP/5001-09d9fda0", "user-callerid|SKIPTTL") in new stack
    -- Executing [s@macro-user-callerid:1] NoOp("SIP/5001-09d9fda0", "user-callerid: device 5001") in new stack
    -- Executing [s@macro-user-callerid:2] Set("SIP/5001-09d9fda0", "AMPUSER=5001") in new stack
    -- Executing [s@macro-user-callerid:3] GotoIf("SIP/5001-09d9fda0", "0?report") in new stack
    -- Executing [s@macro-user-callerid:4] GotoIf("SIP/5001-09d9fda0", "0?start") in new stack
    -- Executing [s@macro-user-callerid:5] Set("SIP/5001-09d9fda0", "REALCALLERIDNUM=5001") in new stack
    -- Executing [s@macro-user-callerid:6] NoOp("SIP/5001-09d9fda0", "REALCALLERIDNUM is 5001") in new stack
    -- Executing [s@macro-user-callerid:7] Set("SIP/5001-09d9fda0", "AMPUSER=5001") in new stack
    -- Executing [s@macro-user-callerid:8] Set("SIP/5001-09d9fda0", "AMPUSERCIDNAME=5001") in new stack
    -- Executing [s@macro-user-callerid:9] GotoIf("SIP/5001-09d9fda0", "0?report") in new stack
    -- Executing [s@macro-user-callerid:10] Set("SIP/5001-09d9fda0", "AMPUSERCID=5001") in new stack
    -- Executing [s@macro-user-callerid:11] Set("SIP/5001-09d9fda0", "CALLERID(all)="5001" <5001>") in new stack
    -- Executing [s@macro-user-callerid:12] Set("SIP/5001-09d9fda0", "REALCALLERIDNUM=5001") in new stack
    -- Executing [s@macro-user-callerid:13] NoOp("SIP/5001-09d9fda0", "TTL: ARG1: SKIPTTL") in new stack
    -- Executing [s@macro-user-callerid:14] GotoIf("SIP/5001-09d9fda0", "1?continue") in new stack
    -- Goto (macro-user-callerid,s,23)
    -- Executing [s@macro-user-callerid:23] NoOp("SIP/5001-09d9fda0", "Using CallerID "5001" <5001>") in new stack
    -- Executing [s@macro-dialout-trunk:11] Macro("SIP/5001-09d9fda0", "record-enable|5001|OUT") in new stack
    -- Executing [s@macro-record-enable:1] GotoIf("SIP/5001-09d9fda0", "0?2:4") in new stack
    -- Goto (macro-record-enable,s,4)
    -- Executing [s@macro-record-enable:4] AGI("SIP/5001-09d9fda0", "recordingcheck|20080622-103537|1214145337.7") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
    recordingcheck|20080622-103537|1214145337.7: Outbound recording not enabled
    -- AGI Script recordingcheck completed, returning 0
    -- Executing [s@macro-record-enable:5] NoOp("SIP/5001-09d9fda0", "No recording needed") in new stack
    -- Executing [s@macro-dialout-trunk:12] GotoIf("SIP/5001-09d9fda0", "0?skipoutcid") in new stack
    -- Executing [s@macro-dialout-trunk:13] Set("SIP/5001-09d9fda0", "DIAL_TRUNK_OPTIONS=") in new stack
    -- Executing [s@macro-dialout-trunk:14] Macro("SIP/5001-09d9fda0", "outbound-callerid|1") in new stack
    -- Executing [s@macro-outbound-callerid:1] GotoIf("SIP/5001-09d9fda0", "1?start") in new stack
    -- Goto (macro-outbound-callerid,s,3)
    -- Executing [s@macro-outbound-callerid:3] NoOp("SIP/5001-09d9fda0", "REALCALLERIDNUM is 5001") in new stack
    -- Executing [s@macro-outbound-callerid:4] GotoIf("SIP/5001-09d9fda0", "1?normcid") in new stack
    -- Goto (macro-outbound-callerid,s,9)
    -- Executing [s@macro-outbound-callerid:9] Set("SIP/5001-09d9fda0", "USEROUTCID=") in new stack
    -- Executing [s@macro-outbound-callerid:10] Set("SIP/5001-09d9fda0", "EMERGENCYCID=") in new stack
    -- Executing [s@macro-outbound-callerid:11] Set("SIP/5001-09d9fda0", "TRUNKOUTCID=") in new stack
    -- Executing [s@macro-outbound-callerid:12] GotoIf("SIP/5001-09d9fda0", "1?trunkcid") in new stack
    -- Goto (macro-outbound-callerid,s,16)
    -- Executing [s@macro-outbound-callerid:16] GotoIf("SIP/5001-09d9fda0", "1?usercid") in new stack
    -- Goto (macro-outbound-callerid,s,18)
    -- Executing [s@macro-outbound-callerid:18] GotoIf("SIP/5001-09d9fda0", "1?report") in new stack
    -- Goto (macro-outbound-callerid,s,22)
    -- Executing [s@macro-outbound-callerid:22] NoOp("SIP/5001-09d9fda0", "CallerID set to "5001" <5001>") in new stack
    -- Executing [s@macro-dialout-trunk:15] GotoIf("SIP/5001-09d9fda0", "1?nomax") in new stack
    -- Goto (macro-dialout-trunk,s,17)
    -- Executing [s@macro-dialout-trunk:17] AGI("SIP/5001-09d9fda0", "fixlocalprefix") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
    -- AGI Script fixlocalprefix completed, returning 0
    -- Executing [s@macro-dialout-trunk:18] Set("SIP/5001-09d9fda0", "OUTNUM=2222222") in new stack
    -- Executing [s@macro-dialout-trunk:19] Set("SIP/5001-09d9fda0", "custom=ZAP/g0") in new stack
    -- Executing [s@macro-dialout-trunk:20] GotoIf("SIP/5001-09d9fda0", "1?gocall") in new stack
    -- Goto (macro-dialout-trunk,s,24)
    -- Executing [s@macro-dialout-trunk:24] GotoIf("SIP/5001-09d9fda0", "0?customtrunk") in new stack
    -- Executing [s@macro-dialout-trunk:25] Dial("SIP/5001-09d9fda0", "ZAP/g0/2222222|300|") in new stack
    == Everyone is busy/congested at this time (1:0/0/1)
    -- Executing [s@macro-dialout-trunk:26] Goto("SIP/5001-09d9fda0", "s-CHANUNAVAIL|1") in new stack
    -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,1)
    -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:1] GotoIf("SIP/5001-09d9fda0", "1?noreport") in new stack
    -- Goto (macro-dialout-trunk,s-CHANUNAVAIL,3)
    -- Executing [s-CHANUNAVAIL@macro-dialout-trunk:3] NoOp("SIP/5001-09d9fda0", "TRUNK Dial failed due to CHANUNAVAIL - failing through to other trunks") in new stack
    -- Executing [72222222@from-internal:2] Macro("SIP/5001-09d9fda0", "outisbusy|") in new stack
    -- Executing [s@macro-outisbusy:1] Playback("SIP/5001-09d9fda0", "all-circuits-busy-now|noanswer") in new stack
    -- <SIP/5001-09d9fda0> Playing 'all-circuits-busy-now' (language 'en')
    == Spawn extension (macro-outisbusy, s, 1) exited non-zero on 'SIP/5001-09d9fda0' in macro 'outisbusy'
    == Spawn extension (macro-outisbusy, s, 1) exited non-zero on 'SIP/5001-09d9fda0'
    elastix*CLI>


    I'm sure there is other info that would be helpful, but I'm pretty new to this so I don't know what else to post.

    I would really appreciate it if someone could point me in the right direction!

    Thanks for your help!

    Tfunk
     
  2. Bob

    Bob

    Joined:
    Nov 4, 2007
    Messages:
    2,400
    Likes Received:
    1
    Can you post you trunk info for VoipStreet (what you have in the Freepbx GUI. Just remember to replace your User Account and Secret with UUUUUU & SSSSSS respectively.

    Also under the CLI, (asterisk -r -vvvvvvvvvvv) can you provide the output using this command

    iax2 show registry

    provide the output, replacing again, your account code with the UUUUUU

    This will provide a start on the VoIP side of things...

    Now on the ZAP side, can you provide a copy of the /etc/zaptel.conf and also the relevant part of the /etc/asterisk/zapata-channels.conf (if it is short enough provide the whole thing - otherwise just the part that shows each channel).

    Then we can start analysing....

    Regards
    Bob
     
  3. tfunk

    Joined:
    Jun 22, 2008
    Messages:
    17
    Likes Received:
    0
    Hi Bob,

    Thanks for your help!

    It appears the problem was with the provider for the IAX issues.

    For the zap issue...Let's just say...you have to pay attention when you plug the phone line in. If you plug it into the LINE port...not the PHONE port.
    <Hanging head in shame>
     

Share This Page