Page 1 of 1

Carrier Setting Help

PostPosted: Wed Jul 17, 2013 5:44 pm
by senate014
Version = goautodial-64bit-ce-3.0-RC1b
OS = VMware 4.1
Server = HP DL585 G2 4x Quad Core AMD Opteron

Hi guys,

I know you've probably heard all this before when newbies are setting up but I have a Carrier/Trunk issue where I'm not able to dial out.

I'm getting the following error when trying to dial out:

[Jul 17 23:26:51] NOTICE[4052]: chan_sip.c:15566 handle_request_invite: Call from '8001' to extension '901423564XXX' rejected because extension not found.

I use a UK SIP Trunk provider called Gamma Telecoms. I currently have an inhouse Trixbox server running fine. I've just forwarded the firewall ports to my new GOAUTODIALNOW server but I just can't get it dialing out.

The SIP Trunk is authenticated via IP address so there isn't any user credentials needed in the account entry field.

This is my "Account Entry" config:

[SIP01]
disallow=all
allow=g729
allow=gsm
allow=ulaw
type=friend
host=83.245.6.81 (this is Gamma telecoms IPDC SIP server)
dtmfmode=rfc2833
fromdomain=188.66.XX.XXX (this is my external IP address)
context=trunkinbound
qualify=yes
insecure=very

This is my dial plan:

exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9X.,2,Dial(${SIP01}/${EXTEN:2},,tTor)
exten => _9X.,3,Hangup

My Trixbox server works fine with the following config:

(Outgoing Settings) PEER Detail:

type=friend
insecure=very
host=83.245.6.81
fromdomain=188.66.XX.XX
context=from-trunk
canreinvite=no

(Incoming Setting) USER Details:

type=peer
qualify=no
insecure=very
context=from-trunk

Register String: BLANK

There are a few config files that I have edited to get the system working:

sip_nat.conf

externip=188.66.XX.XX
nat=yes
localnet=192.168.10.0/255.255.255.0

I'm just not sure what I'm doing wrong with my Goautodialnow configuration. The server can call between extensions fine but just not outgoing calls.

I've tried the following command:

sip show peers

My SIP trunk doesn't show, only my extensions.

I've installed and loaded the g729 codec.

Is there something I'm missing because I'm banging my head against the wall :oops:

Re: Carrier Setting Help

PostPosted: Wed Jul 17, 2013 9:07 pm
by gardo
It's highly recommended to upgrade your system first by running "yum update".

Looks like you don't have the correct dialplan entry for "901423564XXX".

exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9X.,2,Dial(${SIP01}/${EXTEN:2},,tTor)
exten => _9X.,3,Hangup


What's the complete number you're dialing? Please post your Asterisk CLI when dialing.

You might need to change the dialplan to:

exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9X.,2,Dial(${SIP01}/${EXTEN:1},,tTor)
exten => _9X.,3,Hangup


Alternately, if you applied the updates or upgraded your system via "yum update", you can use the new add carrier wizard. We have revised the manual carrier entry to be more user friendly. No need to worry about dialplans (as long as the carrier accepts the standard: country code + area code + phone number).

Re: Carrier Setting Help

PostPosted: Thu Jul 18, 2013 4:12 am
by DomeDan
senate014 wrote:I've tried the following command:
sip show peers
My SIP trunk doesn't show, only my extensions.


That's a problem, look at the asterisk CLI and see if there is any errors with registration

Re: Carrier Setting Help

PostPosted: Thu Jul 18, 2013 9:08 am
by senate014
gardo wrote:It's highly recommended to upgrade your system first by running "yum update".

Looks like you don't have the correct dialplan entry for "901423564XXX".

exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9X.,2,Dial(${SIP01}/${EXTEN:2},,tTor)
exten => _9X.,3,Hangup


What's the complete number you're dialing? Please post your Asterisk CLI when dialing.

You might need to change the dialplan to:

exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9X.,2,Dial(${SIP01}/${EXTEN:1},,tTor)
exten => _9X.,3,Hangup


