VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
Claudio.Cavalera at it... Guest
|
Posted: Mon Feb 18, 2008 10:53 am Post subject: [asterisk-users] realtime table customization to track iax r |
|
|
Hello,
I'm experimenting with Asterisk and MySQL.
Up to know I've just put iax.conf in a MySQL database and it seems to
work: when a Iax2 client registers the corrispondent row in db is
updated. Good.
However when I have many asterisk boxes pointing to the same db a
problem arises: I need an additional column in iax_buddies table called
for example "Asterisk ID" which tells me on which asterisk box a
particular user is registered. Is there a way to achieve this? I've seen
this function:
ASB*CLI>
-= Info about function 'REALTIME' =-
[Syntax]
REALTIME(family|fieldmatch[|value[|delim1[|delim2]]]) on read
REALTIME(family|fieldmatch|value|field) on write
[Synopsis]
RealTime Read/Write Functions
[...]
but I don't think I can use this during client registration as it will
only be available in dialplan.
Any hints appreciated.
Regards,
Claudio
Internet Email Confidentiality Footer
-----------------------------------------------------------------------------------------------------
La presente comunicazione, con le informazioni in essa contenute e ogni documento o file allegato, e' rivolta unicamente alla/e persona/e cui e' indirizzata ed alle altre da questa autorizzata/e a riceverla. Se non siete i destinatari/autorizzati siete avvisati che qualsiasi azione, copia, comunicazione, divulgazione o simili basate sul contenuto di tali informazioni e' vietata e potrebbe essere contro la legge (art. 616 C.P., D.Lgs n. 196/2003 Codice in materia di protezione dei dati personali). Se avete ricevuto questa comunicazione per errore, vi preghiamo di darne immediata notizia al mittente e di distruggere il messaggio originale e ogni file allegato senza farne copia alcuna o riprodurne in alcun modo il contenuto.
This e-mail and its attachments are intended for the addressee(s) only and are confidential and/or may contain legally privileged information. If you have received this message by mistake or are not one of the addressees above, you may take no action based on it, and you may not copy or show it to anyone; please reply to this e-mail and point out the error which has occurred.
----------------------------------------------------------------------------------------------------- |
|
Back to top |
|
|
benny+usenet at amorse... Guest
|
Posted: Tue Feb 19, 2008 12:45 pm Post subject: [asterisk-users] realtime table customization to track iax r |
|
|
"Cavalera Claudio Luigi" <Claudio.Cavalera at italtel.it> writes:
Quote: | Hello,
I'm experimenting with Asterisk and MySQL.
Up to know I've just put iax.conf in a MySQL database and it seems to
work: when a Iax2 client registers the corrispondent row in db is
updated. Good.
However when I have many asterisk boxes pointing to the same db a
problem arises: I need an additional column in iax_buddies table called
for example "Asterisk ID" which tells me on which asterisk box a
particular user is registered.
|
I have solved this by creating views for each asterisk, like this:
create view customer1_sip as select * from sip where customer = 'customer1';
and so on. This works in MySQL which has updatable views, but not in
PostgreSQL, but you can achieve the same effect with triggers I
believe.
It is not a particularly nice solution because you need to remove and
recreate all views if you add a new column to the table. We're going
back to generating config files from a database though.
/Benny |
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|