Span 3: Channel 0/1 got hangup, cause 81

Hi Guys,

I have setup a ISDN card that was working fine on a old trixbox. However on the Freepbx after the install, any call that lands gets disconnected and goes into a loop. The call comes in, phone rings for a half a second and cuts off then rings again cuts off. I have noticed its giving > Span 3: Channel 0/1 got hangup, cause 81


Following is what I get on the CLI. Can someone please assist I would be very grateful.
Thanks.
complete log is at pastebin.
http://pastebin.com/NEeuDwtB

 -- Accepting call from '7861111111' to '600000' on channel 0/1, span 3
    -- Executing [600000@from-pstn:1] NoOp("DAHDI/i3/7861111111-5", "Catch-All DID Match - Found 600000 - You probably want a DID for this.") in new stack
    -- Accepting call from '7861111111' to '600000' on channel 0/1, span 4
    -- Executing [600000@from-pstn:1] NoOp("DAHDI/i4/7861111111-5", "Catch-All DID Match - Found 600000 - You probably want a DID for this.") in new stack
    -- Executing [600000@from-pstn:2] Set("DAHDI/i3/7861111111-5", "__FROM_DID=600000") in new stack
    -- Executing [600000@from-pstn:2] Set("DAHDI/i4/7861111111-5", "__FROM_DID=600000") in new stack
    -- Executing [600000@from-pstn:3] Goto("DAHDI/i3/7861111111-5", "ext-did,s,1") in new stack
    -- Executing [600000@from-pstn:3] Goto("DAHDI/i4/7861111111-5", "ext-did,s,1") in new stack
    -- Goto (ext-did,s,1)
    -- Executing [s@ext-did:1] ExecIf("DAHDI/i4/7861111111-5", "0?Set(__FROM_DID=s)") in new stack
    -- Executing [s@ext-did:2] Gosub("DAHDI/i4/7861111111-5", "app-blacklist-check,s,1()") in new stack
    -- Goto (ext-did,s,1)
    -- Executing [s@ext-did:1] ExecIf("DAHDI/i3/7861111111-5", "0?Set(__FROM_DID=s)") in new stack
    -- Executing [s@ext-did:2] Gosub("DAHDI/i3/7861111111-5", "app-blacklist-check,s,1()") in new stack
    -- Executing [s@app-blacklist-check:1] GotoIf("DAHDI/i4/7861111111-5", "0?blacklisted") in new stack
    -- Executing [s@app-blacklist-check:2] Set("DAHDI/i4/7861111111-5", "CALLED_BLACKLIST=1") in new stack
    -- Executing [s@app-blacklist-check:1] GotoIf("DAHDI/i3/7861111111-5", "0?blacklisted") in new stack
    -- Executing [s@app-blacklist-check:3] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [s@app-blacklist-check:2] Set("DAHDI/i3/7861111111-5", "CALLED_BLACKLIST=1") in new stack
    -- Executing [s@ext-did:3] Set("DAHDI/i4/7861111111-5", "CDR(did)=600000") in new stack
    -- Executing [s@ext-did:4] ExecIf("DAHDI/i4/7861111111-5", "1 ?Set(CALLERID(name)=7861111111)") in new stack
    -- Executing [s@ext-did:5] Set("DAHDI/i4/7861111111-5", "CHANNEL(musicclass)=default") in new stack
    -- Executing [s@ext-did:6] Set("DAHDI/i4/7861111111-5", "__MOHCLASS=default") in new stack
    -- Executing [s@ext-did:7] Set("DAHDI/i4/7861111111-5", "__CALLINGPRES_SV=allowed") in new stack
    -- Executing [s@ext-did:8] Set("DAHDI/i4/7861111111-5", "CALLERPRES()=allowed_not_screened") in new stack
    -- Executing [s@ext-did:9] Goto("DAHDI/i4/7861111111-5", "from-did-direct,2002,1") in new stack
    -- Goto (from-did-direct,2002,1)
    -- Executing [s@app-blacklist-check:3] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [s@ext-did:3] Set("DAHDI/i3/7861111111-5", "CDR(did)=600000") in new stack
    -- Executing [s@ext-did:4] ExecIf("DAHDI/i3/7861111111-5", "1 ?Set(CALLERID(name)=7861111111)") in new stack
    -- Executing [2002@from-did-direct:1] Set("DAHDI/i4/7861111111-5", "__RINGTIMER=15") in new stack
    -- Executing [s@ext-did:5] Set("DAHDI/i3/7861111111-5", "CHANNEL(musicclass)=default") in new stack
    -- Executing [2002@from-did-direct:2] Macro("DAHDI/i4/7861111111-5", "exten-vm,novm,2002,0,0,0") in new stack
    -- Executing [s@ext-did:6] Set("DAHDI/i3/7861111111-5", "__MOHCLASS=default") in new stack
    -- Executing [s@ext-did:7] Set("DAHDI/i3/7861111111-5", "__CALLINGPRES_SV=allowed") in new stack
    -- Executing [s@ext-did:8] Set("DAHDI/i3/7861111111-5", "CALLERPRES()=allowed_not_screened") in new stack
    -- Executing [s@macro-exten-vm:1] Macro("DAHDI/i4/7861111111-5", "user-callerid,") in new stack
    -- Executing [s@ext-did:9] Goto("DAHDI/i3/7861111111-5", "from-did-direct,2002,1") in new stack
    -- Goto (from-did-direct,2002,1)
    -- Executing [2002@from-did-direct:1] Set("DAHDI/i3/7861111111-5", "__RINGTIMER=15") in new stack
    -- Executing [2002@from-did-direct:2] Macro("DAHDI/i3/7861111111-5", "exten-vm,novm,2002,0,0,0") in new stack
    -- Executing [s@macro-exten-vm:1] Macro("DAHDI/i3/7861111111-5", "user-callerid,") in new stack
    -- Executing [s@macro-user-callerid:1] Set("DAHDI/i3/7861111111-5", "TOUCH_MONITOR=1167612930.20") in new stack
    -- Executing [s@macro-user-callerid:2] Set("DAHDI/i3/7861111111-5", "AMPUSER=7861111111") in new stack
    -- Executing [s@macro-user-callerid:3] GotoIf("DAHDI/i3/7861111111-5", "0?report") in new stack
    -- Executing [s@macro-user-callerid:4] ExecIf("DAHDI/i3/7861111111-5", "1?Set(REALCALLERIDNUM=7861111111)") in new stack
    -- Executing [s@macro-user-callerid:5] Set("DAHDI/i3/7861111111-5", "AMPUSER=") in new stack
    -- Executing [s@macro-user-callerid:6] GotoIf("DAHDI/i3/7861111111-5", "0?limit") in new stack
    -- Executing [s@macro-user-callerid:7] Set("DAHDI/i3/7861111111-5", "AMPUSERCIDNAME=") in new stack
    -- Executing [s@macro-user-callerid:8] GotoIf("DAHDI/i3/7861111111-5", "1?report") in new stack
    -- Goto (macro-user-callerid,s,15)
    -- Executing [s@macro-user-callerid:15] GotoIf("DAHDI/i3/7861111111-5", "0?continue") in new stack
    -- Executing [s@macro-user-callerid:16] Set("DAHDI/i3/7861111111-5", "__TTL=64") in new stack
    -- Executing [s@macro-user-callerid:17] GotoIf("DAHDI/i3/7861111111-5", "1?continue") in new stack
    -- Goto (macro-user-callerid,s,28)
    -- Executing [s@macro-user-callerid:28] Set("DAHDI/i3/7861111111-5", "CALLERID(number)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:29] Set("DAHDI/i3/7861111111-5", "CALLERID(name)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:30] Set("DAHDI/i3/7861111111-5", "CDR(cnum)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:31] Set("DAHDI/i3/7861111111-5", "CDR(cnam)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:32] Set("DAHDI/i3/7861111111-5", "CHANNEL(language)=en") in new stack
    -- Executing [s@macro-exten-vm:2] Set("DAHDI/i3/7861111111-5", "RingGroupMethod=none") in new stack
    -- Executing [s@macro-exten-vm:3] Set("DAHDI/i3/7861111111-5", "__EXTTOCALL=2002") in new stack
    -- Executing [s@macro-exten-vm:4] Set("DAHDI/i3/7861111111-5", "__PICKUPMARK=2002") in new stack
    -- Executing [s@macro-exten-vm:5] Set("DAHDI/i3/7861111111-5", "RT=") in new stack
    -- Executing [s@macro-exten-vm:6] Gosub("DAHDI/i3/7861111111-5", "sub-record-check,s,1(exten,2002,)") in new stack
    -- Executing [s@sub-record-check:1] Set("DAHDI/i3/7861111111-5", "REC_POLICY_MODE_SAVE=") in new stack
    -- Executing [s@sub-record-check:2] GotoIf("DAHDI/i3/7861111111-5", "1?check") in new stack
    -- Goto (sub-record-check,s,7)
    -- Executing [s@sub-record-check:7] Set("DAHDI/i3/7861111111-5", "__MON_FMT=wav") in new stack
    -- Executing [s@sub-record-check:8] GotoIf("DAHDI/i3/7861111111-5", "1?next") in new stack
    -- Goto (sub-record-check,s,11)
    -- Executing [s@sub-record-check:11] ExecIf("DAHDI/i3/7861111111-5", "0?Return()") in new stack
    -- Executing [s@sub-record-check:12] ExecIf("DAHDI/i3/7861111111-5", "0?Set(__REC_POLICY_MODE=)") in new stack
    -- Executing [s@sub-record-check:13] GotoIf("DAHDI/i3/7861111111-5", "0?exten,1") in new stack
    -- Executing [s@sub-record-check:14] Set("DAHDI/i3/7861111111-5", "__REC_STATUS=INITIALIZED") in new stack
    -- Executing [s@sub-record-check:15] Set("DAHDI/i3/7861111111-5", "NOW=1167612930") in new stack
    -- Executing [s@sub-record-check:16] Set("DAHDI/i3/7861111111-5", "__DAY=01") in new stack
    -- Executing [s@sub-record-check:17] Set("DAHDI/i3/7861111111-5", "__MONTH=01") in new stack
    -- Executing [s@sub-record-check:18] Set("DAHDI/i3/7861111111-5", "__YEAR=2007") in new stack
    -- Executing [s@sub-record-check:19] Set("DAHDI/i3/7861111111-5", "__TIMESTR=20070101-005530") in new stack
    -- Executing [s@sub-record-check:20] Set("DAHDI/i3/7861111111-5", "__FROMEXTEN=7861111111") in new stack
    -- Executing [s@sub-record-check:21] Set("DAHDI/i3/7861111111-5", "__CALLFILENAME=exten-2002-7861111111-20070101-005530-1167612930.20") in new stack
    -- Executing [s@macro-user-callerid:1] Set("DAHDI/i4/7861111111-5", "TOUCH_MONITOR=1167612930.21") in new stack
    -- Executing [s@sub-record-check:22] Goto("DAHDI/i3/7861111111-5", "exten,1") in new stack
    -- Goto (sub-record-check,exten,1)
    -- Executing [exten@sub-record-check:1] GotoIf("DAHDI/i3/7861111111-5", "0?callee") in new stack
    -- Executing [s@macro-user-callerid:2] Set("DAHDI/i4/7861111111-5", "AMPUSER=7861111111") in new stack
    -- Executing [exten@sub-record-check:2] Set("DAHDI/i3/7861111111-5", "__REC_POLICY_MODE=always") in new stack
    -- Executing [s@macro-user-callerid:3] GotoIf("DAHDI/i4/7861111111-5", "0?report") in new stack
    -- Executing [exten@sub-record-check:3] GotoIf("DAHDI/i3/7861111111-5", "0?caller") in new stack
    -- Executing [s@macro-user-callerid:4] ExecIf("DAHDI/i4/7861111111-5", "1?Set(REALCALLERIDNUM=7861111111)") in new stack
    -- Executing [exten@sub-record-check:4] GotoIf("DAHDI/i3/7861111111-5", "1?callee") in new stack
    -- Goto (sub-record-check,exten,8)
    -- Executing [s@macro-user-callerid:5] Set("DAHDI/i4/7861111111-5", "AMPUSER=") in new stack
    -- Executing [s@macro-user-callerid:6] GotoIf("DAHDI/i4/7861111111-5", "0?limit") in new stack
    -- Executing [exten@sub-record-check:8] GosubIf("DAHDI/i3/7861111111-5", "1?record,1(exten,2002,7861111111)") in new stack
    -- Executing [s@macro-user-callerid:7] Set("DAHDI/i4/7861111111-5", "AMPUSERCIDNAME=") in new stack
    -- Executing [s@macro-user-callerid:8] GotoIf("DAHDI/i4/7861111111-5", "1?report") in new stack
    -- Executing [record@sub-record-check:1] Set("DAHDI/i3/7861111111-5", "AUDIOHOOK_INHERIT(MixMonitor)=yes") in new stack
    -- Goto (macro-user-callerid,s,15)
    -- Executing [s@macro-user-callerid:15] GotoIf("DAHDI/i4/7861111111-5", "0?continue") in new stack
    -- Executing [record@sub-record-check:2] MixMonitor("DAHDI/i3/7861111111-5", "2007/01/01/exten-2002-7861111111-20070101-005530-1167612930.20.wav,,") in new stack
    -- Executing [s@macro-user-callerid:16] Set("DAHDI/i4/7861111111-5", "__TTL=64") in new stack
    -- Executing [record@sub-record-check:3] Set("DAHDI/i3/7861111111-5", "__REC_STATUS=RECORDING") in new stack
  == Begin MixMonitor Recording DAHDI/i3/7861111111-5
    -- Executing [s@macro-user-callerid:17] GotoIf("DAHDI/i4/7861111111-5", "1?continue") in new stack
    -- Executing [record@sub-record-check:4] Set("DAHDI/i3/7861111111-5", "CDR(recordingfile)=exten-2002-7861111111-20070101-005530-1167612930.20.wav") in new stack
    -- Goto (macro-user-callerid,s,28)
    -- Executing [record@sub-record-check:5] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [s@macro-user-callerid:28] Set("DAHDI/i4/7861111111-5", "CALLERID(number)=7861111111") in new stack
    -- Executing [exten@sub-record-check:9] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [s@macro-user-callerid:29] Set("DAHDI/i4/7861111111-5", "CALLERID(name)=7861111111") in new stack
    -- Executing [s@macro-exten-vm:7] Macro("DAHDI/i3/7861111111-5", "dial-one,,tr,2002") in new stack
    -- Executing [s@macro-user-callerid:30] Set("DAHDI/i4/7861111111-5", "CDR(cnum)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:31] Set("DAHDI/i4/7861111111-5", "CDR(cnam)=7861111111") in new stack
    -- Executing [s@macro-user-callerid:32] Set("DAHDI/i4/7861111111-5", "CHANNEL(language)=en") in new stack
    -- Executing [s@macro-dial-one:1] Set("DAHDI/i3/7861111111-5", "DEXTEN=2002") in new stack
    -- Executing [s@macro-exten-vm:2] Set("DAHDI/i4/7861111111-5", "RingGroupMethod=none") in new stack
    -- Executing [s@macro-dial-one:2] Set("DAHDI/i3/7861111111-5", "DIALSTATUS_CW=") in new stack
    -- Executing [s@macro-exten-vm:3] Set("DAHDI/i4/7861111111-5", "__EXTTOCALL=2002") in new stack
    -- Executing [s@macro-exten-vm:4] Set("DAHDI/i4/7861111111-5", "__PICKUPMARK=2002") in new stack
    -- Executing [s@macro-dial-one:3] GosubIf("DAHDI/i3/7861111111-5", "0?screen,1()") in new stack
    -- Executing [s@macro-exten-vm:5] Set("DAHDI/i4/7861111111-5", "RT=") in new stack
    -- Executing [s@macro-dial-one:4] GosubIf("DAHDI/i3/7861111111-5", "0?cf,1()") in new stack
    -- Executing [s@macro-exten-vm:6] Gosub("DAHDI/i4/7861111111-5", "sub-record-check,s,1(exten,2002,)") in new stack
    -- Executing [s@sub-record-check:1] Set("DAHDI/i4/7861111111-5", "REC_POLICY_MODE_SAVE=") in new stack
    -- Executing [s@macro-dial-one:5] GotoIf("DAHDI/i3/7861111111-5", "1?skip1") in new stack
    -- Goto (macro-dial-one,s,8)
    -- Executing [s@sub-record-check:2] GotoIf("DAHDI/i4/7861111111-5", "1?check") in new stack
    -- Goto (sub-record-check,s,7)
    -- Executing [s@macro-dial-one:8] GotoIf("DAHDI/i3/7861111111-5", "0?nodial") in new stack
    -- Executing [s@sub-record-check:7] Set("DAHDI/i4/7861111111-5", "__MON_FMT=wav") in new stack
    -- Executing [s@macro-dial-one:9] GotoIf("DAHDI/i3/7861111111-5", "0?continue") in new stack
    -- Executing [s@sub-record-check:8] GotoIf("DAHDI/i4/7861111111-5", "1?next") in new stack
    -- Goto (sub-record-check,s,11)
    -- Executing [s@macro-dial-one:10] Set("DAHDI/i3/7861111111-5", "EXTHASCW=ENABLED") in new stack
    -- Executing [s@sub-record-check:11] ExecIf("DAHDI/i4/7861111111-5", "0?Return()") in new stack
    -- Executing [s@macro-dial-one:11] GotoIf("DAHDI/i3/7861111111-5", "0?next1:cwinusebusy") in new stack
    -- Executing [s@sub-record-check:12] ExecIf("DAHDI/i4/7861111111-5", "0?Set(__REC_POLICY_MODE=)") in new stack
    -- Goto (macro-dial-one,s,23)
    -- Executing [s@macro-dial-one:23] GotoIf("DAHDI/i3/7861111111-5", "1?next3:continue") in new stack
    -- Executing [s@sub-record-check:13] GotoIf("DAHDI/i4/7861111111-5", "0?exten,1") in new stack
    -- Goto (macro-dial-one,s,24)
    -- Executing [s@sub-record-check:14] Set("DAHDI/i4/7861111111-5", "__REC_STATUS=INITIALIZED") in new stack
    -- Executing [s@sub-record-check:15] Set("DAHDI/i4/7861111111-5", "NOW=1167612930") in new stack
    -- Executing [s@macro-dial-one:24] ExecIf("DAHDI/i3/7861111111-5", "0?Set(DIALSTATUS_CW=BUSY)") in new stack
    -- Executing [s@sub-record-check:16] Set("DAHDI/i4/7861111111-5", "__DAY=01") in new stack
    -- Executing [s@sub-record-check:17] Set("DAHDI/i4/7861111111-5", "__MONTH=01") in new stack
    -- Executing [s@macro-dial-one:25] GotoIf("DAHDI/i3/7861111111-5", "0?nodial") in new stack
    -- Executing [s@sub-record-check:18] Set("DAHDI/i4/7861111111-5", "__YEAR=2007") in new stack
    -- Executing [s@macro-dial-one:26] GosubIf("DAHDI/i3/7861111111-5", "1?dstring,1():dlocal,1()") in new stack
    -- Executing [s@sub-record-check:19] Set("DAHDI/i4/7861111111-5", "__TIMESTR=20070101-005530") in new stack
    -- Executing [dstring@macro-dial-one:1] Set("DAHDI/i3/7861111111-5", "DSTRING=") in new stack
    -- Executing [s@sub-record-check:20] Set("DAHDI/i4/7861111111-5", "__FROMEXTEN=7861111111") in new stack
    -- Executing [dstring@macro-dial-one:2] Set("DAHDI/i3/7861111111-5", "DEVICES=2002") in new stack
    -- Executing [s@sub-record-check:21] Set("DAHDI/i4/7861111111-5", "__CALLFILENAME=exten-2002-7861111111-20070101-005530-1167612930.21") in new stack
    -- Executing [dstring@macro-dial-one:3] ExecIf("DAHDI/i3/7861111111-5", "0?Return()") in new stack
    -- Executing [s@sub-record-check:22] Goto("DAHDI/i4/7861111111-5", "exten,1") in new stack
    -- Goto (sub-record-check,exten,1)
    -- Executing [dstring@macro-dial-one:4] ExecIf("DAHDI/i3/7861111111-5", "0?Set(DEVICES=002)") in new stack
    -- Executing [exten@sub-record-check:1] GotoIf("DAHDI/i4/7861111111-5", "0?callee") in new stack
    -- Executing [dstring@macro-dial-one:5] Set("DAHDI/i3/7861111111-5", "LOOPCNT=1") in new stack
    -- Executing [exten@sub-record-check:2] Set("DAHDI/i4/7861111111-5", "__REC_POLICY_MODE=always") in new stack
    -- Executing [exten@sub-record-check:3] GotoIf("DAHDI/i4/7861111111-5", "0?caller") in new stack
    -- Executing [dstring@macro-dial-one:6] Set("DAHDI/i3/7861111111-5", "ITER=1") in new stack
    -- Executing [exten@sub-record-check:4] GotoIf("DAHDI/i4/7861111111-5", "1?callee") in new stack
    -- Executing [dstring@macro-dial-one:7] Set("DAHDI/i3/7861111111-5", "THISDIAL=SIP/2002") in new stack
    -- Goto (sub-record-check,exten,8)
    -- Executing [exten@sub-record-check:8] GosubIf("DAHDI/i4/7861111111-5", "1?record,1(exten,2002,7861111111)") in new stack
    -- Executing [dstring@macro-dial-one:8] GosubIf("DAHDI/i3/7861111111-5", "1?zap2dahdi,1()") in new stack
    -- Executing [record@sub-record-check:1] Set("DAHDI/i4/7861111111-5", "AUDIOHOOK_INHERIT(MixMonitor)=yes") in new stack
    -- Executing [record@sub-record-check:2] MixMonitor("DAHDI/i4/7861111111-5", "2007/01/01/exten-2002-7861111111-20070101-005530-1167612930.21.wav,,") in new stack
    -- Executing [record@sub-record-check:3] Set("DAHDI/i4/7861111111-5", "__REC_STATUS=RECORDING") in new stack
    -- Executing [record@sub-record-check:4] Set("DAHDI/i4/7861111111-5", "CDR(recordingfile)=exten-2002-7861111111-20070101-005530-1167612930.21.wav") in new stack
    -- Executing [record@sub-record-check:5] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [exten@sub-record-check:9] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [s@macro-exten-vm:7] Macro("DAHDI/i4/7861111111-5", "dial-one,,tr,2002") in new stack
    -- Executing [s@macro-dial-one:1] Set("DAHDI/i4/7861111111-5", "DEXTEN=2002") in new stack
    -- Executing [s@macro-dial-one:2] Set("DAHDI/i4/7861111111-5", "DIALSTATUS_CW=") in new stack
    -- Executing [s@macro-dial-one:3] GosubIf("DAHDI/i4/7861111111-5", "0?screen,1()") in new stack
    -- Executing [s@macro-dial-one:4] GosubIf("DAHDI/i4/7861111111-5", "0?cf,1()") in new stack
    -- Executing [s@macro-dial-one:5] GotoIf("DAHDI/i4/7861111111-5", "1?skip1") in new stack
    -- Goto (macro-dial-one,s,8)
    -- Executing [s@macro-dial-one:8] GotoIf("DAHDI/i4/7861111111-5", "0?nodial") in new stack
    -- Executing [s@macro-dial-one:9] GotoIf("DAHDI/i4/7861111111-5", "0?continue") in new stack
  == Begin MixMonitor Recording DAHDI/i4/7861111111-5
    -- Executing [s@macro-dial-one:10] Set("DAHDI/i4/7861111111-5", "EXTHASCW=ENABLED") in new stack
    -- Executing [zap2dahdi@macro-dial-one:1] ExecIf("DAHDI/i3/7861111111-5", "0?Return()") in new stack
    -- Executing [s@macro-dial-one:11] GotoIf("DAHDI/i4/7861111111-5", "0?next1:cwinusebusy") in new stack
    -- Executing [zap2dahdi@macro-dial-one:2] Set("DAHDI/i3/7861111111-5", "NEWDIAL=") in new stack
    -- Goto (macro-dial-one,s,23)
    -- Executing [zap2dahdi@macro-dial-one:3] Set("DAHDI/i3/7861111111-5", "LOOPCNT2=1") in new stack
    -- Executing [s@macro-dial-one:23] GotoIf("DAHDI/i4/7861111111-5", "1?next3:continue") in new stack
    -- Goto (macro-dial-one,s,24)
    -- Executing [zap2dahdi@macro-dial-one:4] Set("DAHDI/i3/7861111111-5", "ITER2=1") in new stack
    -- Executing [s@macro-dial-one:24] ExecIf("DAHDI/i4/7861111111-5", "0?Set(DIALSTATUS_CW=BUSY)") in new stack
    -- Executing [zap2dahdi@macro-dial-one:5] Set("DAHDI/i3/7861111111-5", "THISPART2=SIP/2002") in new stack
    -- Executing [s@macro-dial-one:25] GotoIf("DAHDI/i4/7861111111-5", "0?nodial") in new stack
    -- Executing [zap2dahdi@macro-dial-one:6] ExecIf("DAHDI/i3/7861111111-5", "0?Set(THISPART2=DAHDI/2002)") in new stack
    -- Executing [s@macro-dial-one:26] GosubIf("DAHDI/i4/7861111111-5", "1?dstring,1():dlocal,1()") in new stack
    -- Executing [zap2dahdi@macro-dial-one:7] Set("DAHDI/i3/7861111111-5", "NEWDIAL=SIP/2002&") in new stack
    -- Executing [zap2dahdi@macro-dial-one:8] Set("DAHDI/i3/7861111111-5", "ITER2=2") in new stack
    -- Executing [dstring@macro-dial-one:1] Set("DAHDI/i4/7861111111-5", "DSTRING=") in new stack
    -- Executing [zap2dahdi@macro-dial-one:9] GotoIf("DAHDI/i3/7861111111-5", "0?begin2") in new stack
    -- Executing [dstring@macro-dial-one:2] Set("DAHDI/i4/7861111111-5", "DEVICES=2002") in new stack
    -- Executing [dstring@macro-dial-one:3] ExecIf("DAHDI/i4/7861111111-5", "0?Return()") in new stack
    -- Executing [zap2dahdi@macro-dial-one:10] Set("DAHDI/i3/7861111111-5", "THISDIAL=SIP/2002") in new stack
    -- Executing [dstring@macro-dial-one:4] ExecIf("DAHDI/i4/7861111111-5", "0?Set(DEVICES=002)") in new stack
    -- Executing [dstring@macro-dial-one:5] Set("DAHDI/i4/7861111111-5", "LOOPCNT=1") in new stack
    -- Executing [zap2dahdi@macro-dial-one:11] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [dstring@macro-dial-one:6] Set("DAHDI/i4/7861111111-5", "ITER=1") in new stack
    -- Executing [dstring@macro-dial-one:7] Set("DAHDI/i4/7861111111-5", "THISDIAL=SIP/2002") in new stack
    -- Executing [dstring@macro-dial-one:9] Set("DAHDI/i3/7861111111-5", "DSTRING=SIP/2002&") in new stack
    -- Executing [dstring@macro-dial-one:8] GosubIf("DAHDI/i4/7861111111-5", "1?zap2dahdi,1()") in new stack
    -- Executing [zap2dahdi@macro-dial-one:1] ExecIf("DAHDI/i4/7861111111-5", "0?Return()") in new stack
    -- Executing [dstring@macro-dial-one:10] Set("DAHDI/i3/7861111111-5", "ITER=2") in new stack
    -- Executing [zap2dahdi@macro-dial-one:2] Set("DAHDI/i4/7861111111-5", "NEWDIAL=") in new stack
    -- Executing [zap2dahdi@macro-dial-one:3] Set("DAHDI/i4/7861111111-5", "LOOPCNT2=1") in new stack
    -- Executing [zap2dahdi@macro-dial-one:4] Set("DAHDI/i4/7861111111-5", "ITER2=1") in new stack
    -- Executing [dstring@macro-dial-one:11] GotoIf("DAHDI/i3/7861111111-5", "0?begin") in new stack
    -- Executing [zap2dahdi@macro-dial-one:5] Set("DAHDI/i4/7861111111-5", "THISPART2=SIP/2002") in new stack
    -- Executing [dstring@macro-dial-one:12] Set("DAHDI/i3/7861111111-5", "DSTRING=SIP/2002") in new stack
    -- Executing [zap2dahdi@macro-dial-one:6] ExecIf("DAHDI/i4/7861111111-5", "0?Set(THISPART2=DAHDI/2002)") in new stack
    -- Executing [dstring@macro-dial-one:13] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [zap2dahdi@macro-dial-one:7] Set("DAHDI/i4/7861111111-5", "NEWDIAL=SIP/2002&") in new stack
    -- Executing [zap2dahdi@macro-dial-one:8] Set("DAHDI/i4/7861111111-5", "ITER2=2") in new stack
    -- Executing [s@macro-dial-one:27] GotoIf("DAHDI/i3/7861111111-5", "0?nodial") in new stack
    -- Executing [zap2dahdi@macro-dial-one:9] GotoIf("DAHDI/i4/7861111111-5", "0?begin2") in new stack
    -- Executing [s@macro-dial-one:28] GotoIf("DAHDI/i3/7861111111-5", "0?skiptrace") in new stack
    -- Executing [zap2dahdi@macro-dial-one:10] Set("DAHDI/i4/7861111111-5", "THISDIAL=SIP/2002") in new stack
    -- Executing [zap2dahdi@macro-dial-one:11] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [dstring@macro-dial-one:9] Set("DAHDI/i4/7861111111-5", "DSTRING=SIP/2002&") in new stack
    -- Executing [s@macro-dial-one:29] GosubIf("DAHDI/i3/7861111111-5", "1?ctset,1():ctclear,1()") in new stack
    -- Executing [dstring@macro-dial-one:10] Set("DAHDI/i4/7861111111-5", "ITER=2") in new stack
    -- Executing [dstring@macro-dial-one:11] GotoIf("DAHDI/i4/7861111111-5", "0?begin") in new stack
    -- Executing [dstring@macro-dial-one:12] Set("DAHDI/i4/7861111111-5", "DSTRING=SIP/2002") in new stack
    -- Executing [dstring@macro-dial-one:13] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [s@macro-dial-one:27] GotoIf("DAHDI/i4/7861111111-5", "0?nodial") in new stack
    -- Executing [s@macro-dial-one:28] GotoIf("DAHDI/i4/7861111111-5", "0?skiptrace") in new stack
    -- Executing [s@macro-dial-one:29] GosubIf("DAHDI/i4/7861111111-5", "1?ctset,1():ctclear,1()") in new stack
    -- Executing [ctset@macro-dial-one:1] Set("DAHDI/i4/7861111111-5", "DB(CALLTRACE/2002)=7861111111") in new stack
    -- Executing [ctset@macro-dial-one:2] Return("DAHDI/i4/7861111111-5", "") in new stack
    -- Executing [s@macro-dial-one:30] Set("DAHDI/i4/7861111111-5", "D_OPTIONS=tr") in new stack
    -- Executing [s@macro-dial-one:31] ExecIf("DAHDI/i4/7861111111-5", "0?SIPAddHeader(Alert-Info: )") in new stack
    -- Executing [s@macro-dial-one:32] ExecIf("DAHDI/i4/7861111111-5", "0?SIPAddHeader()") in new stack
    -- Executing [s@macro-dial-one:33] ExecIf("DAHDI/i4/7861111111-5", "1?Set(CHANNEL(musicclass)=default)") in new stack
    -- Executing [ctset@macro-dial-one:1] Set("DAHDI/i3/7861111111-5", "DB(CALLTRACE/2002)=7861111111") in new stack
    -- Executing [s@macro-dial-one:34] GosubIf("DAHDI/i4/7861111111-5", "0?qwait,1()") in new stack
    -- Executing [s@macro-dial-one:35] Set("DAHDI/i4/7861111111-5", "__CWIGNORE=") in new stack
    -- Executing [s@macro-dial-one:36] Set("DAHDI/i4/7861111111-5", "__KEEPCID=TRUE") in new stack
    -- Executing [s@macro-dial-one:37] GotoIf("DAHDI/i4/7861111111-5", "0?usegoto,1") in new stack
    -- Executing [ctset@macro-dial-one:2] Return("DAHDI/i3/7861111111-5", "") in new stack
    -- Executing [s@macro-dial-one:38] GotoIf("DAHDI/i4/7861111111-5", "1?godial") in new stack
    -- Goto (macro-dial-one,s,43)
    -- Executing [s@macro-dial-one:43] Dial("DAHDI/i4/7861111111-5", "SIP/2002,,tr") in new stack
    -- Executing [s@macro-dial-one:30] Set("DAHDI/i3/7861111111-5", "D_OPTIONS=tr") in new stack
    -- Executing [s@macro-dial-one:31] ExecIf("DAHDI/i3/7861111111-5", "0?SIPAddHeader(Alert-Info: )") in new stack
    -- Executing [s@macro-dial-one:32] ExecIf("DAHDI/i3/7861111111-5", "0?SIPAddHeader()") in new stack
  == Using SIP RTP TOS bits 184
  == Using SIP RTP CoS mark 5
    -- Executing [s@macro-dial-one:33] ExecIf("DAHDI/i3/7861111111-5", "1?Set(CHANNEL(musicclass)=default)") in new stack
    -- Executing [s@macro-dial-one:34] GosubIf("DAHDI/i3/7861111111-5", "0?qwait,1()") in new stack
    -- Executing [s@macro-dial-one:35] Set("DAHDI/i3/7861111111-5", "__CWIGNORE=") in new stack
    -- Executing [s@macro-dial-one:36] Set("DAHDI/i3/7861111111-5", "__KEEPCID=TRUE") in new stack
    -- Executing [s@macro-dial-one:37] GotoIf("DAHDI/i3/7861111111-5", "0?usegoto,1") in new stack
    -- Called SIP/2002
    -- Executing [s@macro-dial-one:38] GotoIf("DAHDI/i3/7861111111-5", "1?godial") in new stack
    -- Goto (macro-dial-one,s,43)
    -- Executing [s@macro-dial-one:43] Dial("DAHDI/i3/7861111111-5", "SIP/2002,,tr") in new stack
  == Using SIP RTP TOS bits 184
  == Using SIP RTP CoS mark 5
    -- Called SIP/2002
    -- SIP/2002-00000008 is ringing
    -- SIP/2002-00000008 is ringing
PRI Span: 3 TEI=0 MDL-ERROR (A): Got supervisory frame with F=1 in state 7(Multi-frame established)
PRI Span: 4 TEI=0 MDL-ERROR (A): Got supervisory frame with F=1 in state 7(Multi-frame established)
    -- SIP/2002-00000009 is ringing
    -- Span 3: Channel 0/1 got hangup, cause 81
  == Spawn extension (macro-dial-one, s, 43) exited non-zero on 'DAHDI/i3/7861111111-5' in macro 'dial-one'
  == Spawn extension (macro-exten-vm, s, 7) exited non-zero on 'DAHDI/i3/7861111111-5' in macro 'exten-vm'
    -- Span 4: Channel 0/1 got hangup, cause 81
  == Spawn extension (macro-dial-one, s, 43) exited non-zero on 'DAHDI/i4/7861111111-5' in macro 'dial-one'
  == Spawn extension (from-did-direct, 2002, 2) exited non-zero on 'DAHDI/i3/7861111111-5'
  == Spawn extension (macro-exten-vm, s, 7) exited non-zero on 'DAHDI/i4/7861111111-5' in macro 'exten-vm'
    -- Executing [h@from-did-direct:1] Macro("DAHDI/i3/7861111111-5", "hangupcall,") in new stack
  == Spawn extension (from-did-direct, 2002, 2) exited non-zero on 'DAHDI/i4/7861111111-5'
    -- Executing [h@from-did-direct:1] Macro("DAHDI/i4/7861111111-5", "hangupcall,") in new stack
    -- Executing [s@macro-hangupcall:1] GotoIf("DAHDI/i3/7861111111-5", "1?endmixmoncheck") in new stack
    -- Goto (macro-hangupcall,s,9)
    -- Executing [s@macro-hangupcall:1] GotoIf("DAHDI/i4/7861111111-5", "1?endmixmoncheck") in new stack
    -- Executing [s@macro-hangupcall:9] NoOp("DAHDI/i3/7861111111-5", "End of MIXMON check") in new stack
    -- Goto (macro-hangupcall,s,9)
    -- Executing [s@macro-hangupcall:9] NoOp("DAHDI/i4/7861111111-5", "End of MIXMON check") in new stack
    -- Executing [s@macro-hangupcall:10] GotoIf("DAHDI/i3/7861111111-5", "1?nomeetmemon") in new stack
    -- Goto (macro-hangupcall,s,28)
    -- Executing [s@macro-hangupcall:10] GotoIf("DAHDI/i4/7861111111-5", "1?nomeetmemon") in new stack
    -- Goto (macro-hangupcall,s,28)
    -- Executing [s@macro-hangupcall:28] NoOp("DAHDI/i3/7861111111-5", "End of MEETME check") in new stack
    -- Executing [s@macro-hangupcall:28] NoOp("DAHDI/i4/7861111111-5", "End of MEETME check") in new stack
    -- Executing [s@macro-hangupcall:29] GotoIf("DAHDI/i3/7861111111-5", "1?noautomon") in new stack
    -- Executing [s@macro-hangupcall:29] GotoIf("DAHDI/i4/7861111111-5", "1?noautomon") in new stack
    -- Goto (macro-hangupcall,s,34)
    -- Goto (macro-hangupcall,s,34)
1 Like

I would have to suggest that you look at why your iSDN signalling is showing

PRI Span: 3 TEI=0 MDL-ERROR (A): Got supervisory frame with F=1 in state 7(Multi-frame established)
PRI Span: 4 TEI=0 MDL-ERROR (A): Got supervisory frame with F=1 in state 7(Multi-frame established)

It appears that span 3 is trying to pass the call to to span 4 which returns that 81 error. Do you have 4 spans and are their D channels separate at the providers end ?

pri set debug on span 3
pri set debug on span 4

Hi Dicko,

Thanks for your reply. Could this be a reason because I do not have the mISDN driver installed?

Yes, 4 spans and channels separate from the provider.

That would depend on your hardware

https://wiki.asterisk.org/wiki/display/AST/mISDN

Digium/Sangoma don’t need it.

Okay.
I dont have the card installed on this machine at the moment, as I had to swap it back to the working one. But I think this is happening because I have following in /etc/dahdi/system.conf instead of

loadzone = uk 
defaultzone = uk

Am I on right track?

# Autogenerated by /usr/sbin/dahdi_genconf on Mon Jan  1 00:52:04 2007
# If you edit this file and execute /usr/sbin/dahdi_genconf again,
# your manual changes will be LOST.
# Dahdi Configuration File
#
# This file is parsed by the Dahdi Configurator, dahdi_cfg
#
# Span 1: WPBRI/0 "wrtdm Board 1"
span=1,1,0,ccs,ami
# termtype: te
bchan=1-2
hardhdlc=3
echocanceller=oslec,1-2

# Span 2: WPBRI/1 "wrtdm Board 2" (MASTER)
span=2,2,0,ccs,ami
# termtype: te
bchan=4-5
hardhdlc=6
echocanceller=oslec,4-5

# Span 3: WPBRI/2 "wrtdm Board 3"
span=3,3,0,ccs,ami
# termtype: te
bchan=7-8
hardhdlc=9
echocanceller=oslec,7-8

# Span 4: WPBRI/3 "wrtdm Board 4"
span=4,4,0,ccs,ami
# termtype: te
bchan=10-11
hardhdlc=12
echocanceller=oslec,10-11

# Global data

loadzone        = us
defaultzone     = us

Can’t really help here /etc/dahdi is where you put dahdi configs but you need to make sure all the parameters match exactly with what your provider supplies for the ISDN PRI running on the underlying E0’s in your case that the D channels are not bonded nor redundant amongst your spans.

Are you trying to replace a card with another one? are they both amenable to the standard dahdi channel driver ?

edit:

I see you are BRI not PRI ignore most of what I said about d-channels and E0’s but be careful of what hardware you try, there is little support anymore for cologne chip-sets. Use Digium or Sangoma and save yourself heartache.

I know its a Sangoma and uses Woomera on current config. I actually cant access any part of that machine apart from AMI, as we have lost the password for its root. Currently it sits on an old Trixbox and we are trying to set it up on a new FPBX.

Regards,
Jeet.