I've RTFM and Googled but can't seem to get sip_autoreg to work (or
perhaps I'm just completely missing the point of it).
(what I'd like to do is avoid having to put explicit entries for every
SIP phone into extensions.conf).
Asterisk is creating entries in the (virtual) context sip_autoreg:
asterisk*CLI> dialplan show sip_autoreg
[ Context 'sip_autoreg' created by 'SIP' ]
'112' => 1. Noop(112)
[SIP]
'113' => 1. Noop(113)
[SIP]
'114' => 1. Noop(114)
[SIP]
-= 3 extensions (3 priorities) in 1 context. =-
asterisk*CLI>
....and in my dialplan I have:
[from-sip]
include => actual_sip_autoreg
include => other_stuff_and_widgets
...in [actual_sip_autoreg] I have:
[actual_sip_autoreg]
include => sip_autoreg
exten => _.,n,NoOp("Here I am Mr Mgoo")
exten => _.,n,Playback(tt-weasels)
But when a SIP phone dials 114 the "Here I am Mr Mgoo" NoOp
doesn't get
executed. Here's what the console says:
asterisk*CLI>
-- Executing [114 at from-sip:1] NoOp("SIP/Russell-0071e7b0",
"114") in new stack
-- Executing [114 at from-sip:2]
Congestion("SIP/Russell-0071e7b0", "") in new stack
== Spawn extension (from-sip, 114, 2) exited non-zero on
'SIP/Russell-0071e7b0'
asterisk*CLI>
...a "dialplan show actual_sip_autoreg" produces:
asterisk*CLI> dialplan show actual_sip_autoreg
[ Context 'actual_sip_autoreg' created by 'pbx_config' ]
'_.' => 7. NoOp("Here I am Mr Mgoo")
[pbx_config]
8. Playback(tt-weasels) [pbx_config]
Include => 'sip_autoreg' [pbx_config]
-= 1 extension (2 priorities) in 1 context. =-
asterisk*CLI>
So... anyone got any idea why the NoOp and thence the Weasels don't get
executed?
Ta in advance.
--
Regards,
Russell
--------------------------------------------------------------------
| Russell Brown | MAIL: russell at lls.com PHONE: 01780 471800 |
| Lady Lodge Systems | WWW Work: http://www.lls.com |
| Peterborough, England | WWW Play: http://www.ruffle.me.uk |
--------------------------------------------------------------------
On 5 Aug 2007, at 16:46, Russell Brown wrote:> > I've RTFM and Googled but can't seem to get sip_autoreg to work (or > perhaps I'm just completely missing the point of it). > > (what I'd like to do is avoid having to put explicit entries for every > SIP phone into extensions.conf). > > Asterisk is creating entries in the (virtual) context sip_autoreg: > > asterisk*CLI> dialplan show sip_autoreg > [ Context 'sip_autoreg' created by 'SIP' ] > '112' => 1. Noop > (112) [SIP] > '113' => 1. Noop > (113) [SIP] > '114' => 1. Noop > (114) [SIP] > -= 3 extensions (3 priorities) in 1 context. =- > asterisk*CLI> > > ....and in my dialplan I have: > > [from-sip] > include => actual_sip_autoreg > include => other_stuff_and_widgets > > > ...in [actual_sip_autoreg] I have: > > [actual_sip_autoreg] > include => sip_autoreg > exten => _.,n,NoOp("Here I am Mr Mgoo") > exten => _.,n,Playback(tt-weasels) > > > But when a SIP phone dials 114 the "Here I am Mr Mgoo" NoOp doesn't > get > executed. Here's what the console says: > > asterisk*CLI> > -- Executing [114 at from-sip:1] NoOp("SIP/Russell-0071e7b0", > "114") in new stack > -- Executing [114 at from-sip:2] Congestion("SIP/ > Russell-0071e7b0", "") in new stack > == Spawn extension (from-sip, 114, 2) exited non-zero on 'SIP/ > Russell-0071e7b0' > asterisk*CLI> > > ...a "dialplan show actual_sip_autoreg" produces: > > asterisk*CLI> dialplan show actual_sip_autoreg > [ Context 'actual_sip_autoreg' created by 'pbx_config' ] > '_.' => 7. NoOp("Here I am Mr Mgoo") [pbx_config] > 8. Playback(tt-weasels) [pbx_config] > Include => 'sip_autoreg' [pbx_config] > -= 1 extension (2 priorities) in 1 context. =- > asterisk*CLI> > > So... anyone got any idea why the NoOp and thence the Weasels > don't get > executed? > > Ta in advance. > >I don't think the first 'n' is doing what you want it to, try putting: exten => _.,2,NoOp("Here I am Mr Mgoo") instead. Tim Panton www.mexuar.net www.westhawk.co.uk/