Alternately, if you applied the updates or upgraded your system via "yum update", you can use the new add carrier wizard. We have revised the manual carrier entry to be more user friendly. No need to worry about dialplans (as long as the carrier accepts the standard: country code + area code + phone number).


Hi gardo,

Thanks for the response.

I ran the yum update when I installed the system around a week ago. I've used the "Add New Carrier" wizard withing GoAutoDial when I first setup the system with no luck, that's why I;m posting here today.

I need to get this system up and running by Monday, I'm willing to pay money for someone to help me get the outbound dialing working with my SIP Provider. Like I've stated above, I have my Trixbox server running fine for over 3 years with this carrier so It can't be them.

This is the asterisk -r log when trying to dial out using X-Lite:

Connected to Asterisk 1.4.39.1-vici.go RPM by currently running on gcsvds001 (pid = 3951)
Verbosity is at least 4
[Jul 18 14:59:02] NOTICE[4052]: chan_sip.c:15566 handle_request_invite: Call from '8001' to extension '901423564XXX' rejected because extension not found.


I've tried changing the dial plan to the exact match that you've stated above and it still doesn't work.

Any ideas?

If anyone wants to call me you can get me on +44 (0) 1423 223 431

Cheers!

Re: Carrier Setting Help

PostPosted: Thu Jul 18, 2013 9:15 am
by senate014
DomeDan wrote:
senate014 wrote:I've tried the following command:
sip show peers
My SIP trunk doesn't show, only my extensions.


That's a problem, look at the asterisk CLI and see if there is any errors with registration


Hi DomeDan,

Thanks for replying. Yeah it doesn't look through but I just presumed that the SIP Trunk wouldn't show because it's not actually authenicating with the provider because the authentication is simply done via the external IP address.

On my Trixbox server I have to include fromdomain=188.66.71.XX in the TRUNK config file as you can see below so it sends out the IP address that it's from to authenticate and make the call if I'm guessing right?:

type=friend
insecure=very
host=83.245.6.81
fromdomain=188.66.71.XX
context=from-trunk
canreinvite=no

This is the log I get from my Trixbox server when making an outbound call:

