header("Pragma: No-Cache"); ?>
*** important note 2004-01-08: ***I'm currently not working on this stuff. Since the code is more than one year old i can not guarantee that it will work for you. As you know, asterisk is in heavy development and every few weeks there is a new release in the CVS, sometimes even with huge changes in concepts and code. Please note, that DynExtenDB only works with CAPI drivers. IT DOES NOT WORK WITH ZAPTEL. There are other simple solutions to handle high numbers of extensions. I'm currently handling a 7-digit number-block (guess how many that is) without DynExtenDB. Regards, Andy
DynExtenDB is a simple solution to manage a huge amount of extensions which change quite often.
DynExtenDB is something like your old extensions.conf, but it changes the way extensions are used. Your extensions will (additionally to extensions.conf) exist in a MySQL database and are only registered when used.
There is one really big advantage:
Your extensions.conf is STATIC - it has to be rewritten if something changes.
But your MySQL database is dynamic, and so is DynExtenDB: it makes your asteriskpbx 'dynamic' for your extensions. That means that your extensions are not anymore loaded once and registered statically when you launch asterisk, but instead your extensions will be queried in 'real-time' from MySQL and registered each time someone calls the specific DNID. By the way, did you try to have 50,000 extensions in your extensions.conf?
Please note that DynExtenDB isn't finished yet. It works great for my applications, but maybe it won't be useful for you - who knows. Feedback welcome.
I'm aware of the fact that there are already some other possibilities to manage your dialplan. But I like the idea to have a dynamically configured dialplan with 'extensions-just-in-time' functionality.
Have a look at get_the_idea.html
all extensions matching this pattern will be in the database. this line instructs asterisk to have a look at the database, fetch the dialplan for the specific extension, and handle the call. afterwards the dialplan for this extension will be unregistered again, until the next call comes in for that extension. every extensions can have its own dialplan.
that means:
you need only 1 line in extensions.conf for 10,000+ or more extensions (as many as fit in your mysql table)
Every extension which is not statically in your extensions.conf is in the database - asterisk will look there and handle the call. (read INSTALL file)The way:
- completely dynamic handling of extensions: you or your users can change the behavior of every single extension like you want, for example with a simple CGI or PHP web-interface script running on your asterisk box accessing the MyExtenDB table. (please: develop a webinterface and send it to me!) - no need for cronjobs, no need for creating new files, no generating of new extensins.conf and even no reloading of asterisk after you changed dialplans! all changes are directly available. - can handle a real huge amount of extensions without having them registered all the time. MySQL is still pretty fast with some hundred thousand rows in a table.
- not really tested yet - not really finished yet

this is a very basic first-step script to edit extensions in MySQL. you probably will write your
own script some day, because you have a lot of extensions, and you'll change your extensions from your applications.
Andreas Otto (Cologne Germany) mail <at> andreasotto.net (replace @ sign) find me on irc.openprojects.net #asterisk / #asterisk.de nick 'andio' thanx to: Klaus-Peter Junghanns alias 'kapejod' for creating the state-of-the-art channeldriver for ISDN: http://www.junghanns.net/ast.php chan_capi rules :) and: Carsten (Berlin) AVM for your support and AVM for great hardware I would like to keep this as an module for the next time. If you have good ideas and would like to contribute, please let me know! I'm open for all your ideas and requests. - andio
ChangeLog: ========== 0.0.3a ------------------ 2002-12-15 fixed bug with last priority had been inserted twice please update 0.0.3 ------------------ 2002-12-15 .conf only read once, cleaning up, bugfixes, included simple edit-extensions.php example 0.0.2 ------------------ 2002-12-15 bug fixes, not released 0.0.1 ------------------ 2002-12-14 initial release 0.0.1