Trunk can not find extenstion

Hello All,

Just updated to asterisk 1.6.2.6 , on Centos5 ,using the Asterisk-GUI to configure. All extensions can call each other with audio correctly. Set up a new ,never used trunk from ipkall to the asterisk server using the normal configuring within Asterisk-GUI. When I call from cell phone, using the assign DID from ipkall the call does in fact get routed to ,and hit the asterisk server,but never rings the extension.
Here is what the asterisk-cli shows:

Notice[31455]: Call from ‘trunk_1’ to extension ‘6000’ rejected because extension not found .

I do have the trunk set to forward the call to this extension. - 6000

I can call this extension from one of the other phones internally. I did search this exact error but can not find out what a resolve is. How can I troubleshoot this scenario? I m not sure how to filter down Wireshark to figure out what the miscommuncation is between the trunk> to the extension. Is there possibly some hand configuring I have to do to the trunk config,that asterisk-gui can not provide for possibly newer variables in asterisk 1.6.x?

Thanks,
Barry

The trunk is probably in the wrong context.

I have that suspicion, too. However, until OP posts his dialplans, there is no way to know for sure.

david55,

In the asterisk-gui there is no option to change context? I assume I need to hand edit the file itself? I have found in a test/sandbox quite sometime back,if you hand edit any file produced/parsed by asterisk-gui,the file ends up with lots of white spaces,double entries,etc?
Any ideas,what a good context would be?
This is an ipkall.com trunk.

Thanks,
Barry

extensions.conf

DIALOPTIONS =
RINGTIME = 20
FOLLOWMEOPTIONS =
PAGING_HEADER = Intercom
PAGING_TIMEOUT = 60
trunk_1 = SIP/trunk_1
CID_6001 = vanaccess 0020

[DID_trunk_1]
include = DID_trunk_1_default
include = DID_trunk_1_timeinterval_All Day|${timeinterval_All Day}
include = DID_trunk_1_default
[DID_trunk_1_default]
[CallingRule_ipkall]
[CallingRule_Longdistance]
exten = _91XXXXXXXXXX!,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:1}, , , )
[CallingRule_IAXTEL]
exten = _91700XXXXXXX!,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:1}, , , )
[CallingRule_Local_AreaCode]
exten = _9256XXXXXXX!,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:4}, , , )
[CallingRule_International]
exten = _9011XXXXX.,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:1}, , , )
[CallingRule_Local_7_digits]
exten = _9XXXXXXX!,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:1}, , , )
[CallingRule_Emergency]
exten = _911!,1,Macro(trunkdial-failover-0.3,${}/${EXTEN:0}, , , )
[CallingRule_ipkallout]
exten = 2062035991,1,Macro(trunkdial-failover-0.3,${trunk_1}/${EXTEN:0},trunk_1,)

[DLPN_DialPlan1]
include = default
include = parkedcalls
include = conferences
include = ringgroups
include = voicemenus
include = queues
include = voicemailgroups
include = directory
include = pagegroups
include = page_an_extension
[DID_trunk_1_timeinterval_All Day]
exten = 2062035991,1,Goto(default|6001|1)

users.conf

username = 6001
type = peer
host = 192.168.0.242
transfer = yes
mailbox = 6001
call-limit = 100
fullname = vanaccess 0200
registersip = no
host = dynamic
callgroup = 1
context = DLPN_DialPlan1
cid_number = 6001
hasvoicemail = yes
vmsecret = 55
email = usertwo@eazylivin.net
threewaycalling = no
hasdirectory = no
callwaiting = no
hasmanager = no
hasagent = no
hassip = yes
hasiax = no
secret =
nat = no
canreinvite = no
dtmfmode = rfc2833
insecure = port,invite
pickupgroup = 1
autoprov = no
label =
macaddress =
linenumber = 1
LINEKEYS = 1
disallow = all
allow = ulaw,gsm

[6001]
username = 6001
transfer = yes

mailbox = 6001
call-limit = 100
fullname = 6001

registersip = no
host = dynamic
callgroup = 1
context = DLPN_DialPlan1
cid_number = 6001
hasvoicemail = yes
vmsecret = 55,55
email = usertwo@eazylivin.net,usertwo@eazylivin.net,usertwo@eazylivin.net,usertwo@eazylivin.net
threewaycalling = no
hasdirectory = no
callwaiting = no
hasmanager = no
hasagent = no
hassip = yes
hasiax = no
secret = ,
nat = no
canreinvite = no
dtmfmode = rfc2833
insecure = no
pickupgroup =
autoprov = yes
label = 6001

[trunk_1]
context = DID_trunk_1
host = voiper.ipkall.com
trunkname = ipkall ; GUI metadata

hasiax = no
registeriax = no
hassip = yes
registersip = yes
trunkstyle = voip
hasexten = no

allow = all
insecure = port,invite
secret =
username =


Sorry this should have been a pastebin,but was in a hurry and getting pestered here as well with q&a sessions one after the other…:smile:

Thanks,
Barry

I can’t tell you how to do this from your GUI, but you need to put definitions for 6000, etc., in DID_trunk_1_default, or DID_trunk_1_timeinterval_All Day, depending on which times of day you want people to be able to call the numbers from outside.

david55,

Could you possibly do a copy/paste of the above ,to what you think a trunk config would be valid. The way asterisk-gui ‘macros’ everything I can not decypher,what things should look like.

Thanks,
Barry

You don’t seem to have an extension 6000, anyway. Also you seem to be missing the default context, which is referenced from that dialplan. As you are also missing all the macro defintions, I assume you have missed out large parts of the dialplan. If you did have an extension 6000 and if you did have an appropriate default context, it would look something like the entry you already have in the daytime context, but with both numbers replaced by 6000.

I guess the current entry assumes that your PSTN access provider gives you the actual dialled number, but they are actually giving you your local extension number. I think you need to talk to the service provider to work out exactly what they are offering.

As configured, if they sent you 2062035991, and if the default context included something that amounted to:

6001,1,Dial(SIP/6001)

you would connect through to your extension.

If the GUI is worth using at all, this really ought to be trivial to configure. This is not a case where the principle that GUIs make simple things very easy and complex things impossible, should be erring to the impossible side.

david,

sorry i should have added more info, the DID provided by ipkall is 2062035591
the ext(registered) connected to asterisk id like to have this number hit is 6001
can you give an top to bottom trunk/extension.conf example?
BTW: I can ring the extensions from an remote extension(from work) for example,so I am pretty sure the trunk setup is hosed in some way?
The asterisk-gui macros have me totally baffled,which don’t take much…:smile:

Thanks a million!

Barry

2062035591 can’t be a DID, except in the loose way often used here. To be a DID, you need to have a range of numbers.

Your original message says that it is complaining about extension 6000, which looks like your PSTN access provider is sending that, rather than your public phone number, but your configuration expects your public phone number.

You haven’t provided a complete copy of extensions.conf, and I suspect the complete copy would include a default context.

You only have one extension defined, so I don’t see how you could call from one extension to another, unless you are allowing anonymous callers.