Connected to Asterisk 1.4.22-3 RPM by currently running on cspbx001 (pid = 2480)
Verbosity is at least 3
-- Executing [901423564XXX@from-internal:1] Macro("SIP/209-b7908af8", "user-callerid|SKIPTTL|") in new stack
-- Executing [s@macro-user-callerid:1] Set("SIP/209-b7908af8", "AMPUSER=209") in new stack
-- Executing [s@macro-user-callerid:2] GotoIf("SIP/209-b7908af8", "0?report") in new stack
-- Executing [s@macro-user-callerid:3] ExecIf("SIP/209-b7908af8", "1|Set|REALCALLERIDNUM=209") in new stack
-- Executing [s@macro-user-callerid:4] Set("SIP/209-b7908af8", "AMPUSER=209") in new stack
-- Executing [s@macro-user-callerid:5] Set("SIP/209-b7908af8", "AMPUSERCIDNAME=Andy Hughes") in new stack
-- Executing [s@macro-user-callerid:6] GotoIf("SIP/209-b7908af8", "0?report") in new stack
-- Executing [s@macro-user-callerid:7] Set("SIP/209-b7908af8", "AMPUSERCID=209") in new stack
-- Executing [s@macro-user-callerid:8] Set("SIP/209-b7908af8", "CALLERID(all)="Andy Hughes" <209>") in new stack
-- Executing [s@macro-user-callerid:9] ExecIf("SIP/209-b7908af8", "0|Set|CHANNEL(language)=") in new stack
-- Executing [s@macro-user-callerid:10] GotoIf("SIP/209-b7908af8", "1?continue") in new stack
-- Goto (macro-user-callerid,s,19)
-- Executing [s@macro-user-callerid:19] NoOp("SIP/209-b7908af8", "Using CallerID "Andy Hughes" <209>") in new stack
-- Executing [901423564XXX@from-internal:2] Set("SIP/209-b7908af8", "_NODEST=") in new stack
-- Executing [901423564XXX@from-internal:3] Macro("SIP/209-b7908af8", "record-enable|209|OUT|") in new stack
-- Executing [s@macro-record-enable:1] GotoIf("SIP/209-b7908af8", "1?check") in new stack
-- Goto (macro-record-enable,s,4)
-- Executing [s@macro-record-enable:4] AGI("SIP/209-b7908af8", "recordingcheck|20130718-151319|1374156799.2349") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
recordingcheck|20130718-151319|1374156799.2349: Outbound recording not enabled
-- AGI Script recordingcheck completed, returning 0
-- Executing [s@macro-record-enable:5] MacroExit("SIP/209-b7908af8", "") in new stack
-- Executing [901423564XXX@from-internal:4] Macro("SIP/209-b7908af8", "dialout-trunk|2|01423564XXX||") in new stack
-- Executing [s@macro-dialout-trunk:1] Set("SIP/209-b7908af8", "DIAL_TRUNK=2") in new stack
-- Executing [s@macro-dialout-trunk:2] GosubIf("SIP/209-b7908af8", "0?sub-pincheck|s|1") in new stack
-- Executing [s@macro-dialout-trunk:3] GotoIf("SIP/209-b7908af8", "0?disabletrunk|1") in new stack
-- Executing [s@macro-dialout-trunk:4] Set("SIP/209-b7908af8", "DIAL_NUMBER=01423564512") in new stack
-- Executing [s@macro-dialout-trunk:5] Set("SIP/209-b7908af8", "DIAL_TRUNK_OPTIONS=tr") in new stack
-- Executing [s@macro-dialout-trunk:6] Set("SIP/209-b7908af8", "OUTBOUND_GROUP=OUT_2") in new stack
-- Executing [s@macro-dialout-trunk:7] GotoIf("SIP/209-b7908af8", "1?nomax") in new stack
-- Goto (macro-dialout-trunk,s,9)
-- Executing [s@macro-dialout-trunk:9] GotoIf("SIP/209-b7908af8", "0?skipoutcid") in new stack
-- Executing [s@macro-dialout-trunk:10] Set("SIP/209-b7908af8", "DIAL_TRUNK_OPTIONS=") in new stack
-- Executing [s@macro-dialout-trunk:11] Macro("SIP/209-b7908af8", "outbound-callerid|2") in new stack
-- Executing [s@macro-outbound-callerid:1] ExecIf("SIP/209-b7908af8", "0|SetCallerPres|") in new stack
-- Executing [s@macro-outbound-callerid:2] ExecIf("SIP/209-b7908af8", "0|Set|REALCALLERIDNUM=209") in new stack
-- Executing [s@macro-outbound-callerid:3] GotoIf("SIP/209-b7908af8", "1?normcid") in new stack
-- Goto (macro-outbound-callerid,s,6)
-- Executing [s@macro-outbound-callerid:6] Set("SIP/209-b7908af8", "USEROUTCID=") in new stack
-- Executing [s@macro-outbound-callerid:7] Set("SIP/209-b7908af8", "EMERGENCYCID=") in new stack
-- Executing [s@macro-outbound-callerid:8] Set("SIP/209-b7908af8", "TRUNKOUTCID=") in new stack
-- Executing [s@macro-outbound-callerid:9] GotoIf("SIP/209-b7908af8", "1?trunkcid") in new stack
-- Goto (macro-outbound-callerid,s,12)
-- Executing [s@macro-outbound-callerid:12] ExecIf("SIP/209-b7908af8", "0|Set|CALLERID(all)=") in new stack
-- Executing [s@macro-outbound-callerid:13] ExecIf("SIP/209-b7908af8", "0|Set|CALLERID(all)=") in new stack
-- Executing [s@macro-outbound-callerid:14] ExecIf("SIP/209-b7908af8", "0|SetCallerPres|prohib_passed_screen") in new stack
-- Executing [s@macro-dialout-trunk:12] ExecIf("SIP/209-b7908af8", "1|AGI|fixlocalprefix") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/fixlocalprefix
-- AGI Script fixlocalprefix completed, returning 0
-- Executing [s@macro-dialout-trunk:13] Set("SIP/209-b7908af8", "OUTNUM=01423564512") in new stack
-- Executing [s@macro-dialout-trunk:14] Set("SIP/209-b7908af8", "custom=SIP/SIP01") in new stack
-- Executing [s@macro-dialout-trunk:15] ExecIf("SIP/209-b7908af8", "0|Set|DIAL_TRUNK_OPTIONS=M(setmusic^)") in new stack
-- Executing [s@macro-dialout-trunk:16] Macro("SIP/209-b7908af8", "dialout-trunk-predial-hook|") in new stack
-- Executing [s@macro-dialout-trunk-predial-hook:1] MacroExit("SIP/209-b7908af8", "") in new stack
-- Executing [s@macro-dialout-trunk:17] GotoIf("SIP/209-b7908af8", "0?bypass|1") in new stack
-- Executing [s@macro-dialout-trunk:18] GotoIf("SIP/209-b7908af8", "0?customtrunk") in new stack
-- Executing [s@macro-dialout-trunk:19] Dial("SIP/209-b7908af8", "SIP/SIP01/01423564512|300|") in new stack
-- Called SIP01/01423564XXX
-- SIP/SIP01-0a23f368 is making progress passing it to SIP/209-b7908af8
== Spawn extension (macro-dialout-trunk, s, 19) exited non-zero on 'SIP/209-b7908af8' in macro 'dialout-trunk'
== Spawn extension (macro-dialout-trunk, s, 19) exited non-zero on 'SIP/209-b7908af8'
-- Executing [h@macro-dialout-trunk:1] Macro("SIP/209-b7908af8", "hangupcall|") in new stack
-- Executing [s@macro-hangupcall:1] GotoIf("SIP/209-b7908af8", "1?skiprg") in new stack
-- Goto (macro-hangupcall,s,4)
-- Executing [s@macro-hangupcall:4] GotoIf("SIP/209-b7908af8", "1?skipblkvm") in new stack
-- Goto (macro-hangupcall,s,7)
-- Executing [s@macro-hangupcall:7] GotoIf("SIP/209-b7908af8", "1?theend") in new stack
-- Goto (macro-hangupcall,s,9)
-- Executing [s@macro-hangupcall:9] Hangup("SIP/209-b7908af8", "") in new stack
== Spawn extension (macro-hangupcall, s, 9) exited non-zero on 'SIP/209-b7908af8' in macro 'hangupcall'
== Spawn extension (macro-hangupcall, s, 9) exited non-zero on 'SIP/209-b7908af8'

