[Asterisk-Users] Extension context problem

Don asterisk at geeksrus.ca
Tue May 17 16:32:15 MST 2005



Ok... first, I'm using AAH 1.0 which has a full dialplan already laid 
out.  My reason for using AAH is largely because it starts as a fully 
laid out dialplan.  But I am doing my own management of my extensions 
and sip entries because AMP doesn't do all the parameters I want for my 
polycom phones.  I plan to manage these with my own perl scripts. 

The problem I am having currently is that I have my phones set with 
"context=from-internal".  But when I dial from them, I get the 
"congestion" pattern and in the verbose asterisk console it tells me 
that the dial came from "context=from-sip-external" which has the 
comment as being "unknown SIP callers".  I have no idea why this is 
happening... I'm wondering if it has something to do with registration 
or passwords or something??  Any advice would be appreciated.

Don


Asterisk says this when I dial extension 221 from extension 225
*CLI>     -- Executing AbsoluteTimeout("SIP/192.168.2.1-095e4bc0", "15") 
in new stack
    -- Set Absolute Timeout to 15
    -- Executing Congestion("SIP/192.168.2.1-095e4bc0", "") in new stack
  == Spawn extension (from-sip-external, 221, 2) exited non-zero on 
'SIP/192.168.2.1-095e4bc0'
    -- Executing AbsoluteTimeout("SIP/192.168.2.1-095e4bc0", "15") in 
new stack
    -- Set Absolute Timeout to 15
    -- Executing Congestion("SIP/192.168.2.1-095e4bc0", "") in new stack
  == Spawn extension (from-sip-external, h, 2) exited non-zero on 
'SIP/192.168.2.1-095e4bc0'

An example of one of my phone entries in the "sip.conf" file is given below.

=== sip.conf example
[225]
username=225
type=peer
secret=2255
qualify=no
port=5060
nat=never
mailbox=
host=192.168.2.225
defaultip=192.168.2.225
dtmfmode=inband
context=from-internal
canreinvite=no
callerid="Don Murray" <225>
progressinband=no

extension.conf includes:
[ext-local]
include => ext-local-custom
exten => 999,1,Macro(exten-vm,999 at default,999)
exten => 221,1,Macro(exten-vm,221 at default,221)
exten => 225,1,Macro(exten-vm,225 at default,225)

and
[from-internal]
...
include => ext-local
...

[macro-exten-vm]
exten => s,1,Setvar(FROMCONTEXT=exten-vm)
exten => s,2,GotoIf($[${CHANNEL:0:5} = Local]?novm,1:3)  ; if the 
channel is Local, then do not go to voicemail.  This is primarily to 
avoid vm for call-forwarded extensions in ring groups
exten => s,3,GotoIf($[${ARG1} = novm]?novm,1)
exten => s,4,Macro(dial,${RINGTIMER},${DIAL_OPTIONS},${ARG2})
exten => s,5,Wait(1)
exten => s,6,Voicemail(u${ARG1})      ; no answer to voicemail
exten => s,7,Macro(hangupcall)
exten => s,106,Wait(1)
exten => s,107,Voicemail(b${ARG1})
exten => o,1,Background(one-moment-please)      ; 0 during vm message 
will hangup
exten => o,2,goto(from-pstn,s,1)
exten => a,1,Goto(app-directory,*411,1)
exten => a,2,Hangup
exten => novm,1,Macro(dial,120,${DIAL_OPTIONS},${ARG2})
exten => novm,2,Wait(1)
exten => novm,3,Playback(vm-nobodyavail)
exten => novm,4,Playback(allison7/pls-try-call-later)
exten => novm,5,Hangup







More information about the asterisk-users mailing list