[Asterisk-Users] Pattern matching rules for least cost routing
Mark Elkins
mje at posix.co.za
Tue Apr 20 15:21:33 MST 2004
I've got two patterns I want to match on making an outgoing call...
(one day - to do Least Cost Routing for Cell/Mobile calls)
Firstly - I prefer '0' rather than '9' to get an outside line...
Either its a call to a mobile No... (072 -or- 082 -or- 083 -or- 084)
or its just another number to dial...
I added the following... the playback just advises me which 'route' is
being taken.... In 'extentions.conf' I have...
;Cell Phone call
exten => _00[78][234].,1,Playback(posix-cellphone)
exten => _00[78][234].,2,Dial(${TRUNK}:${EXTEN:${TRUNKMSD}})
;Default catch all - just dial it....
exten => _0.,1,Playback(posix-defaultroute)
exten => _0.,2,Dial(${TRUNK}:${EXTEN:${TRUNKMSD}})
No matter what is dialled - I always go out on the 'Default' line.
Swapping order makes no difference. If I comment out the 'default' - it
does match the 'Cell' pattern - and works.
Shouldn't the number I dial match the longest match - not the shortest
match as it seems to be doing? Is there a way to change that logic??
--
. . ___. .__ Posix Systems - Sth Africa
/| /| / /__ mje at posix.co.za - Mark J Elkins, Cisco CCIE
/ |/ |ARK \_/ /__ LKINS Tel: +27 12 807 0590 Cell: +27 82 601 0496
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.digium.com/pipermail/asterisk-users/attachments/20040420/4c83986a/attachment.pgp
More information about the asterisk-users
mailing list