[Asterisk-Users] SIP peers in MySQL Database
harry gaillac
gaillacharry at yahoo.fr
Wed Oct 13 03:50:54 MST 2004
I agree you a database server must be available for
any applications.
but pbx office get conf from database with perl script
so pbx keep sip config not like ser getting conf from
sql server
harry
--- Bill Seddon <bill.seddon at lyquidity.com> a écrit :
> I'm sure you've considered it, but having
> distributed asterisk services
> dependent upon one instance of SQL Server at remote
> location always being
> available seems a weak point in the design. If the
> SQL Server node is not
> available, all asterisk users will be affected.
>
> Have you considered using one master sql server
> instance with local msde
> instances (no license issues) and use replication
> services to ensure each
> slave copy is updated as needed? It may make for a
> more robust solution in
> a multi-node environment.
>
> -----Original Message-----
> From: asterisk-users-bounces at lists.digium.com
> [mailto:asterisk-users-bounces at lists.digium.com] On
> Behalf Of harry gaillac
> Sent: October 13, 2004 10:56 AM
> To: Asterisk Users Mailing List - Non-Commercial
> Discussion
> Subject: Re: [Asterisk-Users] SIP peers in MySQL
> Database
>
> I don't try the perl script. here is what I expect
> from asterisk and sql database for example.
>
> one asterisk pbx per office, several offices,one sql
> server.I want to admin all sip conf offices from sql
> server
>
> I create one sip table per office on my database
> server.
>
> each pbx office get his sip conf from sql server.
>
> If i add or remove sip clients on my sql server how
> pbx office update his sip conf ?
>
> Harry
>
>
> --- Matthew Boehm <mboehm at cytelcom.com> a écrit :
> > > How do you update many pbx ? crontab ?
> >
> > How often are you needing to update them? Hourly?
> > Daily? I only have 1 * box
> > so I currently use the perl script method on our
> > prod server. I'm using the
> > RealTime on our dev server.
> >
> > RealTime will deffinatly be easier once it has
> > become stablized. You will be
> > able to have multiple Sip tables in 1 database
> > server that can handle
> > multiple * machines.
> >
> > Be patient..
> > -Matthew
> >
> > >
> > > Best regards
> > > Harry
> > >
> > > NB: everybody should be able to find a full
> > > documentation about Asterisk features not in
> > mailing
> > > list.
> > > I look at voip-info.
> > >
> > > --- Matthew Boehm <mboehm at cytelcom.com> a écrit
> :
> > > > Yes you are wrong. You seem to be combining
> two
> > > > different methods of getting
> > > > SIP info out of a database. Pick 1. I use the
> > perl
> > > > script right now so here
> > > > is how to do that:
> > > >
> > > > In order to use the perl script which can
> > support
> > > > 'ALL' sip abilities, use
> > > > this table:
> > > >
> > > > CREATE TABLE sip_perl (
> > > > id INT(11) DEFAULT -1 NOT NULL,
> > > > keyword VARCHAR(20) NOT NULL,
> > > > data VARCHAR(50) NOT NULL,
> > > > flags INT(1) DEFAULT 0 NOT NULL,
> > > > PRIMARY KEY (id,keyword)
> > > > );
> > > >
> > > > Then, insert a new row for each sip parameter
> > > > keeping the 'id' the same for
> > > > each phone:
> > > >
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'account', '3038', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'callerid', '"Cytel" <2814494000>', 1);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'nat', 'yes', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'context', 'cytel-internal', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'type', 'friend', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'mailbox', '3038 at cytel', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'secret', '3038joshdana', 0);
> > > > INSERT INTO `sip_perl` (`id`, `keyword`,
> `DATA`,
> > > > `flags`) VALUES (3038,
> > > > 'host', 'dynamic', 0);
> > > >
> > > > Edit the perl script to match. Then run the
> perl
> > > > script. It should
> > > > create/overwrite whatever file you set in it
> and
> > > > produce a new .conf
> > > >
> > > > Go into sip.conf and add a #include line for
> > this
> > > > new file.
> > > >
> > > > Matthew
> > > >
> > > > ----- Original Message -----
> > > > From: "harry gaillac" <gaillacharry at yahoo.fr>
> > > > To: "Asterisk Users Mailing List -
> > Non-Commercial
> > > > Discussion"
> > > > <asterisk-users at lists.digium.com>
> > > > Sent: Monday, October 11, 2004 6:42 PM
> > > > Subject: Re: [Asterisk-Users] SIP peers in
> MySQL
> > > > Database
> > > >
> > > >
> > > > > I read the perl script.
> > > > > here is table structure for table
> `sipfriends`
> > > > >
> > > > > CREATE TABLE `sipfriends` (
> > > > > `name` varchar(40) NOT NULL default '',
> > > > > `secret` varchar(40) NOT NULL default '',
> > > > > `context` varchar(40) NOT NULL default '',
> > > > > `username` varchar(40) default '',
> > > > > `ipaddr` varchar(20) NOT NULL default '',
> > > > > `port` int(6) NOT NULL default '0',
> > > > > `regseconds` int(11) NOT NULL default '0',
> > > > > PRIMARY KEY (`name`)
> > > > > ) TYPE=MyISAM;
> > > > >
> > > > > I would like asterisk retrieve all
> sipfriends
> > > > > variables
> > > > > from database.
> > > > >
> > > > > I wish to add other variables for each sip
> > clients
> > > > > like qualify, nat, ... in sipfriends table
> but
> > sip
> > > > > code channel don't seem to be able to
> support
> > > > others
> > > > > variables.
> > > > > may be i'm wrong ?
> > > > >
> > > > > best regards
> > > > > harry
> > > > >
> > > > > --- Matthew Boehm <mboehm at cytelcom.com> a
> > écrit :
> > > > > > It is possible to use 1 database for many
> > > > asterisk
> > > > > > boxes. You can do this
> > > > > > with the retreive script I mentioned. By
> > adding
> > > > > > another column to the
> > > > > > database to indicate which * server that
> > phone
>
=== message truncated ===
Vous manquez despace pour stocker vos mails ?
Yahoo! Mail vous offre GRATUITEMENT 100 Mo !
Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/
Le nouveau Yahoo! Messenger est arrivé ! Découvrez toutes les nouveautés pour dialoguer instantanément avec vos amis. A télécharger gratuitement sur http://fr.messenger.yahoo.com
More information about the asterisk-users
mailing list