Re: Carrier Setting Help

PostPosted: Thu Jul 18, 2013 3:37 pm
by senate014
I'm all sorted now!!!!!! :o :o :o :o

This link is what did it for me, read from the start and this is the major thing that you need to get right

http://www.vicidial.org/VICIDIALforum/v ... f=7&t=7449

Look for SIPtrunk in the [globals] section and change it to:

SIPtrunk=SIP/SIP01 (<<< this is the name of my trunk "SIP01")

Look for the line 'dial a long distance outbound number' and we will modify the 9 lines below it. (ignoring comment lines)
First comment the 3 lines directly below it. These are used to send outbound calls to TRUNKX (Zap/g2).
Skip over the next 3 lines and then uncomment the final 3 lines ('dial a long distance outbound number through a SIP provider').
And change them to this:

exten => _91NXXNXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _91NXXNXXXXXX,2,Dial(${SIPtrunk}/${EXTEN:1},55,o)
exten => _91NXXNXXXXXX,3,Hangup

I've highlighted in RED the extremely important bits to make your VICIdialNow (GoAutoDial) server dial out! :)

Re: Carrier Setting Help

PostPosted: Thu Jul 18, 2013 7:31 pm
by gardo
Thank you for posting your solution. Great to hear that everything is working fine now. :D