[Asterisk-Users] Dial Plan Problems

Ian Chilton mailinglist at ichilton.co.uk
Tue Dec 14 03:32:39 MST 2004


Hi,

I am having a few dial plan problems which I wondered if anyone would be
able to help with.

Firstly, I wanted to send 0800 calls through 1 sip provider and other
08xx calls through another. I have this:

  exten => _0800.,1,Dial(SIP/${EXTEN}@provider1,30)
  exten => _0800.,2,Congestion

  exten => _08.,1,Dial(SIP/${EXTEN}@provider2,30)
  exten => _08.,2,Congestion

However, whichever way round I put these, 0800 calls still seem to go
out of provider2.

I fixed this as follows:

  exten => _08[1-9].,1,Dial(SIP/${EXTEN}@provider2,30)
  exten => _08[1-9].,2,Congestion

..but, is there another way of getting this working without putting
exceptions into other dial plan rules? - it works in this example but
would be a pain in anything more complicated.

For example, I had the same problem with a provider who has some service
numbers in the format 09XX but the dial plan for these was not getting
detected because of my _0. dial plan for national phone calls.

Am I missing something here?


Also, I can't seem to get the invalid extension working. I have a
context which has some incoming calls sent to it. I then have an
extension for each number. What I want is to play an invalid message if
anyone comes into that context on another number.

I tried this by commenting the entries for 1 of my working numbers out
and putting this in:

  exten => i,1,Playback(invalid)
  exten => i,2,Hangup

.. but when I call the number I commented out, Asterisk doesn't see the
call (no logging) - I just get a beep and the call ends. If I put the
extension for that number back in, it works fine.

Any ideas?


Thanks!

--ian




More information about the asterisk-users mailing list