Outgoing issue

Hi,

I got a freepbx install running. I have set up local extensions (200, 201 etc) and it works. I want to use a SPA-3000 modem (connected to an analog line)

The spa-3000 registered with my freepbx correctly (internal IP 192.168.0.187)

However, whenever I call out I get this message ‘All circuits are busy now. Please try your call again later’

Im not sure what I have missed. I tried all the suggestions on :
http://aussievoip.com.au/wiki/Setup+Sipura+3000+with+FreePBX

My outgoing trunk settings are:
trunk name : pstn

allow=ulaw
context=from-trunk
disallow=all
dtmfmode=inband
host=dynamic
nat=no
qualify=no
secret=xxxx
type=peer
username=pstn

Incoming trunk settings:
USER context : spa3000

canreinvite=no
context=from-trunk
dtmfmode=inband
host=192.168.0.187
nat=never
port=5061
qualify=yes
secret=xxxx
type=user
username=spa3000

On my outbound routes, Im using a single number as the dial pattern to keep things simple (I have tried other combos, not sure its related to dial pattern)

Thanks in advance for any pointers…

VJ

represented by ‘2021000000’ in this debug info.

on ariel’s suggestion I deleted the default 0-9 route

This is the latest debug info :

Connected to Asterisk 1.2.9.1 svn rev 34876 currently running on asterisk1 (pid = 2789)
Verbosity is at least 3
Core debug is at least 1
– Executing Macro(“SIP/200-5881”, “dialout-trunk|2|92021000000||”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?3:2”) in new stack
– Goto (macro-dialout-trunk,s,3)
– Executing Macro(“SIP/200-5881”, “user-callerid”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?report”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?start”) in new stack
– Executing Set(“SIP/200-5881”, “REALCALLERIDNUM=200”) in new stack
– Executing NoOp(“SIP/200-5881”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-5881”, “AMPUSER=200”) in new stack
– Executing Set(“SIP/200-5881”, “AMPUSERCIDNAME=200”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?report”) in new stack
– Executing Set(“SIP/200-5881”, “CALLERID(all)=200 <200>”) in new stack
– Executing NoOp(“SIP/200-5881”, “Using CallerID “200” <200>”) in new stack
– Executing Macro(“SIP/200-5881”, “record-enable|200|OUT”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0 > 0?2:4”) in new stack
– Goto (macro-record-enable,s,4)
– Executing AGI(“SIP/200-5881”, “recordingcheck|20060726-084135|1153917695.43”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
recordingcheck|20060726-084135|1153917695.43: Outbound recording not enabled
– AGI Script recordingcheck completed, returning 0
– Executing NoOp(“SIP/200-5881”, “No recording needed”) in new stack
– Executing Macro(“SIP/200-5881”, “outbound-callerid|2”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?start”) in new stack
– Goto (macro-outbound-callerid,s,3)
– Executing NoOp(“SIP/200-5881”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-5881”, “USEROUTCID=”) in new stack
– Executing Set(“SIP/200-5881”, “EMERGENCYCID=”) in new stack
– Executing Set(“SIP/200-5881”, “TRUNKOUTCID=92027285430”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?trunkcid”) in new stack
– Goto (macro-outbound-callerid,s,11)
– Executing GotoIf(“SIP/200-5881”, “0?usercid”) in new stack
– Executing Set(“SIP/200-5881”, “CALLERID(all)=92027285430”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?report”) in new stack
– Goto (macro-outbound-callerid,s,15)
– Executing NoOp(“SIP/200-5881”, “CallerID set to “” <92027285430>”) in new stack
– Executing Set(“SIP/200-5881”, “GROUP()=OUT_2”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?108”) in new stack
– Executing Set(“SIP/200-5881”, “DIAL_NUMBER=92021000000”) in new stack
– Executing Set(“SIP/200-5881”, “DIAL_TRUNK=2”) in new stack
– Executing AGI(“SIP/200-5881”, “fixlocalprefix”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
fixlocalprefix: Could not parse /etc/asterisk/localprefixes.conf
– AGI Script fixlocalprefix completed, returning 0
– Executing Set(“SIP/200-5881”, “OUTNUM=92021000000”) in new stack
– Executing Set(“SIP/200-5881”, “custom=SIP/pstn”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?16”) in new stack
– Executing Dial(“SIP/200-5881”, “SIP/pstn/92021000000|120|r”) in new stack
– Called pstn/92021000000
– Got SIP response 503 “Service Unavailable” back from 192.168.0.187
– SIP/pstn-9002 is circuit-busy
== Everyone is busy/congested at this time (1:0/1/0)
– Executing Goto(“SIP/200-5881”, “s-CONGESTION|1”) in new stack
– Goto (macro-dialout-trunk,s-CONGESTION,1)
– Executing NoOp(“SIP/200-5881”, “Dial failed due to CONGESTION”) in new stack
– Executing Macro(“SIP/200-5881”, “dialout-trunk|1|92021000000||”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?3:2”) in new stack
– Goto (macro-dialout-trunk,s,3)
– Executing Macro(“SIP/200-5881”, “user-callerid”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?report”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?start”) in new stack
– Goto (macro-user-callerid,s,4)
– Executing NoOp(“SIP/200-5881”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-5881”, “AMPUSER=200”) in new stack
– Executing Set(“SIP/200-5881”, “AMPUSERCIDNAME=200”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?report”) in new stack
– Executing Set(“SIP/200-5881”, “CALLERID(all)=200 <200>”) in new stack
– Executing NoOp(“SIP/200-5881”, “Using CallerID “200” <200>”) in new stack
– Executing Macro(“SIP/200-5881”, “record-enable|200|OUT”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0 > 0?2:4”) in new stack
– Goto (macro-record-enable,s,4)
– Executing AGI(“SIP/200-5881”, “recordingcheck|20060726-084135|1153917695.43”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
recordingcheck|20060726-084135|1153917695.43: Outbound recording not enabled
– AGI Script recordingcheck completed, returning 0
– Executing NoOp(“SIP/200-5881”, “No recording needed”) in new stack
– Executing Macro(“SIP/200-5881”, “outbound-callerid|1”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?start”) in new stack
– Goto (macro-outbound-callerid,s,3)
– Executing NoOp(“SIP/200-5881”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-5881”, “USEROUTCID=”) in new stack
– Executing Set(“SIP/200-5881”, “EMERGENCYCID=”) in new stack
– Executing Set(“SIP/200-5881”, “TRUNKOUTCID=”) in new stack
– Executing GotoIf(“SIP/200-5881”, “1?trunkcid”) in new stack
– Goto (macro-outbound-callerid,s,11)
– Executing GotoIf(“SIP/200-5881”, “1?usercid”) in new stack
– Goto (macro-outbound-callerid,s,13)
– Executing GotoIf(“SIP/200-5881”, “1?report”) in new stack
– Goto (macro-outbound-callerid,s,15)
– Executing NoOp(“SIP/200-5881”, “CallerID set to “200” <200>”) in new stack
– Executing Set(“SIP/200-5881”, “GROUP()=OUT_1”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?108”) in new stack
– Executing Set(“SIP/200-5881”, “DIAL_NUMBER=92021000000”) in new stack
– Executing Set(“SIP/200-5881”, “DIAL_TRUNK=1”) in new stack
– Executing AGI(“SIP/200-5881”, “fixlocalprefix”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
fixlocalprefix: Could not parse /etc/asterisk/localprefixes.conf
– AGI Script fixlocalprefix completed, returning 0
– Executing Set(“SIP/200-5881”, “OUTNUM=92021000000”) in new stack
– Executing Set(“SIP/200-5881”, “custom=ZAP/g0”) in new stack
– Executing GotoIf(“SIP/200-5881”, “0?16”) in new stack
– Executing Dial(“SIP/200-5881”, “ZAP/g0/92021000000|120|r”) in new stack
== Everyone is busy/congested at this time (1:0/0/1)
– Executing Goto(“SIP/200-5881”, “s-CHANUNAVAIL|1”) in new stack
– Goto (macro-dialout-trunk,s-CHANUNAVAIL,1)
– Executing NoOp(“SIP/200-5881”, “Dial failed due to CHANUNAVAIL”) in new stack
– Executing Macro(“SIP/200-5881”, “outisbusy|”) in new stack
– Executing Playback(“SIP/200-5881”, “all-circuits-busy-now”) in new stack
– Playing ‘all-circuits-busy-now’ (language ‘en’)
– Executing Playback(“SIP/200-5881”, “pls-try-call-later”) in new stack
– Playing ‘pls-try-call-later’ (language ‘en’)
– Executing Macro(“SIP/200-5881”, “hangupcall”) in new stack
– Executing ResetCDR(“SIP/200-5881”, “w”) in new stack
– Executing NoCDR(“SIP/200-5881”, “”) in new stack
– Executing Wait(“SIP/200-5881”, “5”) in new stack

Did you do step 5 from the info section of the sheet. This is where it will send the call out of the PSTN line.

yes, all the steps =/

cli asterisk -rvvv

make calls post here

You did create outbound route correct??? dail patterns
set trunk sequence???

yes I did

I tried different sequences and eventually added just my phone number coz I want to test out going to one number to prove the concept works…

The sequence is SIP/pstn first and the built in zap/g0 second

debug info :

– Executing Macro(“SIP/200-df77”, “dialout-trunk|1|2021000000|”) in new stack
– Executing GotoIf(“SIP/200-df77”, “1?3:2”) in new stack
– Goto (macro-dialout-trunk,s,3)
– Executing Macro(“SIP/200-df77”, “user-callerid”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0?report”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0?start”) in new stack
– Executing Set(“SIP/200-df77”, “REALCALLERIDNUM=200”) in new stack
– Executing NoOp(“SIP/200-df77”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-df77”, “AMPUSER=200”) in new stack
– Executing Set(“SIP/200-df77”, “AMPUSERCIDNAME=200”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0?report”) in new stack
– Executing Set(“SIP/200-df77”, “CALLERID(all)=200 <200>”) in new stack
– Executing NoOp(“SIP/200-df77”, “Using CallerID “200” <200>”) in new stack
– Executing Macro(“SIP/200-df77”, “record-enable|200|OUT”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0 > 0?2:4”) in new stack
– Goto (macro-record-enable,s,4)
– Executing AGI(“SIP/200-df77”, “recordingcheck|20060726-082858|1153916938.40”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
recordingcheck|20060726-082858|1153916938.40: Outbound recording not enabled
– AGI Script recordingcheck completed, returning 0
– Executing NoOp(“SIP/200-df77”, “No recording needed”) in new stack
– Executing Macro(“SIP/200-df77”, “outbound-callerid|1”) in new stack
– Executing GotoIf(“SIP/200-df77”, “1?start”) in new stack
– Goto (macro-outbound-callerid,s,3)
– Executing NoOp(“SIP/200-df77”, “REALCALLERIDNUM is 200”) in new stack
– Executing Set(“SIP/200-df77”, “USEROUTCID=”) in new stack
– Executing Set(“SIP/200-df77”, “EMERGENCYCID=”) in new stack
– Executing Set(“SIP/200-df77”, “TRUNKOUTCID=”) in new stack
– Executing GotoIf(“SIP/200-df77”, “1?trunkcid”) in new stack
– Goto (macro-outbound-callerid,s,11)
– Executing GotoIf(“SIP/200-df77”, “1?usercid”) in new stack
– Goto (macro-outbound-callerid,s,13)
– Executing GotoIf(“SIP/200-df77”, “1?report”) in new stack
– Goto (macro-outbound-callerid,s,15)
– Executing NoOp(“SIP/200-df77”, “CallerID set to “200” <200>”) in new stack
– Executing Set(“SIP/200-df77”, “GROUP()=OUT_1”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0?108”) in new stack
– Executing Set(“SIP/200-df77”, “DIAL_NUMBER=2021000000”) in new stack
– Executing Set(“SIP/200-df77”, “DIAL_TRUNK=1”) in new stack
– Executing AGI(“SIP/200-df77”, “fixlocalprefix”) in new stack
– Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
fixlocalprefix: Could not parse /etc/asterisk/localprefixes.conf
– AGI Script fixlocalprefix completed, returning 0
– Executing Set(“SIP/200-df77”, “OUTNUM=2021000000”) in new stack
– Executing Set(“SIP/200-df77”, “custom=ZAP/g0”) in new stack
– Executing GotoIf(“SIP/200-df77”, “0?16”) in new stack
– Executing Dial(“SIP/200-df77”, “ZAP/g0/2021000000|120|r”) in new stack
== Everyone is busy/congested at this time (1:0/0/1)
– Executing Goto(“SIP/200-df77”, “s-CHANUNAVAIL|1”) in new stack
– Goto (macro-dialout-trunk,s-CHANUNAVAIL,1)
– Executing NoOp(“SIP/200-df77”, “Dial failed due to CHANUNAVAIL”) in new stack
– Executing Macro(“SIP/200-df77”, “outisbusy|”) in new stack
– Executing Playback(“SIP/200-df77”, “all-circuits-busy-now”) in new stack
– Playing ‘all-circuits-busy-now’ (language ‘en’)
– Executing Playback(“SIP/200-df77”, “pls-try-call-later”) in new stack
– Playing ‘pls-try-call-later’ (language ‘en’)
– Executing Macro(“SIP/200-df77”, “hangupcall”) in new stack
– Executing ResetCDR(“SIP/200-df77”, “w”) in new stack
– Executing NoCDR(“SIP/200-df77”, “”) in new stack
– Executing Wait(“SIP/200-df77”, “5”) in new stack
– Executing Hangup(“SIP/200-df77”, “”) in new stack