Re: [asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-17 Thread Jonas Kellens

Remove yourself !

Don't hijack my thread !



On 17-08-16 14:53, Dario Estupinan wrote:

REMOVE ME please.

2016-08-15 15:16 GMT-05:00 Jonas Kellens >:


Hello

after I have upgraded from Asterisk 12 to
asterisk-certified-13.8-cert1 none of my realtime SIP peers (saved
in MySQL DB) register anymore.


[Aug 15 22:03:43] NOTICE[30098]: chan_sip.c:28451
handle_request_register: Registration from
'>' failed for
'78.119.140.190:5076 ' - Wrong password
[Aug 15 22:04:13] NOTICE[30098]: chan_sip.c:28451
handle_request_register: Registration from
'>' failed for
'78.119.140.190:5072 ' - Wrong password
[Aug 15 22:04:43] NOTICE[30098]: chan_sip.c:28451
handle_request_register: Registration from
'>' failed for
'78.119.140.190:5062 ' - Wrong password
[Aug 15 22:04:46] NOTICE[30098]: chan_sip.c:28451
handle_request_register: Registration from
'>' failed for
'78.119.140.190:5060 ' - Wrong password
[Aug 15 22:04:53] NOTICE[30098]: chan_sip.c:28451
handle_request_register: Registration from
'>' failed for
'78.119.140.190:5060 ' - Wrong password


Is this a known problem ??


Second question I have : can I get the complete list of columns
that can be used in realtime database for sip peers somewhere
(update for Ast 13) ? Are columns like dtlsenable, dtlsverify,
dtlscertfile, dtlscafile, dtlssetup possible ??




Thanks for the help.


Kind regards.

Jonas.

-- 
_

-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users





--
**
*DARIO ESTUPIÑAN V.*
*Líder de NOC+*
*Cel: 3008832295*
*E-Mail: darioestupi...@soygenial.co *




Antes de imprimir este mensaje, asegúrese de que es necesario. 
Proteger el medio ambiente está también en sus manos.



AVISO LEGAL: Este mensaje es confidencial, puede contener información 
privilegiada y no puede ser usado ni divulgado por personas distintas 
de su destinatario. Si recibe este correo por error, por favor 
elimínelo y avise a su remitente. Está prohibida su retención, 
grabación, utilización, aprovechamiento o divulgación con cualquier 
propósito. La Corporación Politécnica Nacional de Colombia no asume 
ninguna responsabilidad por eventuales daños generados por el recibo y 
el uso de este material, siendo responsabilidad del destinatario 
verificar con sus propios medios la existencia de virus u otros 
defectos. El presente correo electrónico solo refleja la opinión de su 
Remitente y no representa necesariamente la opinión oficial de la 
Corporación o de sus Directivos.






-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-17 Thread John Novack

Remove yourself

READ - Included with every message -

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users 


Dario Estupinan wrote:


asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users 




--

Dog is my Co-pilot

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-17 Thread Dario Estupinan
REMOVE ME please.

2016-08-15 15:16 GMT-05:00 Jonas Kellens :

> Hello
>
> after I have upgraded from Asterisk 12 to asterisk-certified-13.8-cert1
> none of my realtime SIP peers (saved in MySQL DB) register anymore.
>
>
> [Aug 15 22:03:43] NOTICE[30098]: chan_sip.c:28451 handle_request_register:
> Registration from '' failed for '
> 78.119.140.190:5076' - Wrong password
> [Aug 15 22:04:13] NOTICE[30098]: chan_sip.c:28451 handle_request_register:
> Registration from '' failed for '
> 78.119.140.190:5072' - Wrong password
> [Aug 15 22:04:43] NOTICE[30098]: chan_sip.c:28451 handle_request_register:
> Registration from '' failed for '
> 78.119.140.190:5062' - Wrong password
> [Aug 15 22:04:46] NOTICE[30098]: chan_sip.c:28451 handle_request_register:
> Registration from '' failed for '
> 78.119.140.190:5060' - Wrong password
> [Aug 15 22:04:53] NOTICE[30098]: chan_sip.c:28451 handle_request_register:
> Registration from '' failed for '
> 78.119.140.190:5060' - Wrong password
>
>
> Is this a known problem ??
>
>
> Second question I have : can I get the complete list of columns that can
> be used in realtime database for sip peers somewhere (update for Ast 13) ?
> Are columns like dtlsenable, dtlsverify, dtlscertfile, dtlscafile,
> dtlssetup possible ??
>
>
>
>
> Thanks for the help.
>
>
> Kind regards.
>
> Jonas.
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>   http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>



-- 

*DARIO ESTUPIÑAN V.*
*Líder de NOC+*
*Cel: 3008832295*
*E-Mail: darioestupi...@soygenial.co *




Antes de imprimir este mensaje, asegúrese de que es necesario. Proteger el
medio ambiente está también en sus manos.


AVISO LEGAL: Este mensaje es confidencial, puede contener información
privilegiada y no puede ser usado ni divulgado por personas distintas de su
destinatario. Si recibe este correo por error, por favor elimínelo y avise
a su remitente. Está prohibida su retención, grabación, utilización,
aprovechamiento o divulgación con cualquier propósito. La Corporación
Politécnica Nacional de Colombia no asume ninguna responsabilidad por
eventuales daños generados por el recibo y el uso de este material, siendo
responsabilidad del destinatario verificar con sus propios medios la
existencia de virus u otros defectos. El presente correo electrónico solo
refleja la opinión de su Remitente y no representa necesariamente la
opinión oficial de la Corporación o de sus Directivos.
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-17 Thread Jonas Kellens


On 15-08-16 23:00, Carlos Chavez wrote:



I highly recommend that you use alembic to set up your database as 
this will make sure you are always using the correct database schema.  
You should be able to find the "official" structure in the 
contrib/realtime/mysql directory of the Asterisk source.




Hello

in contrib/realtime/mysql I see a table 'sippeers' with a column 
"transport ENUM('udp','tcp','tls','ws','wss','udp,tcp','tcp,udp') " but 
I see no columns dtlsenable, dtlsverify, dtlscertfile, dtlscafile, 
dtlssetup ?


So if we can define a sip peer with transport 'ws' or 'wss', then why 
are there no columns for the 'dtls'-part (which is kinda mandatory) ?




Kind regards.



--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-15 Thread Carlos Chavez

On 8/15/16 3:16 PM, Jonas Kellens wrote:


Hello

after I have upgraded from Asterisk 12 to 
asterisk-certified-13.8-cert1 none of my realtime SIP peers (saved in 
MySQL DB) register anymore.



[Aug 15 22:03:43] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5076' - 
Wrong password
[Aug 15 22:04:13] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5072' - 
Wrong password
[Aug 15 22:04:43] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5062' - 
Wrong password
[Aug 15 22:04:46] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5060' - 
Wrong password
[Aug 15 22:04:53] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5060' - 
Wrong password



Is this a known problem ??


Second question I have : can I get the complete list of columns that 
can be used in realtime database for sip peers somewhere (update for 
Ast 13) ? Are columns like dtlsenable, dtlsverify, dtlscertfile, 
dtlscafile, dtlssetup possible ??



The first thing you need to test is if you are properly loading the 
realtime data.  The best way would be to enable "rtcachefriends=yes" and 
then "sip show peer XXX load".  If you are not getting anything then 
there is a problem with your realtime setup.  I used realtime sip until 
13.7 before switching to PJSIP so it should work.


I highly recommend that you use alembic to set up your database as 
this will make sure you are always using the correct database schema.  
You should be able to find the "official" structure in the 
contrib/realtime/mysql directory of the Asterisk source.


--
Telecomunicaciones Abiertas de México S.A. de C.V.
Carlos Chávez
+52 (55)9116-91161


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP peers do not register any more after upgrade to Asterisk 13

2016-08-15 Thread Jonas Kellens

Hello

after I have upgraded from Asterisk 12 to asterisk-certified-13.8-cert1 
none of my realtime SIP peers (saved in MySQL DB) register anymore.



[Aug 15 22:03:43] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5076' - Wrong 
password
[Aug 15 22:04:13] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5072' - Wrong 
password
[Aug 15 22:04:43] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5062' - Wrong 
password
[Aug 15 22:04:46] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5060' - Wrong 
password
[Aug 15 22:04:53] NOTICE[30098]: chan_sip.c:28451 
handle_request_register: Registration from 
'' failed for '78.119.140.190:5060' - Wrong 
password



Is this a known problem ??


Second question I have : can I get the complete list of columns that can 
be used in realtime database for sip peers somewhere (update for Ast 13) 
? Are columns like dtlsenable, dtlsverify, dtlscertfile, dtlscafile, 
dtlssetup possible ??





Thanks for the help.


Kind regards.

Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] realtime sip peers status

2012-10-22 Thread Control Oye
Dear All,

I have successfully setup Asterisk realtime. Now I can create extensions 
dynamically. But when I put this command on cli mode

sip show peers

it returns no result.

can any one guide me to fix this problem.

Thanks--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers status

2012-10-22 Thread Ishfaq Malik
On Mon, 2012-10-22 at 19:17 +0500, Control Oye wrote:
 Dear All,
  
 I have successfully setup Asterisk realtime. Now I can create
 extensions dynamically. But when I put this command on cli mode
  
 sip show peers
  
 it returns no result.
  
 can any one guide me to fix this problem.
  
 Thanks
 --

The extensions you have created will not show up in the cli command of
sip show peers until the sip extensions have tried to connect to the
asterisk server.

Ish

-- 
Ishfaq Malik i...@pack-net.co.uk
Department: VOIP Support
Company: Packnet Limited
t: +44 (0)845 004 4994
f: +44 (0)161 660 9825
e: i...@pack-net.co.uk
w: http://www.pack-net.co.uk

Registered Address: PACKNET LIMITED, 2A ENTERPRISE HOUSE, LLOYD STREET
NORTH, MANCHESTER
SCIENCE PARK, MANCHESTER, M156SE
COMPANY REG NO. 04920552


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] realtime sip peers status

2012-10-22 Thread Steven Howes
On 22 Oct 2012, at 15:21, Ishfaq Malik wrote:
 On Mon, 2012-10-22 at 19:17 +0500, Control Oye wrote:
 I have successfully setup Asterisk realtime. Now I can create
 extensions dynamically. But when I put this command on cli mode
 
 sip show peers
 
 it returns no result.
 
 can any one guide me to fix this problem.
 
 The extensions you have created will not show up in the cli command of
 sip show peers until the sip extensions have tried to connect to the
 asterisk server.

You may also need to cache realtime peers for some of the stats you're probably 
after. There are plenty of guides online for this. Google is your friend.

Steve
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-15 Thread Jonas Kellens

On 04/13/2011 09:18 PM, Rob Coward wrote:


Rather than add extra overhead to your dialplan and the asterisk 
server, why not make use of the AMI and have a background process 
listening for the various events and updating your database accordingly ?


See 
http://www.voip-info.org/wiki/view/asterisk+manager+events#ExtensionStatusEvent 
and 
http://search.cpan.org/~greenbean/Asterisk-AMI-v0.2.5/lib/Asterisk/AMI.pm#Events


Regards,

Rob



Hello,

this event tells me something about an extension, but not about the SIP 
peer status.


Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-15 Thread Adolphe Cher-aime

Registry type Event will give you information about your peer.

Adolphe Cher-aime
From my Iphone

On Apr 15, 2011, at 1:15 AM, Jonas Kellens jonas.kell...@telenet.be  
wrote:



On 04/13/2011 09:18 PM, Rob Coward wrote:


Rather than add extra overhead to your dialplan and the asterisk  
server, why not make use of the AMI and have a background process  
listening for the various events and updating your database  
accordingly ?


See http://www.voip-info.org/wiki/view/asterisk+manager+events#ExtensionStatusEvent 
 and http://search.cpan.org/~greenbean/Asterisk-AMI-v0.2.5/lib/Asterisk/AMI.pm#Events


Regards,

Rob



Hello,

this event tells me something about an extension, but not about the  
SIP peer status.


Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
 http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-15 Thread Jonas Kellens

On 04/15/2011 11:53 AM, Adolphe Cher-aime wrote:

Registry type Event will give you information about your peer.

Adolphe Cher-aime
From my Iphone


I don't find information on how this event tells me whether the SIP peer 
is occupied with a call or not.


How can I capture the notify messages (as in BLF) ??


Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Jonas Kellens

On 04/13/2011 11:20 AM, Ishfaq Malik wrote:

On Wed, 2011-04-13 at 11:09 +0200, Jonas Kellens wrote:
   

On 04/13/2011 10:57 AM, Ishfaq Malik wrote:
 

On Wed, 2011-04-13 at 10:15 +0200, Jonas Kellens wrote:

   

Hello,

I'm using SIP realtime with MySQL DB.

Is it possible to get the status of the SIP peer (free / calling) from
this realtime DB ?

If not, is there another way to obtain the call state of a SIP peer ?

 

You could use core show channels in the console/via AMI to determine if
any extensions are on a call or even making a call.


   

If this information is not available, then I'm thinking of writing an
AGI and calling this AGI when a call is being answered. This AGI will
then write to the MySQL-DB the state busy for this SIP peer.
Off course when the call ends, I need another AGi in the h-exten which
writes the state free for this SIP peer.

You think this will work ? Or will it put too much load on my system ?


Kind regards,
Jonas.

 

You could write a shell script to do what you suggested and pop it on a
cron. The info wouldn't be 100% realtime that way though but I think the
load would be very low.

Also, as someone else has suggested, you could use hints but you have to
add some of the code for hints directly into the extensions.conf which
sort of goes against the point of RealTime unless you use scripts to
handle that part as I myself have done.
   


Why should I use a cron ? I can just use an AGI in extensions.conf. 
That's the closest to realtime I think.


How can I write information to a MySQL-DB using hints ? Please explain.


Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Andrew Thomas
Maybe I should have asked 'why do you want to put the status in to a
mySQL database'?

BTW - extensions.conf has mySQL functions built in - so no external
script is actually needed.




-Original Message-
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Jonas
Kellens
Sent: 13 April 2011 10:25
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Realtime SIP  peer status


On 04/13/2011 11:20 AM, Ishfaq Malik wrote:
 On Wed, 2011-04-13 at 11:09 +0200, Jonas Kellens wrote:

 On 04/13/2011 10:57 AM, Ishfaq Malik wrote:
  
 On Wed, 2011-04-13 at 10:15 +0200, Jonas Kellens wrote:


 Hello,

 I'm using SIP realtime with MySQL DB.

 Is it possible to get the status of the SIP peer (free / calling) 
 from this realtime DB ?

 If not, is there another way to obtain the call state of a SIP peer

 ?

  
 You could use core show channels in the console/via AMI to determine

 if any extensions are on a call or even making a call.



 If this information is not available, then I'm thinking of writing an

 AGI and calling this AGI when a call is being answered. This AGI will

 then write to the MySQL-DB the state busy for this SIP peer. Off 
 course when the call ends, I need another AGi in the h-exten which 
 writes the state free for this SIP peer.

 You think this will work ? Or will it put too much load on my system 
 ?


 Kind regards,
 Jonas.

  
 You could write a shell script to do what you suggested and pop it on 
 a cron. The info wouldn't be 100% realtime that way though but I think

 the load would be very low.

 Also, as someone else has suggested, you could use hints but you have 
 to add some of the code for hints directly into the extensions.conf 
 which sort of goes against the point of RealTime unless you use 
 scripts to handle that part as I myself have done.


Why should I use a cron ? I can just use an AGI in extensions.conf. 
That's the closest to realtime I think.

How can I write information to a MySQL-DB using hints ? Please explain.


Kind regards,
Jonas.

-- _
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


 If you have received this communication in error we would appreciate
you advising us either by telephone or return of e-mail. The contents
of this message, and any attachments, are the property of DataVox,
and are intended for the confidential use of the named recipient only.
If you are not the intended recipient, employee or agent responsible
for delivery of this message to the intended recipient, take note that
any dissemination, distribution or copying of this communication and
its attachments is strictly prohibited, and may be subject to civil or
criminal action for which you may be liable.
Every effort has been made to ensure that this e-mail or any attachments
are free from viruses. While the company has taken every reasonable
precaution to minimise this risk, neither company, nor the sender can
accept liability for any damage which you sustain as a result of viruses.
It is recommended that you should carry out your own virus checks
before opening any attachments. 

Registered in England. No. 27459085.



--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Ishfaq Malik
On Wed, 2011-04-13 at 10:28 +0100, Andrew Thomas wrote:
 BTW - extensions.conf has mySQL functions built in - so no external
 script is actually needed.
 
   
Could you point me in the right direction for that?

-- 
Ishfaq Malik
Software Developer
PackNet Ltd

Office:   0161 660 3062


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Jonas Kellens

On 04/13/2011 11:28 AM, Andrew Thomas wrote:

Maybe I should have asked 'why do you want to put the status in to a
mySQL database'?

BTW - extensions.conf has mySQL functions built in - so no external
script is actually needed.


Well, I read out this information in a website which serves as a 
comprehensible GUI.


I know I can use mysql-functions in the dialplan, but when I need to 
write something on answering, then I need the AGI-option of the 
Dial()-command.



Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Ishfaq Malik
On Wed, 2011-04-13 at 11:24 +0200, Jonas Kellens wrote:
 On 04/13/2011 11:20 AM, Ishfaq Malik wrote:
  On Wed, 2011-04-13 at 11:09 +0200, Jonas Kellens wrote:
 
  On 04/13/2011 10:57 AM, Ishfaq Malik wrote:
   
  On Wed, 2011-04-13 at 10:15 +0200, Jonas Kellens wrote:
 
 
  Hello,
 
  I'm using SIP realtime with MySQL DB.
 
  Is it possible to get the status of the SIP peer (free / calling) from
  this realtime DB ?
 
  If not, is there another way to obtain the call state of a SIP peer ?
 
   
  You could use core show channels in the console/via AMI to determine if
  any extensions are on a call or even making a call.
 
 
 
  If this information is not available, then I'm thinking of writing an
  AGI and calling this AGI when a call is being answered. This AGI will
  then write to the MySQL-DB the state busy for this SIP peer.
  Off course when the call ends, I need another AGi in the h-exten which
  writes the state free for this SIP peer.
 
  You think this will work ? Or will it put too much load on my system ?
 
 
  Kind regards,
  Jonas.
 
   
  You could write a shell script to do what you suggested and pop it on a
  cron. The info wouldn't be 100% realtime that way though but I think the
  load would be very low.
 
  Also, as someone else has suggested, you could use hints but you have to
  add some of the code for hints directly into the extensions.conf which
  sort of goes against the point of RealTime unless you use scripts to
  handle that part as I myself have done.
 
 
 Why should I use a cron ? I can just use an AGI in extensions.conf. 
 That's the closest to realtime I think.
 
 How can I write information to a MySQL-DB using hints ? Please explain.
 
 
 Kind regards,
 Jonas.
 
 --
TBH I hadn't though as far as how to write it to a DB, was just thinking
on ways of extension state reporting...
-- 
Ishfaq Malik
Software Developer
PackNet Ltd

Office:   0161 660 3062


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Ishfaq Malik
On Wed, 2011-04-13 at 10:32 +0100, Ishfaq Malik wrote:
 On Wed, 2011-04-13 at 10:28 +0100, Andrew Thomas wrote:
  BTW - extensions.conf has mySQL functions built in - so no external
  script is actually needed.
  
  
 Could you point me in the right direction for that?
 
Ignore that, I just realised what you meant...
-- 
Ishfaq Malik
Software Developer
PackNet Ltd

Office:   0161 660 3062


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Andrew Thomas

http://www.voip-info.org/wiki/view/Asterisk+cmd+MYSQL

And yes, I meant Asterisk has mySQL commands built in [that can be
accessed via. extensions.conf].  Sorry if I mislead.



-Original Message-
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Ishfaq
Malik
Sent: 13 April 2011 10:33
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Realtime SIP  peer status


On Wed, 2011-04-13 at 10:28 +0100, Andrew Thomas wrote:
 BTW - extensions.conf has mySQL functions built in - so no external 
 script is actually needed.
 
   
Could you point me in the right direction for that?

-- 
Ishfaq Malik
Software Developer
PackNet Ltd

Office:   0161 660 3062


-- _
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


 If you have received this communication in error we would appreciate
you advising us either by telephone or return of e-mail. The contents
of this message, and any attachments, are the property of DataVox,
and are intended for the confidential use of the named recipient only.
If you are not the intended recipient, employee or agent responsible
for delivery of this message to the intended recipient, take note that
any dissemination, distribution or copying of this communication and
its attachments is strictly prohibited, and may be subject to civil or
criminal action for which you may be liable.
Every effort has been made to ensure that this e-mail or any attachments
are free from viruses. While the company has taken every reasonable
precaution to minimise this risk, neither company, nor the sender can
accept liability for any damage which you sustain as a result of viruses.
It is recommended that you should carry out your own virus checks
before opening any attachments. 

Registered in England. No. 27459085.



--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Andrew Thomas
Fair enough.  Then if this is really what you want I guess an AGI is the
best way to go.

As for load - well, that depends on how many concurrent connections you
figure on having [and of course the platform it's all on].




-Original Message-
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Jonas
Kellens
Sent: 13 April 2011 10:39
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Realtime SIP  peer status


On 04/13/2011 11:28 AM, Andrew Thomas wrote:
 Maybe I should have asked 'why do you want to put the status in to a 
 mySQL database'?

 BTW - extensions.conf has mySQL functions built in - so no external 
 script is actually needed.

Well, I read out this information in a website which serves as a 
comprehensible GUI.

I know I can use mysql-functions in the dialplan, but when I need to 
write something on answering, then I need the AGI-option of the 
Dial()-command.


Kind regards,
Jonas.

-- _
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


 If you have received this communication in error we would appreciate
you advising us either by telephone or return of e-mail. The contents
of this message, and any attachments, are the property of DataVox,
and are intended for the confidential use of the named recipient only.
If you are not the intended recipient, employee or agent responsible
for delivery of this message to the intended recipient, take note that
any dissemination, distribution or copying of this communication and
its attachments is strictly prohibited, and may be subject to civil or
criminal action for which you may be liable.
Every effort has been made to ensure that this e-mail or any attachments
are free from viruses. While the company has taken every reasonable
precaution to minimise this risk, neither company, nor the sender can
accept liability for any damage which you sustain as a result of viruses.
It is recommended that you should carry out your own virus checks
before opening any attachments. 

Registered in England. No. 27459085.



--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Jonas Kellens

On 04/13/2011 11:46 AM, Andrew Thomas wrote:

Fair enough.  Then if this is really what you want I guess an AGI is the
best way to go.

As for load - well, that depends on how many concurrent connections you
figure on having [and of course the platform it's all on].

Platform : CentOS 5.5
Asterisk : 1.6.2.16.1
Concurrent connections : 25
RAM : 512MB
CPU : 2GHz


Kind regards,
Jonas.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Steve Edwards

On Wed, 13 Apr 2011, Andrew Thomas wrote:


Fair enough.  Then if this is really what you want I guess an AGI is the
best way to go.

As for load - well, that depends on how many concurrent connections you
figure on having [and of course the platform it's all on].


I do almost exactly the same for PRIs with AGIs written in C. Each call 
may execute dozens of AGIs over a 10 minute or so call. 5 AGIs get 
executed before the caller hears the first prompt and it is almost 
instantaneous.


This is on a 6 year old Xeon (3.40GHz) server handling about 100 
concurrent calls.


You can execute XXX AGIs written in C in the time it takes to load the 
interpreter (Perl or PHP) for your script.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peer status

2011-04-13 Thread Rob Coward
  

Rather than add extra overhead to your dialplan and the asterisk
server, why not make use of the AMI and have a background process
listening for the various events and updating your database accordingly
? 

See
http://www.voip-info.org/wiki/view/asterisk+manager+events#ExtensionStatusEvent
and
http://search.cpan.org/~greenbean/Asterisk-AMI-v0.2.5/lib/Asterisk/AMI.pm#Events


Regards, 

Rob 

On Wed, 13 Apr 2011 10:15:30 +0200, Jonas Kellens
wrote: 

 Hello,
 
 I'm using SIP realtime with MySQL DB.
 
 Is it
possible to get the status of the SIP peer (free / calling) from this
realtime DB ?
 
 If not, is there another way to obtain the call state
of a SIP peer ?
 
 Kind regards,
 Jonas.
 --
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-05 Thread Bryan Field-Elliot

On Jan 4, 2011, at 12:26 PM, Tilghman Lesher wrote:

It wasn't designed to do this.  While you can have the same sippeers table
for multiple servers, you really should have a separate sipregs table for
each backend server.  The reason why is that some mappings depend
implicitly on the host to which it was registered.  For example, if a phone
is behind a NAT, then the external port is dependent upon the same host
responding.  If a different host tries to communicate to that external port,
some NAT devices will not route the packet properly.  This is especially
true for SIP over TCP, but it's also true for UDP packets.  (Routing
packets back through a NAT without verifying the sending IP is a security
risk.)
Probably more appropriate for your case is to use DUNDi to coordinate your
machines as to which server presents holds the registration for any
specific phone.

We have one table which is serving both purposes (peers and reg). When we want 
to route a call to an ATA, we first look up that ATA's regserver in that table, 
and then construct a SIP URI based upon that regserver address. In that way, we 
route the call through the server to which the ATA is currently registered. So 
I guess we're covered already in the scenario you describe. It seems like not a 
great design to have to have a private sipregs table for every server in our 
pool, especially given that the pool will grow (or maybe shrink) over time. Is 
that really the recommended design? I haven't seen any articles describing that 
setup for RealTime in a multi-server environment.

Thank you,

Bryan



--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-05 Thread Kevin P. Fleming

On 01/05/2011 09:39 AM, Bryan Field-Elliot wrote:


We have one table which is serving both purposes (peers and reg). When
we want to route a call to an ATA, we first look up that ATA's regserver
in that table, and then construct a SIP URI based upon that regserver
address. In that way, we route the call through the server to which the
ATA is currently registered. So I guess we're covered already in the
scenario you describe. It seems like not a great design to have to have
a private sipregs table for every server in our pool, especially given
that the pool will grow (or maybe shrink) over time. Is that really the
recommended design? I haven't seen any articles describing that setup
for RealTime in a multi-server environment.


Asterisk Realtime was designed to make dynamic configuration possible, 
and then later extended to provide a way to store *some* data outside of 
astdb. It was never intended to provide a failover or data-sharing 
mechanism, and none of the code attempts to take that into account.


--
Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
skype: kpfleming | jabber: kflem...@digium.com
Check us out at www.digium.com  www.asterisk.org

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-05 Thread Tilghman Lesher
On Wednesday 05 January 2011 09:39:00 Bryan Field-Elliot wrote:
 On Jan 4, 2011, at 12:26 PM, Tilghman Lesher wrote:
 
  It wasn't designed to do this.  While you can have the same sippeers
  table for multiple servers, you really should have a separate sipregs
  table for each backend server.  The reason why is that some mappings
  depend implicitly on the host to which it was registered.  For example,
  if a phone is behind a NAT, then the external port is dependent upon
  the same host responding.  If a different host tries to communicate to
  that external port, some NAT devices will not route the packet
  properly.  This is especially true for SIP over TCP, but it's also true
  for UDP packets.  (Routing packets back through a NAT without verifying
  the sending IP is a security risk.)
 
  Probably more appropriate for your case is to use DUNDi to coordinate
  your machines as to which server presents holds the registration for
  any specific phone.

 We have one table which is serving both purposes (peers and reg). When
 we want to route a call to an ATA, we first look up that ATA's
 regserver in that table, and then construct a SIP URI based upon that
 regserver address. In that way, we route the call through the server to
 which the ATA is currently registered. So I guess we're covered already
 in the scenario you describe. It seems like not a great design to have
 to have a private sipregs table for every server in our pool,
 especially given that the pool will grow (or maybe shrink) over time.
 Is that really the recommended design? I haven't seen any articles
 describing that setup for RealTime in a multi-server environment.

Sorry, but a private table for sipregs for each server was exactly what it
designed for, in order to separate out values which change per-server from
general configuration (same for every server).  While I understand that
you're presently using a separate lookup into that table, DUNDi is the
(scalable!) protocol meant to perform this task for you.  Clearly, using a
shared sipregs table has its own set of problems; rather than sticking to
your flawed configuration, I would think that you would jump at the chance
to fix it.

-- 
Tilghman

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-04 Thread Olle E. Johansson

3 jan 2011 kl. 00.26 skrev Bryan Field-Elliot:

 
 Normally, no matter which Asterisk server an ATA connects to, we get our 
 database fields filled out correctly, such as regseconds, lastms, 
 ipadr, etc. However, with some ATA's we are experiencing a problem as 
 follows:
 
 1. ATA reaches its re-registration timeout, which we typically configure to 
 be 60 minutes.
 2. ATA re-queries DNS SRV record, and ends up re-registering with a different 
 AX server than it was on previously.
 3. The new AX server updates the Realtime DB fields (regseconds, lastms, etc).
 4. The old AX server, after a few more minutes, notices that the ATA has 
 vanished, and therefore clears out these same fields.

Oh, that's an interesting observation. Depending on how you see it, it's a bug 
or a feature request.

Code-wise what you could do is that Asterisk could retrieve the information 
from realtime. If the sysname is not the same as the systems, it let the 
information be. If it's the same sysname, then erase the information.

/O
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-04 Thread Bryan Field-Elliot
Thanks Olle.  Do you suppose I am the first Asterisk user to discover this 
behavior? I would find that hard to believe that I'm the first person to 
notice...

Your idea for how to deal with sounds reasonable..

Thank you,

Bryan


On Jan 4, 2011, at 12:18 AM, Olle E. Johansson wrote:


3 jan 2011 kl. 00.26 skrev Bryan Field-Elliot:

 
 Normally, no matter which Asterisk server an ATA connects to, we get our 
 database fields filled out correctly, such as regseconds, lastms, 
 ipadr, etc. However, with some ATA's we are experiencing a problem as 
 follows:
 
 1. ATA reaches its re-registration timeout, which we typically configure to 
 be 60 minutes.
 2. ATA re-queries DNS SRV record, and ends up re-registering with a different 
 AX server than it was on previously.
 3. The new AX server updates the Realtime DB fields (regseconds, lastms, etc).
 4. The old AX server, after a few more minutes, notices that the ATA has 
 vanished, and therefore clears out these same fields.

Oh, that's an interesting observation. Depending on how you see it, it's a bug 
or a feature request.

Code-wise what you could do is that Asterisk could retrieve the information 
from realtime. If the sysname is not the same as the systems, it let the 
information be. If it's the same sysname, then erase the information.

/O
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP, multiple AX servers question

2011-01-04 Thread Tilghman Lesher
On Tuesday 04 January 2011 09:40:56 Bryan Field-Elliot wrote:
 Thanks Olle.  Do you suppose I am the first Asterisk user to discover
 this behavior? I would find that hard to believe that I'm the first
 person to notice...

It wasn't designed to do this.  While you can have the same sippeers table
for multiple servers, you really should have a separate sipregs table for
each backend server.  The reason why is that some mappings depend
implicitly on the host to which it was registered.  For example, if a phone
is behind a NAT, then the external port is dependent upon the same host
responding.  If a different host tries to communicate to that external port,
some NAT devices will not route the packet properly.  This is especially
true for SIP over TCP, but it's also true for UDP packets.  (Routing
packets back through a NAT without verifying the sending IP is a security
risk.)

Probably more appropriate for your case is to use DUNDi to coordinate your
machines as to which server presents holds the registration for any
specific phone.

-- 
Tilghman

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP, multiple AX servers question

2011-01-02 Thread Bryan Field-Elliot
We have several Asterisk servers (1.6.2.15) all configured for Realtime, all 
backed by the same database. The Asterisk servers are all listed under DNS SRV 
records, and SIP ATAs find us this way.

Normally, no matter which Asterisk server an ATA connects to, we get our 
database fields filled out correctly, such as regseconds, lastms, ipadr, 
etc. However, with some ATA's we are experiencing a problem as follows:

1. ATA reaches its re-registration timeout, which we typically configure to 
be 60 minutes.
2. ATA re-queries DNS SRV record, and ends up re-registering with a different 
AX server than it was on previously.
3. The new AX server updates the Realtime DB fields (regseconds, lastms, etc).
4. The old AX server, after a few more minutes, notices that the ATA has 
vanished, and therefore clears out these same fields.

Is there any way to fix this problem? We need to know if ATA's go offline, but, 
we don't want them caught in this endless loop where our multiple AX servers 
are out-guessing eachother and overwriting valid data in the database.

Our realtime options in sip.conf are as follows:

rtcachefriends=yes
rtsavesysname=yes
;rtautoclear=yes
;ignoreregexpire=yes

Because we are using rtsavesysname, a perfect solution seems like it might be 
along the lines of If an ATA disappears, empty out the RT database fields ONLY 
if it's last regserver was this one. Is this possible?


Thank you,

Bryan


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-19 Thread Jonas Kellens

Converting with sox works well as followed :

sox -V intro.wav -c 1 -r 8000 intro2.wav

To convert with asterisk convert, I needed to use an absolute path :

asterisk -rx file convert /var/lib/asterisk/moh/folder/intro.wav 
/var/lib/asterisk/folder/intro.alaw



All works well.


Jonas.

On 08/19/2010 02:31 AM, Nasir Iqbal wrote:

Hi

to convert wav file use following

sox 'orgFile' -w -r 8000 -c 1 -s  'fixedFile'

while replace orgFile and fixedFile with actual filenames


If still now luck try with mp3

Regards
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-18 Thread Nasir Iqbal
Hi

to convert wav file use following

sox 'orgFile' -w -r 8000 -c 1 -s  'fixedFile'

while replace orgFile and fixedFile with actual filenames


If still now luck try with mp3

Regards
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-17 Thread Jonas Kellens
Can anyone help because I don't understand why Asterisk can not read the 
input file, there is not much info given...


2 files :

[r...@asterisk testing]# file testExtended.wav
testExtended.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 
16 bit, stereo 44100 Hz

[r...@asterisk testing]# file testLong.wav
testLong.wav: RIFF (little-endian) data, WAVE audio, 20294 channels 
1414676809 Hz


to mono :

[r...@asterisk testing]# sox testExtended.wav -r 8000 -c1 
testExtended2.wav resample -ql

sox sox: effect `resample' is deprecated; see sox(1) for an alternative
[r...@asterisk testing]# sox testLong.wav -r 8000 -c1 testLong2.wav 
resample -ql

sox sox: effect `resample' is deprecated; see sox(1) for an alternative
sox effects: resample clipped 2 samples; decrease volume?

afterwards :

[r...@asterisk testing]# file testLong2.wav
testLong2.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 
bit, mono 8000 Hz

[r...@asterisk testing]# file testExtended2.wav
testExtended2.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 
16 bit, mono 8000 Hz


But Asterisk can not open them :

[r...@asterisk testing]# asterisk -rx file convert testExtended2.wav 
testExtended2.alaw

Unable to open input file: testExtended2.wav
[r...@asterisk testing]# asterisk -rx file convert testLong2.wav 
testLong2.alaw

Unable to open input file: testLong2.wav


Any thoughts ?!


Jonas.




On 08/14/2010 04:30 PM, Motiejus Jakštys wrote:
On Sat, Aug 14, 2010 at 4:24 PM, Jonas Kellens 
jonas.kell...@telenet.be mailto:jonas.kell...@telenet.be wrote:


 intro extended version.wav: RIFF (little-endian) data, WAVE audio, 
Microsoft

 PCM, 16 bit, stereo 44100 Hz


You need *MONO, 8000Hz*

$ man sox

--
Motiejus Jakštys
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-17 Thread Tiago Geada
Hi.

Just to let you know, we record voices with audacity, and export audio as
flac, just in case we need to edit it.

Then I have the following sh script:

o# cat convert.sh
#!/bin/sh

today=$(date +%F);

mkdir -p $today/flac;
mkdir -p $today/wav;
mkdir -p $today/ul;

for i in *.flac;
do
echo 
echo Processing $i;
echo 
#$filename=
sox $i -r 8000 -c 1 $(echo $i|rev|cut -d . -f2-10|rev).wav;
normalize-audio -a 25dB $(echo $i|rev|cut -d . -f2-10|rev).wav;
mv $i $today/flac/;
sox $(echo $i|cut -d . -f1).wav $(echo $i|rev|cut -d .
-f2-10|rev).ul;
mv $(echo $i|rev|cut -d . -f2-10|rev).wav $today/wav/;
mv $(echo $i|rev|cut -d . -f2-10|rev).ul $today/ul/;
echo ;
done

echo All done;


On 17 August 2010 08:07, Jonas Kellens jonas.kell...@telenet.be wrote:

  Can anyone help because I don't understand why Asterisk can not read the
 input file, there is not much info given...

 2 files :

 [r...@asterisk testing]# file testExtended.wav
 testExtended.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16
 bit, stereo 44100 Hz
 [r...@asterisk testing]# file testLong.wav
 testLong.wav: RIFF (little-endian) data, WAVE audio, 20294 channels
 1414676809 Hz

 to mono :

 [r...@asterisk testing]# sox testExtended.wav -r 8000 -c1
 testExtended2.wav resample -ql

 sox sox: effect `resample' is deprecated; see sox(1) for an alternative
 [r...@asterisk testing]# sox testLong.wav -r 8000 -c1 testLong2.wav
 resample -ql

 sox sox: effect `resample' is deprecated; see sox(1) for an alternative
 sox effects: resample clipped 2 samples; decrease volume?

 afterwards :

 [r...@asterisk testing]# file testLong2.wav
 testLong2.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16
 bit, mono 8000 Hz
 [r...@asterisk testing]# file testExtended2.wav
 testExtended2.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16
 bit, mono 8000 Hz

 But Asterisk can not open them :

 [r...@asterisk testing]# asterisk -rx file convert testExtended2.wav
 testExtended2.alaw
 Unable to open input file: testExtended2.wav
 [r...@asterisk testing]# asterisk -rx file convert testLong2.wav
 testLong2.alaw
 Unable to open input file: testLong2.wav


 Any thoughts ?!


 Jonas.



 On 08/14/2010 04:30 PM, Motiejus Jakštys wrote:

 On Sat, Aug 14, 2010 at 4:24 PM, Jonas Kellens jonas.kell...@telenet.be
 wrote:
 
  intro extended version.wav: RIFF (little-endian) data, WAVE audio,
 Microsoft
  PCM, 16 bit, stereo 44100 Hz
 

 You need *MONO, 8000Hz*

 $ man sox

 --
 Motiejus Jakštys


 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-15 Thread Jonas Kellens

I took this from the wiki, but it's not working :

[r...@asterisk testing]# sox test.wav -r 8000 -c1 test.alaw resample -ql
sox sox: effect `resample' is deprecated; see sox(1) for an alternative
sox formats: no handler for file extension `alaw'



Jonas.

On 08/14/2010 04:30 PM, Motiejus Jakštys wrote:
On Sat, Aug 14, 2010 at 4:24 PM, Jonas Kellens 
jonas.kell...@telenet.be mailto:jonas.kell...@telenet.be wrote:


 intro extended version.wav: RIFF (little-endian) data, WAVE audio, 
Microsoft

 PCM, 16 bit, stereo 44100 Hz


You need *MONO, 8000Hz*

$ man sox

--
Motiejus Jakštys
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-15 Thread Jonas Kellens

And even when I think the format is correct :

[r...@asterisk testing]# sox test.wav -r 8000 -c1 test.wav resample -ql
sox sox: effect `resample' is deprecated; see sox(1) for an alternative
sox wav: Premature EOF on .wav input file

[r...@asterisk testing]# file test.wav
test.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, 
mono 8000 Hz



It is still not working :

[r...@asterisk testing]# asterisk -rx file convert test.wav test.alaw
Unable to open input file: test.wav



Jonas.

On 08/14/2010 04:30 PM, Motiejus Jakštys wrote:
On Sat, Aug 14, 2010 at 4:24 PM, Jonas Kellens 
jonas.kell...@telenet.be mailto:jonas.kell...@telenet.be wrote:


 intro extended version.wav: RIFF (little-endian) data, WAVE audio, 
Microsoft

 PCM, 16 bit, stereo 44100 Hz


You need *MONO, 8000Hz*

$ man sox

--
Motiejus Jakštys
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-14 Thread Jonas Kellens

I have another file that reads :

[r...@asterisk ]# file intro\ extended\ version.wav
intro extended version.wav: RIFF (little-endian) data, WAVE audio, 
Microsoft PCM, 16 bit, stereo 44100 Hz


With the same result :

[r...@asterisk ]# asterisk -rx file convert 
/var/lib/asterisk/moh/test/intro\ extended\ version.wav 
/var/lib/asterisk/moh/test/testing.alaw
Unable to open input file: /var/lib/asterisk/moh/test/intro extended 
version.wav



Jonas.


On 08/13/2010 01:49 PM, Gareth Blades wrote:

The wav file is not in the correct format. Also the number of channels
and sampling frequency it is reporting is complete nonsense. This is
what it should display:-
RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, mono 8000 Hz
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-14 Thread Motiejus Jakštys
On Sat, Aug 14, 2010 at 4:24 PM, Jonas Kellens jonas.kell...@telenet.be
wrote:

 intro extended version.wav: RIFF (little-endian) data, WAVE audio,
Microsoft
 PCM, 16 bit, stereo 44100 Hz


You need *MONO, 8000Hz*

$ man sox

--
Motiejus Jakštys
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] realtime sip peers : musiconhold class

2010-08-13 Thread Jonas Kellens

Hello list,


I'm using asterisk 1.4.30 and realtime sip.


I notice that the field musiconhold is not working as when putting 
someone on hold, the default musiconhold class is always used.



musiconhold.conf :

[default]
mode=files
directory=/var/lib/asterisk/moh
random=yes
;
[106002]
mode=files
directory=/var/lib/asterisk/moh/106002
random=yes


my realtime sip peers have the following in the column '*musiconhold*' : 
*106002*



asterisk*CLI moh show classes
Class: default
Mode: files
Directory: /var/lib/asterisk/moh
Class: 106002
Mode: files
Directory: /var/lib/asterisk/moh/106002


But always :

[Aug 13 09:47:57] -- Started music on hold, class 'default', on 
SIP/test2-0014

[Aug 13 09:48:05] -- Stopped music on hold on SIP/test2-0014



Can anyone help ?!


Kind regards,

Jonas.

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-13 Thread Jonas Kellens

Hello list,

when putting the class 'default' in comment, then this happens :

[Aug 13 12:36:34] WARNING[21172]: res_musiconhold.c:666 get_mohbyname: 
Music on Hold class 'default' not found
[Aug 13 12:36:34] -- Started music on hold, class '106002', on 
SIP/test2-0001
[Aug 13 12:36:34] WARNING[21172]: format_wav.c:124 check_header: Does 
not say fmt
[Aug 13 12:36:34] WARNING[21172]: file.c:385 fn_wrapper: Unable to open 
format wav
[Aug 13 12:36:34] WARNING[21172]: res_musiconhold.c:251 
ast_moh_files_next: Unable to open file 
'/var/lib/asterisk/moh/106002/01Long': No such file or directory


Questions :

1. how can I use AND class default AND class 106002 ?!
2. is it normal that Asterisk can not convert from wav to alaw/gsm ?!


Jonas.


On 08/13/2010 09:57 AM, Jonas Kellens wrote:

Hello list,


I'm using asterisk 1.4.30 and realtime sip.


I notice that the field musiconhold is not working as when putting 
someone on hold, the default musiconhold class is always used.



musiconhold.conf :

[default]
mode=files
directory=/var/lib/asterisk/moh
random=yes
;
[106002]
mode=files
directory=/var/lib/asterisk/moh/106002
random=yes


my realtime sip peers have the following in the column '*musiconhold*' 
: *106002*



asterisk*CLI moh show classes
Class: default
Mode: files
Directory: /var/lib/asterisk/moh
Class: 106002
Mode: files
Directory: /var/lib/asterisk/moh/106002


But always :

[Aug 13 09:47:57] -- Started music on hold, class 'default', on 
SIP/test2-0014

[Aug 13 09:48:05] -- Stopped music on hold on SIP/test2-0014



Can anyone help ?!


Kind regards,

Jonas.

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-13 Thread Gareth Blades
Asterisk can convert from wav but it still needs to be in the correct 
format. See 
http://www.voip-info.org/tiki-index.php?page=Convert+WAV+audio+files+for+use+in+Asterisk

Jonas Kellens wrote:
 Hello list,
 
 when putting the class 'default' in comment, then this happens :
 
 [Aug 13 12:36:34] WARNING[21172]: res_musiconhold.c:666 get_mohbyname: 
 Music on Hold class 'default' not found
 [Aug 13 12:36:34] -- Started music on hold, class '106002', on 
 SIP/test2-0001
 [Aug 13 12:36:34] WARNING[21172]: format_wav.c:124 check_header: Does 
 not say fmt
 [Aug 13 12:36:34] WARNING[21172]: file.c:385 fn_wrapper: Unable to open 
 format wav
 [Aug 13 12:36:34] WARNING[21172]: res_musiconhold.c:251 
 ast_moh_files_next: Unable to open file 
 '/var/lib/asterisk/moh/106002/01Long': No such file or directory
 
 Questions :
 
 1. how can I use AND class default AND class 106002 ?!
 2. is it normal that Asterisk can not convert from wav to alaw/gsm ?!
 
 
 Jonas.
 
 
 On 08/13/2010 09:57 AM, Jonas Kellens wrote:
 Hello list,


 I'm using asterisk 1.4.30 and realtime sip.


 I notice that the field musiconhold is not working as when putting 
 someone on hold, the default musiconhold class is always used.


 musiconhold.conf :

 [default]
 mode=files
 directory=/var/lib/asterisk/moh
 random=yes
 ;
 [106002]
 mode=files
 directory=/var/lib/asterisk/moh/106002
 random=yes


 my realtime sip peers have the following in the column '*musiconhold*' 
 : *106002*


 asterisk*CLI moh show classes
 Class: default
 Mode: files
 Directory: /var/lib/asterisk/moh
 Class: 106002
 Mode: files
 Directory: /var/lib/asterisk/moh/106002


 But always :

 [Aug 13 09:47:57] -- Started music on hold, class 'default', on 
 SIP/test2-0014
 [Aug 13 09:48:05] -- Stopped music on hold on SIP/test2-0014



 Can anyone help ?!


 Kind regards,

 Jonas.



-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-13 Thread Jonas Kellens


1. the converting is not working

[r...@asterisk testing]# file 01Long.wav
01Long.wav: RIFF (little-endian) data, WAVE audio, 20294 channels 
1414676809 Hz


[r...@asterisk testing]# asterisk -rx file convert 
/var/lib/asterisk/testing/01Long.wav /var/lib/asterisk/testing/01Long.alaw

Unable to open input file: /var/lib/asterisk/testing/01Long.wav


2. This does not explain why I can't use class default AND class 
whatever.



Jonas.


On 08/13/2010 12:47 PM, Gareth Blades wrote:

Asterisk can convert from wav but it still needs to be in the correct
format. See
http://www.voip-info.org/tiki-index.php?page=Convert+WAV+audio+files+for+use+in+Asterisk
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] realtime sip peers : musiconhold class

2010-08-13 Thread Gareth Blades
The wav file is not in the correct format. Also the number of channels 
and sampling frequency it is reporting is complete nonsense. This is 
what it should display:-
RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, mono 8000 Hz

Jonas Kellens wrote:
 
 1. the converting is not working
 
 [r...@asterisk testing]# file 01Long.wav
 01Long.wav: RIFF (little-endian) data, WAVE audio, 20294 channels 
 1414676809 Hz
 
 [r...@asterisk testing]# asterisk -rx file convert 
 /var/lib/asterisk/testing/01Long.wav /var/lib/asterisk/testing/01Long.alaw
 Unable to open input file: /var/lib/asterisk/testing/01Long.wav
 
 
 2. This does not explain why I can't use class default AND class 
 whatever.
 
 
 Jonas.
 
 
 On 08/13/2010 12:47 PM, Gareth Blades wrote:
 Asterisk can convert from wav but it still needs to be in the correct 
 format. See 
 http://www.voip-info.org/tiki-index.php?page=Convert+WAV+audio+files+for+use+in+Asterisk


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP Register

2009-11-28 Thread Mindaugas Kezys
Use #exec directive to execute external script which retrieves registration
data from DB, and outputs correct registration string as text.

Do not forget to enable #exec in asterisk.conf

You will need to do sip reload each time you change registration settings. 

With reload you will lose all existing registrations and all previously
registered devices will be unreachable till they register again.

Regards,
Mindaugas Kezys
http://www.kolmisoft.com
VoIP Billing and Routing Solutions


-Original Message-
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Philipp Roos
[Inlogia GmbH]
Sent: 2009 m. lapkričio 27 d. 14:11
To: asterisk-users@lists.digium.com
Subject: [asterisk-users] Realtime SIP Register

Hi,

I would like to have my register directives from sip.conf in my mysql
database:
register = user[:secret[:authuse...@host[:port][/extension]

I already have the sip users and the other config in the DB but how to get
the register in there, too?
In an old mail (Mon Oct 3 00:49:15 MST 2005) Olle E. Johansson said the
[general] section can only be static.
Has there anything changed in the last 4 years?

Thanks!
Philipp

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP Register

2009-11-27 Thread Philipp Roos [Inlogia GmbH]
Hi,

I would like to have my register directives from sip.conf in my mysql database:
register = user[:secret[:authuse...@host[:port][/extension]

I already have the sip users and the other config in the DB but how to get the 
register in there, too?
In an old mail (Mon Oct 3 00:49:15 MST 2005) Olle E. Johansson said the 
[general] section can only be static.
Has there anything changed in the last 4 years?

Thanks!
Philipp

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP

2008-08-24 Thread Il Neofita
Probably I did not read well the information
I am concerning, if I am going to use ARA for the SIP
and I have
register = user:secret:[EMAIL PROTECTED]:port/extension

how I should input that line?
If I am going to delete it from the DB I am forced to reload everything or
there is a way to tell asterisk to remove only a particular entry?
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime + SIP + MySQL: md5secret BROKEN

2008-07-29 Thread Torbjörn Abrahamsson
 
 mysql alter table sip_buddies drop md5secret;
 Query OK, 1 row affected (0.00 sec)
 Records: 1  Duplicates: 0  Warnings: 0
 
 Suddenly, authentication works!
 
 The md5secret used was the md5 of 'qwedsa', and the value was correct.
 
 mysql select md5('qwedsa');
 +--+
 | md5('qwedsa')|
 +--+
 | 4d27b7677bd96f7ba00c4bd0541c9588 |
 +--+
 1 row in set (0.00 sec)
 

Walter,

Not sure, but the above might be your problem.

The md5secret is NOT a MD5 sum of the secret, but of the combination
username:realm:secret. So in your case you should add this md5secret:

mysql select md5('walter:asterisk:qwedsa');
+--+
| md5('walter:asterisk:qwedsa')|
+--+
| 577061918968e961153393ef87b43e4b | 
+--+

This would explain why the tests with cleartext secrets work, and not the
ones with the md5secret. Not sure if you tried md5secrets with a static
sip.conf user definition, but the result should be a credential failure in
that case as well.

Best regards,
Torbjörn



___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime + SIP + MySQL: md5secret BROKEN

2008-07-24 Thread Walter Stanish
I'm quite sure there's a bug somewhere in SIP + realtime + MySQL.

To update, since last post we've integrated with our existing users
database  using MySQL views.  Our legacy database uses md5
password hashes, and does not store plaintext.

During testing this morning I could swear it was all working, however
for some reason, after going out to lunch today and coming back (no
config changes at all!) authentication would not succeed no matter
what I tried:
 - toggling rt* settings in sip.conf
 - re-creating MySQL view
 - reverting to static table
 - sip reload on command line
 - recompiling / re-installing asterisk and asterisk-addons
 - probably a bunch more

Most of these I tried multiple times in various combinations.

The issue appears in the debug log like this:

[Jul 24 17:16:43] DEBUG[8732] chan_sip.c: = No match Their Call ID:
[EMAIL PROTECTED] Their Tag  Our tag: as2f38c31a
[Jul 24 17:16:43] DEBUG[8732] chan_sip.c: Allocating new SIP dialog
for [EMAIL PROTECTED] - REGISTER (No RTP)
[Jul 24 17:16:43] DEBUG[8732] chan_sip.c:  Received REGISTER (2) -
Command in SIP REGISTER
[Jul 24 17:16:43] DEBUG[8732] res_config_mysql.c: MySQL RealTime:
Everything is fine.
[Jul 24 17:16:43] DEBUG[8732] res_config_mysql.c: MySQL RealTime:
Retrieve SQL: SELECT * FROM sip_buddies WHERE name = 'walter' AND host
= 'dynamic'
[Jul 24 17:16:43] DEBUG[8732] db.c: Unable to find key 'walter' in
family 'SIP/Registry'

No matter what I tried I could not fix this.

Finally I found out that after dropping md5secret authentication instantly
began to succeed.

mysql select * from sip_buddies;
+++-+-++-+--++---+--++-+-+---+--+--++--+--+-+--+--++--+-+-+-+--+-+++++--+-+-++--+---++--+-+--+
| id | name   | host| nat | type   | accountcode | amaflags |
call-limit | callgroup | callerid | cancallforward | canreinvite |
context | defaultip | dtmfmode | fromuser | fromdomain | insecure |
language | mailbox | md5secret| deny | permit
| mask | musiconhold | pickupgroup | qualify | regexten | restrictcid
| rtptimeout | rtpholdtimeout | secret | setvar | disallow | allow
  | fullcontact | ipaddr | port | regserver | regseconds |
username | defaultuser | subscribecontext |
+++-+-++-+--++---+--++-+-+---+--+--++--+--+-+--+--++--+-+-+-+--+-+++++--+-+-++--+---++--+-+--+
|  1 | walter | dynamic | no  | friend | NULL| NULL |
 NULL | NULL  | NULL | yes| yes | NULL
| NULL  | NULL | NULL | NULL   | NULL | NULL |
NULL| 4d27b7677bd96f7ba00c4bd0541c9588 | NULL | NULL   | NULL |
NULL| NULL| NULL| NULL | NULL| NULL
   | NULL   | qwedsa | NULL   | all  |
g729;ilbc;gsm;ulaw;alaw | ||0 | NULL  |
  0 | walter   | | NULL |
+++-+-++-+--++---+--++-+-+---+--+--++--+--+-+--+--++--+-+-+-+--+-+++++--+-+-++--+---++--+-+--+
1 row in set (0.00 sec)

mysql alter table sip_buddies drop regserver;
Query OK, 1 row affected (0.01 sec)
Records: 1  Duplicates: 0  Warnings: 0

(retry auth - no luck yet)

mysql alter table sip_buddies drop regseconds;
Query OK, 1 row affected (0.00 sec)
Records: 1  Duplicates: 0  Warnings: 0

(retry auth - no luck yet)

mysql alter table sip_buddies drop md5secret;
Query OK, 1 row affected (0.00 sec)
Records: 1  Duplicates: 0  Warnings: 0

Suddenly, authentication works!

The md5secret used was the md5 of 'qwedsa', and the value was correct.

mysql select md5('qwedsa');
+--+
| md5('qwedsa')|
+--+
| 4d27b7677bd96f7ba00c4bd0541c9588 |
+--+
1 row in set 

Re: [asterisk-users] Realtime + SIP + MySQL: md5secret BROKEN

2008-07-24 Thread Grey Man
On Thu, Jul 24, 2008 at 11:04 AM, Walter Stanish
[EMAIL PROTECTED] wrote:
 If someone could sort out this bug (or let me know if I'm missing
 something 'obvious' - a hard call with realtime documentation this
 sparse...) I'd be most grateful, since we require md5secret support
 to integrate with our existing users database.


Welcome to Asterisk!

It's highly unlikely you'll find anyone to find the bug for you unless
someone is experiencing the same thing. There's no guarantee the bug
is actually with Asterisk it could be with your database or somewhere
in between. That's not to say it's not with Asterisk but there are a
lot of people using realtime with MySQL so if it was a galring bug it
would have been seen and logged already.

If you do manage to track down the bug it will generally at lest get a
response in a short amount of time once it's on the bug tracker.

Regards,

Greyman.

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime + SIP + MySQL: md5secret BROKEN

2008-07-24 Thread Walter Stanish
 If someone could sort out this bug (or let me know if I'm missing
 something 'obvious' - a hard call with realtime documentation this
 sparse...) I'd be most grateful, since we require md5secret support
 to integrate with our existing users database.

 Welcome to Asterisk!

 It's highly unlikely you'll find anyone to find the bug for you unless
 someone is experiencing the same thing.

A quick google search for the issue reveals a number people have run
in to something similar before, some report 'after upgrade', others seem
to be just trying to get realtime working for the first time.

http://www.google.com/search?q=db.c+unable+to+find+key+asterisk

 There's no guarantee the bug is actually with Asterisk it could be
 with your database or somewhere in between.

This seems unlikely for the following reasons.

 1. I can trigger the same SQL queries via the console via realtime
load sippeers username walter and they return data fine.

 2. I have tried upgrading asterisk to root SQL access, with no
 difference in asterisk's behaviour.

 3. The bug is reliably controlled by the presence of the single
 column 'md5secret'

 That's not to say it's not with Asterisk but there are a
 lot of people using realtime with MySQL so if it was a galring bug it
 would have been seen and logged already.

Could I see a show of hands for who's using asterisk realtime with
mysel and md5secret?  If you could post your asterisk /
asterisk-addons / mysql versions too that'd be great.  I don't mind
changing all three of these if someone's found a stable combination.

 If you do manage to track down the bug it will generally at lest get a
 response in a short amount of time once it's on the bug tracker.

I'm happy to post the current material to the bug tracker if it's
considered enough information for a report.

Regards,
Walter Stanish
Owner / Director
Occident Systems
(+86 15808 700 801)

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-14 Thread Olivier
2008/2/13, Atis Lezdins [EMAIL PROTECTED]:

 On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
 
   -BEGIN PGP SIGNED MESSAGE-
   Hash: SHA1
 

   If it is being removed in 1.6, I'm a little concerned since there's no
  mention of this when you show the application, nor on voip-info.org
 .  What
  application/function is it being replaced by?


 There's an obsolete warning in 1.4.18, but i somehow remember that
 it's obsolete already since some 1.4.11

 It's func_realtime as i said before. usage shouldn't be much
 different, you can replace with:

 Set(REALTIME(sip_buddies,name,100,my_field)=foo);

 Also, seems that func_realtime will soon support SQL INSERT's and DELETE's
 :)


Do you mean it should be added between today's beta and future GA 1.6 ?

Regards,

 Atis



 
   Atis Lezdins wrote:
   | On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
   | -BEGIN PGP SIGNED MESSAGE-
   | Hash: SHA1
   |
   | Atis Lezdins wrote:
   | | By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
   | | cache is not implemented in realtime level, but higher (chan_sip).
   | |
   | | Are you sure you need sip show XXX load. If you sip prune peer
   | | data, it should be re-loaded on next access.
   | |
   | | What i was suggesting - to dig into chan_sip and create dialplan
   | | application SipPrune(peer) that would prune the peer directly, by
   | | using corresponding function - sip_prune_peer() in chan_sip.c -
 that
   | | way you will gain some extra performance, as there's no
 manager/cli
   | | overhead.
   | |
   | | However if you're uncomfortable with C, the app_system shouldn't
 cause
   | | any troubles :)
   |
   | RealTimeUpdate is more likely to correspond to app_realtime rather
 than
   | func_realtime.
   |
   | As to my knowledge - that is obsolete and being removed in 1.6,
   | func_realtime replaces it. That's why i wondered about name -  I just
   | never happened to use it :)
   |
   | Regards,
   | Atis
   |
   |
 
   -BEGIN PGP SIGNATURE-
   Version: GnuPG v1.4.7 (GNU/Linux)
   Comment: Using GnuPG with Remi - http://enigmail.mozdev.org
 
  iD8DBQFHsnaM6uKn5cBSgGQRAo/TAKDCruPrn2nm2XV/PYbfSuBKA0j5OwCfQ/Ox
   QE3SYEmZ01QHUT4ITwmLnT0=
   =SKEW
   -END PGP SIGNATURE-
 
 

  ___
  -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
  asterisk-users mailing list
  To UNSUBSCRIBE or update options visit:
 
  http://lists.digium.com/mailman/listinfo/asterisk-users
 


 --
 Atis Lezdins
 VoIP Developer,
 IQ Labs Inc.
 [EMAIL PROTECTED]
 Skype: atis.lezdins
 Cell Phone: +371 28806004
 Work phone: +1 800 7502835

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-13 Thread Rob Hillis
That's why I didn't see anything about the REALTIME function when I went 
looking - many of our production systems are still on later versions of 1.2.


Given that it wasn't made obsolete at the /beginning/ of the 1.4 cycle, 
I'm hoping Digium reconsider making it obsolete in 1.6 and schedule it 
for removal in 1.8.  Half a development cycle isn't a very long time for 
a warning that a function will be removed.


Atis Lezdins wrote:

On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
  

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 If it is being removed in 1.6, I'm a little concerned since there's no
mention of this when you show the application, nor on voip-info.org.  What
application/function is it being replaced by?



There's an obsolete warning in 1.4.18, but i somehow remember that
it's obsolete already since some 1.4.11

It's func_realtime as i said before. usage shouldn't be much
different, you can replace with:

Set(REALTIME(sip_buddies,name,100,my_field)=foo);

Also, seems that func_realtime will soon support SQL INSERT's and DELETE's :)

Regards,
Atis


  

 Atis Lezdins wrote:
 | On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
 | -BEGIN PGP SIGNED MESSAGE-
 | Hash: SHA1
 |
 | Atis Lezdins wrote:
 | | By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
 | | cache is not implemented in realtime level, but higher (chan_sip).
 | |
 | | Are you sure you need sip show XXX load. If you sip prune peer
 | | data, it should be re-loaded on next access.
 | |
 | | What i was suggesting - to dig into chan_sip and create dialplan
 | | application SipPrune(peer) that would prune the peer directly, by
 | | using corresponding function - sip_prune_peer() in chan_sip.c - that
 | | way you will gain some extra performance, as there's no manager/cli
 | | overhead.
 | |
 | | However if you're uncomfortable with C, the app_system shouldn't cause
 | | any troubles :)
 |
 | RealTimeUpdate is more likely to correspond to app_realtime rather than
 | func_realtime.
 |
 | As to my knowledge - that is obsolete and being removed in 1.6,
 | func_realtime replaces it. That's why i wondered about name -  I just
 | never happened to use it :)
 |
 | Regards,
 | Atis
 |
 |

 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.7 (GNU/Linux)
 Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

iD8DBQFHsnaM6uKn5cBSgGQRAo/TAKDCruPrn2nm2XV/PYbfSuBKA0j5OwCfQ/Ox
 QE3SYEmZ01QHUT4ITwmLnT0=
 =SKEW
 -END PGP SIGNATURE-


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:

http://lists.digium.com/mailman/listinfo/asterisk-users





  


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-13 Thread Johansson Olle E

13 feb 2008 kl. 10.27 skrev Rob Hillis:

 That's why I didn't see anything about the REALTIME function when I  
 went looking - many of our production systems are still on later  
 versions of 1.2.

 Given that it wasn't made obsolete at the beginning of the 1.4  
 cycle, I'm hoping Digium reconsider making it obsolete in 1.6 and  
 schedule it for removal in 1.8.  Half a development cycle isn't a  
 very long time for a warning that a function will be removed.

First, it's not Digium - it's the Asterisk developer team. There  
still is a difference, not all of us are employed by Digium. My work  
is mostly funded by myself nowadays, and some by customers that hires  
me as a consultant for various Asterisk projects. I tried to get more  
general funding to spend more time with Asterisk development, but  
failed.

So please rememner that there are a few independent regular Asterisk  
developers out there that is not on the Digium payroll and still take  
part in  decisions about Asterisk.

The way it works is that we decide which functions to deprecate during  
the development cycle. So any decisions was made before the 1.4  
release and stays for the duration of the 1.4 release. We did not  
deprecate anything in 1.4 after the initial release late 2006.

The functionality that was marked as deprecated in 1.4 will be  
removed in 1.6. In fact, it's propably already removed in the  
development code that is the base for the future 1.6.

Over a year is a long time for a warning like this, considering that  
1.6 won't be out for a while (we're in beta test cycle) it might even  
be 1.5 year warning. That should be more than enough for most people -  
I hope. Considering that people don't upgrade quickly, it will  
propably be more than that for most users (as you are still on 1.2 :-) )

Just wanted to clarify the process, I have no detailed insight into  
the realtime functions.

/O


---
* Olle E. Johansson - [EMAIL PROTECTED]
* Asterisk Training http://edvina.net/training/




___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-13 Thread Rob Hillis
Johansson Olle E wrote:
 So please rememner that there are a few independent regular Asterisk  
 developers out there that is not on the Digium payroll and still take  
 part in  decisions about Asterisk.
   

Point taken. 

 Over a year is a long time for a warning like this, considering that  
 1.6 won't be out for a while (we're in beta test cycle) it might even  
 be 1.5 year warning. That should be more than enough for most people -  
 I hope. Considering that people don't upgrade quickly, it will  
 propably be more than that for most users (as you are still on 1.2 :-) )
   

You could be right there - though my main concern is that since I'm
developing for /mostly/ 1.2 systems at this stage, I can't use the new
syntax since (as far as I can tell) the ${REALTIME} function isn't
available in 1.2.  If it were, I'd convert my scripts /now/.

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread ast guy
why don't you write an AGI which talks to asterisk manager API 5038 port and
executes the asterisk commands. You execute asterisk command via agi not
using system command

-ag

On Feb 11, 2008 11:24 AM, Rob Hillis [EMAIL PROTECTED] wrote:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Hi guys,

 I've been working on a little dialplan fragment for roaming extensions,
 however the customer wants us to set the MWI indicator for the roaming
 extension that has just logged in.  We're using MySQL realtime, so I've
 figured out that RealTimeUpdate will happily update the realtime
 database with the correct mailbox.  My problem comes when I need to tell
 Asterisk to flush the realtime data for that extension and reload it so
 that the cached data is correct.  Running the commands sip prune
 realtime peer XXX followed by sip show peer XXX load work fine from
 the Asterisk manager interface and correctly update the cached data so
 the MWI indicator works fine.

 What I want to know is if there is any better method of running manager
 API commands from within the dialplan than the horribly ugly
 System(asterisk -rx sip prune realtime peer XXX)  It works, but from
 my point of view, it's a somewhat nasty hack.

 Anyone have any suggestions?

 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.7 (GNU/Linux)
 Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

 iD8DBQFHr+om6uKn5cBSgGQRAn++AJ4sNAHSG3s/FCVYTreBURn7Mt91UACgy26h
 UC8Q+27UbbFsL9OnL/FzcOY=
 =9gf8
 -END PGP SIGNATURE-


 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Rob Hillis
If this is the only real alternative, then in this instance I'll stick
with using the System command.  Writing an AGI to execute two manager
commands in this case is even greater overkill than using the System
command.

I understand that normally anything that calls multiple manager commands
would usually be something complex enough to justify an AGI.  The
exception seems to be when you're dealing with cached realtime data. (is
it just me, or does that sound like a rather odd oxymoron?)


ast guy wrote:
 why don't you write an AGI which talks to asterisk manager API 5038
port and executes the asterisk commands. You execute asterisk command
via agi not using system command

 -ag

 On Feb 11, 2008 11:24 AM, Rob Hillis [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:

 Hi guys,

 I've been working on a little dialplan fragment for roaming extensions,
 however the customer wants us to set the MWI indicator for the roaming
 extension that has just logged in.  We're using MySQL realtime, so I've
 figured out that RealTimeUpdate will happily update the realtime
 database with the correct mailbox.  My problem comes when I need to tell
 Asterisk to flush the realtime data for that extension and reload it so
 that the cached data is correct.  Running the commands sip prune
 realtime peer XXX followed by sip show peer XXX load work fine from
 the Asterisk manager interface and correctly update the cached data so
 the MWI indicator works fine.

 What I want to know is if there is any better method of running manager
 API commands from within the dialplan than the horribly ugly
 System(asterisk -rx sip prune realtime peer XXX)  It works, but from
 my point of view, it's a somewhat nasty hack.

 Anyone have any suggestions?


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



 -

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Rob Hillis

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

If it is being removed in 1.6, I'm a little concerned since there's no 
mention of this when you show the application, nor on voip-info.org.  
What application/function is it being replaced by?


Atis Lezdins wrote:
| On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
| -BEGIN PGP SIGNED MESSAGE-
| Hash: SHA1
|
| Atis Lezdins wrote:
| | By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
| | cache is not implemented in realtime level, but higher (chan_sip).
| |
| | Are you sure you need sip show XXX load. If you sip prune peer
| | data, it should be re-loaded on next access.
| |
| | What i was suggesting - to dig into chan_sip and create dialplan
| | application SipPrune(peer) that would prune the peer directly, by
| | using corresponding function - sip_prune_peer() in chan_sip.c - that
| | way you will gain some extra performance, as there's no manager/cli
| | overhead.
| |
| | However if you're uncomfortable with C, the app_system shouldn't cause
| | any troubles :)
|
| RealTimeUpdate is more likely to correspond to app_realtime rather than
| func_realtime.
|
| As to my knowledge - that is obsolete and being removed in 1.6,
| func_realtime replaces it. That's why i wondered about name -  I just
| never happened to use it :)
|
| Regards,
| Atis
|
|

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

iD8DBQFHsnaM6uKn5cBSgGQRAo/TAKDCruPrn2nm2XV/PYbfSuBKA0j5OwCfQ/Ox
QE3SYEmZ01QHUT4ITwmLnT0=
=SKEW
-END PGP SIGNATURE-

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Atis Lezdins
On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Atis Lezdins wrote:
 | By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
 | cache is not implemented in realtime level, but higher (chan_sip).
 |
 | Are you sure you need sip show XXX load. If you sip prune peer
 | data, it should be re-loaded on next access.
 |
 | What i was suggesting - to dig into chan_sip and create dialplan
 | application SipPrune(peer) that would prune the peer directly, by
 | using corresponding function - sip_prune_peer() in chan_sip.c - that
 | way you will gain some extra performance, as there's no manager/cli
 | overhead.
 |
 | However if you're uncomfortable with C, the app_system shouldn't cause
 | any troubles :)

 RealTimeUpdate is more likely to correspond to app_realtime rather than
 func_realtime.

As to my knowledge - that is obsolete and being removed in 1.6,
func_realtime replaces it. That's why i wondered about name -  I just
never happened to use it :)

Regards,
Atis


-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Rob Hillis
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Atis Lezdins wrote:
| By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
| cache is not implemented in realtime level, but higher (chan_sip).
|
| Are you sure you need sip show XXX load. If you sip prune peer
| data, it should be re-loaded on next access.
|
| What i was suggesting - to dig into chan_sip and create dialplan
| application SipPrune(peer) that would prune the peer directly, by
| using corresponding function - sip_prune_peer() in chan_sip.c - that
| way you will gain some extra performance, as there's no manager/cli
| overhead.
|
| However if you're uncomfortable with C, the app_system shouldn't cause
| any troubles :)

RealTimeUpdate is more likely to correspond to app_realtime rather than 
func_realtime.
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

iD8DBQFHsiYn6uKn5cBSgGQRAnLwAJ0WZzDsceOCgiF8UxDnrkpjk/pE/QCgpP4f
/+QVcV5YBEGehE+dz1qsNTE=
=IQXo
-END PGP SIGNATURE-


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Atis Lezdins
On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:

  -BEGIN PGP SIGNED MESSAGE-
  Hash: SHA1

  If it is being removed in 1.6, I'm a little concerned since there's no
 mention of this when you show the application, nor on voip-info.org.  What
 application/function is it being replaced by?

There's an obsolete warning in 1.4.18, but i somehow remember that
it's obsolete already since some 1.4.11

It's func_realtime as i said before. usage shouldn't be much
different, you can replace with:

Set(REALTIME(sip_buddies,name,100,my_field)=foo);

Also, seems that func_realtime will soon support SQL INSERT's and DELETE's :)

Regards,
Atis



  Atis Lezdins wrote:
  | On 2/13/08, Rob Hillis [EMAIL PROTECTED] wrote:
  | -BEGIN PGP SIGNED MESSAGE-
  | Hash: SHA1
  |
  | Atis Lezdins wrote:
  | | By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
  | | cache is not implemented in realtime level, but higher (chan_sip).
  | |
  | | Are you sure you need sip show XXX load. If you sip prune peer
  | | data, it should be re-loaded on next access.
  | |
  | | What i was suggesting - to dig into chan_sip and create dialplan
  | | application SipPrune(peer) that would prune the peer directly, by
  | | using corresponding function - sip_prune_peer() in chan_sip.c - that
  | | way you will gain some extra performance, as there's no manager/cli
  | | overhead.
  | |
  | | However if you're uncomfortable with C, the app_system shouldn't cause
  | | any troubles :)
  |
  | RealTimeUpdate is more likely to correspond to app_realtime rather than
  | func_realtime.
  |
  | As to my knowledge - that is obsolete and being removed in 1.6,
  | func_realtime replaces it. That's why i wondered about name -  I just
  | never happened to use it :)
  |
  | Regards,
  | Atis
  |
  |

  -BEGIN PGP SIGNATURE-
  Version: GnuPG v1.4.7 (GNU/Linux)
  Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

 iD8DBQFHsnaM6uKn5cBSgGQRAo/TAKDCruPrn2nm2XV/PYbfSuBKA0j5OwCfQ/Ox
  QE3SYEmZ01QHUT4ITwmLnT0=
  =SKEW
  -END PGP SIGNATURE-


 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:

 http://lists.digium.com/mailman/listinfo/asterisk-users



-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Atis Lezdins
On 2/12/08, Rob Hillis [EMAIL PROTECTED] wrote:

  This is implemented in the Asterisk Dialplan.

  What we're doing is to write a custom roaming extension application that
 (among other things) alters the mailbox that the device looks at to set the
 MWI indicator to that of the roaming extension.  All the systems we sell
 have SIP peers stored in a realtime MySQL database.

  For example, roaming extension 109 logs on to the device on extension 900.
 (our client requires the device to always maintain it's own extension
 number)  As part of the login process, RealTimeUpdate is called to update
 the mailbox watched by the device from 900 to 109.  While the update goes
 through fine, Asterisk itself has already cached the mailbox number as a
 result of having rtcachefriends set to yes in sip.conf.  Of course, this
 is required for the MWI indicator to work properly in the first place.

  The point that I'm using the system calls is to flush the cached device
 details and reload them from MySQL.  I can't see any way of doing this
 through RealTimeUpdate or via any other application, so I'm left with the
 manager commands to flush the entry, followed by a sip show XXX load to
 re-cache the details.  Works nicely, but it seems a bit ugly to me.

  Frankly, I'm surprised that RealTimeUpdate doesn't contain an option to
 flush and reload details, which would negate the need to employ other
 hacks to achieve this.

By RealTimeUpdate do you mean func_realtime? It shouldn't care, as
cache is not implemented in realtime level, but higher (chan_sip).

Are you sure you need sip show XXX load. If you sip prune peer
data, it should be re-loaded on next access.

What i was suggesting - to dig into chan_sip and create dialplan
application SipPrune(peer) that would prune the peer directly, by
using corresponding function - sip_prune_peer() in chan_sip.c - that
way you will gain some extra performance, as there's no manager/cli
overhead.

However if you're uncomfortable with C, the app_system shouldn't cause
any troubles :)

Regards,
Atis





  Atis Lezdins wrote:
  On 2/12/08, Rob Hillis [EMAIL PROTECTED] wrote:


  If this is the only real alternative, then in this instance I'll stick with
 using the System command. Writing an AGI to execute two manager commands in
 this case is even greater overkill than using the System command.

  I understand that normally anything that calls multiple manager commands
 would usually be something complex enough to justify an AGI. The exception
 seems to be when you're dealing with cached realtime data. (is it just me,
 or does that sound like a rather odd oxymoron?)


  ast guy wrote:
   why don't you write an AGI which talks to asterisk manager API 5038 port
 and executes the asterisk commands. You execute asterisk command via agi not
 using system command
  
   -ag
  
   On Feb 11, 2008 11:24 AM, Rob Hillis [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED] wrote:
  

 Hi guys,

  I've been working on a little dialplan fragment for roaming extensions,
  however the customer wants us to set the MWI indicator for the roaming
  extension that has just logged in. We're using MySQL realtime, so I've
  figured out that RealTimeUpdate will happily update the realtime
  database with the correct mailbox. My problem comes when I need to tell
  Asterisk to flush the realtime data for that extension and reload it so
  that the cached data is correct. Running the commands sip prune
  realtime peer XXX followed by sip show peer XXX load work fine from
  the Asterisk manager interface and correctly update the cached data so
  the MWI indicator works fine.

  What I want to know is if there is any better method of running manager
  API commands from within the dialplan than the horribly ugly
  System(asterisk -rx sip prune realtime peer XXX) It works, but from
  my point of view, it's a somewhat nasty hack.

  Anyone have any suggestions?

  You could write dialplan application to do the same in chan_sip. Code
 should be very simple, just the processing of one argument and reusing
 existing functions. If you'll argument good enough why you need it, i
 think it could be included in asterisk.

 Regards,
 Atis




 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:

 http://lists.digium.com/mailman/listinfo/asterisk-users



-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Rob Hillis

This /is/ implemented in the Asterisk Dialplan.

What we're doing is to write a custom roaming extension application 
that (among other things) alters the mailbox that the device looks at to 
set the MWI indicator to that of the roaming extension.  All the 
systems we sell have SIP peers stored in a realtime MySQL database.


For example, roaming extension 109 logs on to the device on extension 
900. (our client requires the device to always maintain it's own 
extension number)  As part of the login process, RealTimeUpdate is 
called to update the mailbox watched by the device from 900 to 109.  
While the update goes through fine, Asterisk itself has already cached 
the mailbox number as a result of having rtcachefriends set to yes in 
sip.conf.  Of course, this is required for the MWI indicator to work 
properly in the first place.


The point that I'm using the system calls is to flush the cached device 
details and reload them from MySQL.  I can't see any way of doing this 
through RealTimeUpdate or via any other application, so I'm left with 
the manager commands to flush the entry, followed by a sip show XXX 
load to re-cache the details.  Works nicely, but it seems a bit ugly to me.


Frankly, I'm surprised that RealTimeUpdate doesn't contain an option to 
flush and reload details, which would negate the need to employ other 
hacks to achieve this.



Atis Lezdins wrote:

On 2/12/08, Rob Hillis [EMAIL PROTECTED] wrote:
  

 If this is the only real alternative, then in this instance I'll stick with
using the System command.  Writing an AGI to execute two manager commands in
this case is even greater overkill than using the System command.

 I understand that normally anything that calls multiple manager commands
would usually be something complex enough to justify an AGI.  The exception
seems to be when you're dealing with cached realtime data. (is it just me,
or does that sound like a rather odd oxymoron?)


 ast guy wrote:
  why don't you write an AGI which talks to asterisk manager API 5038 port
and executes the asterisk commands. You execute asterisk command via agi not
using system command
 
  -ag
 
  On Feb 11, 2008 11:24 AM, Rob Hillis [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:
 

Hi guys,

 I've been working on a little dialplan fragment for roaming extensions,
 however the customer wants us to set the MWI indicator for the roaming
 extension that has just logged in.  We're using MySQL realtime, so I've
 figured out that RealTimeUpdate will happily update the realtime
 database with the correct mailbox.  My problem comes when I need to tell
 Asterisk to flush the realtime data for that extension and reload it so
 that the cached data is correct.  Running the commands sip prune
 realtime peer XXX followed by sip show peer XXX load work fine from
 the Asterisk manager interface and correctly update the cached data so
 the MWI indicator works fine.

 What I want to know is if there is any better method of running manager
 API commands from within the dialplan than the horribly ugly
 System(asterisk -rx sip prune realtime peer XXX)  It works, but from
 my point of view, it's a somewhat nasty hack.

 Anyone have any suggestions?



You could write dialplan application to do the same in chan_sip. Code
should be very simple, just the processing of one argument and reusing
existing functions. If you'll argument good enough why you need it, i
think it could be included in asterisk.

Regards,
Atis


  
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Realtime SIP peers - reloading cached info

2008-02-12 Thread Atis Lezdins
On 2/12/08, Rob Hillis [EMAIL PROTECTED] wrote:

  If this is the only real alternative, then in this instance I'll stick with
 using the System command.  Writing an AGI to execute two manager commands in
 this case is even greater overkill than using the System command.

  I understand that normally anything that calls multiple manager commands
 would usually be something complex enough to justify an AGI.  The exception
 seems to be when you're dealing with cached realtime data. (is it just me,
 or does that sound like a rather odd oxymoron?)


  ast guy wrote:
   why don't you write an AGI which talks to asterisk manager API 5038 port
 and executes the asterisk commands. You execute asterisk command via agi not
 using system command
  
   -ag
  
   On Feb 11, 2008 11:24 AM, Rob Hillis [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED] wrote:
  

 Hi guys,

  I've been working on a little dialplan fragment for roaming extensions,
  however the customer wants us to set the MWI indicator for the roaming
  extension that has just logged in.  We're using MySQL realtime, so I've
  figured out that RealTimeUpdate will happily update the realtime
  database with the correct mailbox.  My problem comes when I need to tell
  Asterisk to flush the realtime data for that extension and reload it so
  that the cached data is correct.  Running the commands sip prune
  realtime peer XXX followed by sip show peer XXX load work fine from
  the Asterisk manager interface and correctly update the cached data so
  the MWI indicator works fine.

  What I want to know is if there is any better method of running manager
  API commands from within the dialplan than the horribly ugly
  System(asterisk -rx sip prune realtime peer XXX)  It works, but from
  my point of view, it's a somewhat nasty hack.

  Anyone have any suggestions?

You could write dialplan application to do the same in chan_sip. Code
should be very simple, just the processing of one argument and reusing
existing functions. If you'll argument good enough why you need it, i
think it could be included in asterisk.

Regards,
Atis


-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP peers - reloading cached info

2008-02-10 Thread Rob Hillis
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi guys,

I've been working on a little dialplan fragment for roaming extensions, 
however the customer wants us to set the MWI indicator for the roaming 
extension that has just logged in.  We're using MySQL realtime, so I've 
figured out that RealTimeUpdate will happily update the realtime 
database with the correct mailbox.  My problem comes when I need to tell 
Asterisk to flush the realtime data for that extension and reload it so 
that the cached data is correct.  Running the commands sip prune 
realtime peer XXX followed by sip show peer XXX load work fine from 
the Asterisk manager interface and correctly update the cached data so 
the MWI indicator works fine.

What I want to know is if there is any better method of running manager 
API commands from within the dialplan than the horribly ugly 
System(asterisk -rx sip prune realtime peer XXX)  It works, but from 
my point of view, it's a somewhat nasty hack.

Anyone have any suggestions?

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Remi - http://enigmail.mozdev.org

iD8DBQFHr+om6uKn5cBSgGQRAn++AJ4sNAHSG3s/FCVYTreBURn7Mt91UACgy26h
UC8Q+27UbbFsL9OnL/FzcOY=
=9gf8
-END PGP SIGNATURE-


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP BLF

2007-12-01 Thread Daniel Hazelbaker

On Nov 28, 2007, at 8:24 PM, [EMAIL PROTECTED]  
wrote:

 From memory - 'rtcachefriends=yes' should do the trick.

 PaulH

Sorry for the late response, wanted to make sure everything else was  
still working.  This did indeed solve the problem.  The only side  
affect I have noticed is that changed I make to the realtime database  
don't get picked up immediately.  Not sure what the cache timeout is  
but I am able to flush it manually so for the moment I don't care. :)

Thanks,
Daniel

 On Wed, 2007-11-28 at 16:56 -0800, Daniel Hazelbaker wrote:
 I am trying to get the presence/hints/BLF working along with Realtime
 SIP but I never get any busy notification. core show hints always
 shows the realtime sip user as idle.  I have tried setting call-limit
 to various values, including 1 but nothing seems to help.  I have
 tried limitonpeers both yes and no.

 Anybody got any other ideas?

 I do know the hinting is working as I can hint a Zap channel and it
 works fine.

 Daniel

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP BLF

2007-11-28 Thread Daniel Hazelbaker
I am trying to get the presence/hints/BLF working along with Realtime  
SIP but I never get any busy notification. core show hints always  
shows the realtime sip user as idle.  I have tried setting call-limit  
to various values, including 1 but nothing seems to help.  I have  
tried limitonpeers both yes and no.

Anybody got any other ideas?

I do know the hinting is working as I can hint a Zap channel and it  
works fine.

Daniel

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Realtime SIP BLF

2007-11-28 Thread Paul Hales

From memory - 'rtcachefriends=yes' should do the trick.

PaulH


On Wed, 2007-11-28 at 16:56 -0800, Daniel Hazelbaker wrote:
 I am trying to get the presence/hints/BLF working along with Realtime  
 SIP but I never get any busy notification. core show hints always  
 shows the realtime sip user as idle.  I have tried setting call-limit  
 to various values, including 1 but nothing seems to help.  I have  
 tried limitonpeers both yes and no.
 
 Anybody got any other ideas?
 
 I do know the hinting is working as I can hint a Zap channel and it  
 works fine.
 
 Daniel
 
 ___
 --Bandwidth and Colocation Provided by http://www.api-digital.com--
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users


___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Realtime SIP Authentication

2006-08-10 Thread ronn100200

Hi All,



I'm using Realtime for SIP users and I looking to find a way to be able
to authenticate users based on both the username and IP of the incoming
call the reason being I have different users connecting from same IP
but using different usernames.



I have read that setting type=peer is only matched on IP address/port.



Is it possible to configure Realtime to match on username and IP? 







Ron.

 



Check Out the new free AIM(R) Mail -- 2 GB of storage and industry-leading spam and email virus protection.



___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] Realtime SIP Authentication

2006-08-10 Thread Rushowr



username + secret


  
  
  From: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  [EMAIL PROTECTED]Sent: Thursday, August 10, 2006 7:53 
  AMTo: asterisk-users@lists.digium.comSubject: 
  [asterisk-users] Realtime SIP Authentication
  
  Hi All,I'm using Realtime for SIP users and I looking to 
  find a way to be able to authenticate users based on both the username and IP 
  of the incoming call the reason being I have different users connecting from 
  same IP but using different usernames.I have read that setting 
  type=peer is only matched on IP address/port.Is it possible to 
  configure Realtime to match on username and IP? Ron.
  
  
  Check Out the new free AIM(R) Mail -- 2 GB of storage 
  and industry-leading spam and email virus 
protection.
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Registrations

2006-06-30 Thread David Thomas

Doug,

If you'd be willing to share the patch and AGI, I would be happy to
help test your solution. I know that myself and several others have
been looking for a way to make Asterisk do this for quite some time.

regards,
David

On 6/29/06, Doug G [EMAIL PROTECTED] wrote:

Well, to dial a peer direclty the only thing that is missing in realtime is the 
status of the sip peer.  (registered, Unregistered, unknown, reachable).   If 
you dial a peer via ip and it is unavaliable you get dead air.  So you need to 
know the status of the peer before dialing it.   The change basicly updates 
realtime with the peers status.  I did the same thing for IAX as well..

Doug




From: [EMAIL PROTECTED] on behalf of Mike Lynchfield
Sent: Thu 6/29/2006 1:43 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [Asterisk-Users] Realtime SIP Registrations


can you elaborate on modify sip to update the status on the sip friends in 
realtime
thanks


On 6/29/06, Doug G  [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]  wrote:

   What I did was modify sip to update the status on the sip friends in realtime.   
Then via FAGI dial them directly with the data found in real-time. (ie dial ( SIP/[EMAIL 
PROTECTED]:5060) Of course you need to check the status in realtime data before you 
dial.  This allows MANY Asterisk servers to share the same SIP data.I then load balance with 
DNS SRV..  Yes I have tested in failover it works.



   I too have been told that by many that this will not work.  So I keep 
expecting to hit some problem with it, but to date I have not...



   Doug





   

   From: [EMAIL PROTECTED] on behalf of David Thomas
   Sent: Thu 6/29/2006 1:05 PM
   To: Asterisk Users Mailing List - Non-Commercial Discussion
   Subject: Re: [Asterisk-Users] Realtime SIP Registrations



   I think lots of us know about it... We're just not sure how to go
   about fixing it. :-(
   I know it's been a thorn in my side since I started using Asterisk.

   I would suspect that many of those saying works for me have never
   actually tested their system in failure scenarios, or they are working
   in a controlled environment without NAT and such...

   regards,
   David

   On 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:
 -Original Message-
 From: Aaron Daniel [mailto: [EMAIL PROTECTED] mailto:[EMAIL 
PROTECTED] ]
 Sent: Thursday, June 29, 2006 9:27 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: RE: [Asterisk-Users] Realtime SIP Registrations


 On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
  How about fixing realtime SIP so that multiple Asterisk
 boxes can reference the same database?
 
  Doug.

 That's kinda what I'm hoping to work towards :)
   
I'm surprised you even knew about that. There seems to be a common 
misconception that this should work (caused by common sense maybe). Every time I 
bring it up, people go 'Of course it works!', or 'Works for me!' (still don't know 
why it works for some and not others.)
   
Doug.
___
--Bandwidth and Colocation provided by Easynews.com --
   
Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users
   
   ___
   --Bandwidth and Colocation provided by Easynews.com --

   Asterisk-Users mailing list
   To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



   ___
   --Bandwidth and Colocation provided by Easynews.com --

   Asterisk-Users mailing list
   To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users







--
Mike
Sales Manager
http://www.theclubvoip.com
Making it happen
1.888.470.7253

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users




___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-30 Thread Douglas Garstang
I'm intensely curious why it doesn't currently work.
You have multiple Asterisk systems, all referring to a common table for SIP 
peer information. 
The fact that there is multiple Asterisk systems accessing the same MySQL data 
should be completely transparent to each of them, and I don't understand why 
this doesn't work.

Anyone?

Doug.

 -Original Message-
 From: David Thomas [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 30, 2006 9:40 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [Asterisk-Users] Realtime SIP Registrations
 
 
 Doug,
 
 If you'd be willing to share the patch and AGI, I would be happy to
 help test your solution. I know that myself and several others have
 been looking for a way to make Asterisk do this for quite some time.
 
 regards,
 David
 
 On 6/29/06, Doug G [EMAIL PROTECTED] wrote:
  Well, to dial a peer direclty the only thing that is 
 missing in realtime is the status of the sip peer.  
 (registered, Unregistered, unknown, reachable).   If you dial 
 a peer via ip and it is unavaliable you get dead air.  So you 
 need to know the status of the peer before dialing it.   The 
 change basicly updates realtime with the peers status.  I did 
 the same thing for IAX as well..
 
  Doug
 
 
  
 
  From: [EMAIL PROTECTED] on behalf of 
 Mike Lynchfield
  Sent: Thu 6/29/2006 1:43 PM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: Re: [Asterisk-Users] Realtime SIP Registrations
 
 
  can you elaborate on modify sip to update the status on 
 the sip friends in realtime
  thanks
 
 
  On 6/29/06, Doug G  [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED]  wrote:
 
 What I did was modify sip to update the status on 
 the sip friends in realtime.   Then via FAGI dial them 
 directly with the data found in real-time. (ie dial ( 
 SIP/[EMAIL PROTECTED]:5060) Of course you need to check 
 the status in realtime data before you dial.  This allows 
 MANY Asterisk servers to share the same SIP data.I then 
 load balance with DNS SRV..  Yes I have tested in failover it works.
 
 
 
 I too have been told that by many that this will not 
 work.  So I keep expecting to hit some problem with it, but 
 to date I have not...
 
 
 
 Doug
 
 
 
 
 
 
 
 From: [EMAIL PROTECTED] on 
 behalf of David Thomas
 Sent: Thu 6/29/2006 1:05 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [Asterisk-Users] Realtime SIP Registrations
 
 
 
 I think lots of us know about it... We're just not 
 sure how to go
 about fixing it. :-(
 I know it's been a thorn in my side since I started 
 using Asterisk.
 
 I would suspect that many of those saying works for 
 me have never
 actually tested their system in failure scenarios, 
 or they are working
 in a controlled environment without NAT and such...
 
 regards,
 David
 
 On 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:
   -Original Message-
   From: Aaron Daniel [mailto: [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] ]
   Sent: Thursday, June 29, 2006 9:27 AM
   To: Asterisk Users Mailing List - Non-Commercial 
 Discussion
   Subject: RE: [Asterisk-Users] Realtime SIP Registrations
  
  
   On Thu, 2006-06-29 at 09:15 -0600, Douglas 
 Garstang wrote:
How about fixing realtime SIP so that multiple Asterisk
   boxes can reference the same database?
   
Doug.
  
   That's kinda what I'm hoping to work towards :)
 
  I'm surprised you even knew about that. There 
 seems to be a common misconception that this should work 
 (caused by common sense maybe). Every time I bring it up, 
 people go 'Of course it works!', or 'Works for me!' (still 
 don't know why it works for some and not others.)
 
  Doug.
  ___
  --Bandwidth and Colocation provided by Easynews.com --
 
  Asterisk-Users mailing list
  To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
 
 
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
 
 
 
 
 
 
  --
  Mike
  Sales Manager
  http://www.theclubvoip.com
  Making

Re: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Tim Panton


On 29 Jun 2006, at 02:08, Aaron Daniel wrote:


Has anyone considered the idea of splitting the sip registration
information in a realtime database from the actual configuration of  
the

peers?

I mean, instead of having a table full of the configuration  
information

(i.e. name, regexten, secret, etc) and registration information (i.e.
ipaddr, fullcontact, etc), you have separate tables with their own
information.  This way, you can have separate tables with config
information, and use a view for the actual compiled configuration,
instead of how it is now, where there may be repeating info all  
over the

database.

Does any of that make sense?


Yes, except, if I understand you correctly, you would also
need to write insert and update triggers on the view, so that
when asterisk writes to the compiled config, the correct changes
are applied to your separate tables.
That might limit your choice of databases a bit.

The other thing to watch is that you have to ensure that
the resulting view behaves exactly the way that asterisk
expects it to, unless you get the join right, you can
get duplicate (apparently identical) records back
which would confuse asterisk.

Overall I like the idea, we do this sort of thing lots in
the web world, I'll probably try something similar in
cdr odbc .

By the way, has anyone used cdr_odbc to oracle XE (the free one)
yet ?

Tim.


--
Aaron Daniel

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Tim Panton
[EMAIL PROTECTED]



___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Aaron Daniel
On Thu, 2006-06-29 at 10:04 +0100, Tim Panton wrote:
 Yes, except, if I understand you correctly, you would also
 need to write insert and update triggers on the view, so that
 when asterisk writes to the compiled config, the correct changes
 are applied to your separate tables.
 That might limit your choice of databases a bit.

The way I designed the second table, you wouldn't have to update any
other tables with information from the sipregs table.  The only
information in there is information that asterisk needs to contact
phones and such.  So, for example, unless you need the ip address listed
somewhere else in your database, you can leave it in sipregs.

 
 The other thing to watch is that you have to ensure that
 the resulting view behaves exactly the way that asterisk
 expects it to, unless you get the join right, you can
 get duplicate (apparently identical) records back
 which would confuse asterisk.

That's something that you have to be careful about anyhow :)  The way
I'm looking at it, you can either use a view (we use 3 different tables
for actual phone configuration... so a view makes sense).  Or for
smaller systems, use an actual sippeers table and put the info in there.

-- 
Aaron Daniel
Computer Systems Technician
Sam Houston State University
[EMAIL PROTECTED]
(936) 294-4198
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Douglas Garstang
 -Original Message-
 From: Aaron Daniel [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, June 28, 2006 7:08 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: [Asterisk-Users] Realtime SIP Registrations
 
 
 Has anyone considered the idea of splitting the sip registration
 information in a realtime database from the actual 
 configuration of the
 peers?
 
 I mean, instead of having a table full of the configuration 
 information
 (i.e. name, regexten, secret, etc) and registration information (i.e.
 ipaddr, fullcontact, etc), you have separate tables with their own
 information.  This way, you can have separate tables with config
 information, and use a view for the actual compiled configuration,
 instead of how it is now, where there may be repeating info 
 all over the
 database.
 
 Does any of that make sense?

How about fixing realtime SIP so that multiple Asterisk boxes can reference the 
same database?

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Aaron Daniel
On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
 How about fixing realtime SIP so that multiple Asterisk boxes can reference 
 the same database?
 
 Doug.

That's kinda what I'm hoping to work towards :)


-- 
Aaron Daniel
Computer Systems Technician
Sam Houston State University
[EMAIL PROTECTED]
(936) 294-4198
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Douglas Garstang
 -Original Message-
 From: Aaron Daniel [mailto:[EMAIL PROTECTED]
 Sent: Thursday, June 29, 2006 9:27 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: RE: [Asterisk-Users] Realtime SIP Registrations
 
 
 On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
  How about fixing realtime SIP so that multiple Asterisk 
 boxes can reference the same database?
  
  Doug.
 
 That's kinda what I'm hoping to work towards :)

I'm surprised you even knew about that. There seems to be a common 
misconception that this should work (caused by common sense maybe). Every time 
I bring it up, people go 'Of course it works!', or 'Works for me!' (still don't 
know why it works for some and not others.)

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread David Thomas

I think lots of us know about it... We're just not sure how to go
about fixing it. :-(
I know it's been a thorn in my side since I started using Asterisk.

I would suspect that many of those saying works for me have never
actually tested their system in failure scenarios, or they are working
in a controlled environment without NAT and such...

regards,
David

On 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:

 -Original Message-
 From: Aaron Daniel [mailto:[EMAIL PROTECTED]
 Sent: Thursday, June 29, 2006 9:27 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: RE: [Asterisk-Users] Realtime SIP Registrations


 On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
  How about fixing realtime SIP so that multiple Asterisk
 boxes can reference the same database?
 
  Doug.

 That's kinda what I'm hoping to work towards :)

I'm surprised you even knew about that. There seems to be a common 
misconception that this should work (caused by common sense maybe). Every time 
I bring it up, people go 'Of course it works!', or 'Works for me!' (still don't 
know why it works for some and not others.)

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Doug G
What I did was modify sip to update the status on the sip friends in 
realtime.   Then via FAGI dial them directly with the data found in real-time. 
(ie dial (SIP/[EMAIL PROTECTED]:5060) Of course you need to check the status 
in realtime data before you dial.  This allows MANY Asterisk servers to share 
the same SIP data.I then load balance with DNS SRV..  Yes I have tested in 
failover it works.

 

I too have been told that by many that this will not work.  So I keep expecting 
to hit some problem with it, but to date I have not...

 

Doug

 

 



From: [EMAIL PROTECTED] on behalf of David Thomas
Sent: Thu 6/29/2006 1:05 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [Asterisk-Users] Realtime SIP Registrations



I think lots of us know about it... We're just not sure how to go
about fixing it. :-(
I know it's been a thorn in my side since I started using Asterisk.

I would suspect that many of those saying works for me have never
actually tested their system in failure scenarios, or they are working
in a controlled environment without NAT and such...

regards,
David

On 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:
  -Original Message-
  From: Aaron Daniel [mailto:[EMAIL PROTECTED]
  Sent: Thursday, June 29, 2006 9:27 AM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: RE: [Asterisk-Users] Realtime SIP Registrations
 
 
  On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
   How about fixing realtime SIP so that multiple Asterisk
  boxes can reference the same database?
  
   Doug.
 
  That's kinda what I'm hoping to work towards :)

 I'm surprised you even knew about that. There seems to be a common 
 misconception that this should work (caused by common sense maybe). Every 
 time I bring it up, people go 'Of course it works!', or 'Works for me!' 
 (still don't know why it works for some and not others.)

 Doug.
 ___
 --Bandwidth and Colocation provided by Easynews.com --

 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


winmail.dat___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Mike Lynchfield
can you elaborate on  modify sip to update the status on the sip friends in realtimethanksOn 6/29/06, Doug G 
[EMAIL PROTECTED] wrote:What I did was modify sip to update the status on the sip friends in realtime. Then via FAGI dial them directly with the data found in real-time. (ie dial (
SIP/[EMAIL PROTECTED]:5060) Of course you need to check the status in realtime data before you dial.This allows MANY Asterisk servers to share the same SIP data.I then load balance with DNS SRV..Yes I have tested in failover it works.
I too have been told that by many that this will not work.So I keep expecting to hit some problem with it, but to date I have not...Doug
From: [EMAIL PROTECTED] on behalf of David ThomasSent: Thu 6/29/2006 1:05 PMTo: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [Asterisk-Users] Realtime SIP RegistrationsI think lots of us know about it... We're just not sure how to goabout fixing it. :-(I know it's been a thorn in my side since I started using Asterisk.
I would suspect that many of those saying works for me have neveractually tested their system in failure scenarios, or they are workingin a controlled environment without NAT and such...
regards,DavidOn 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:  -Original Message-  From: Aaron Daniel [mailto:
[EMAIL PROTECTED]]  Sent: Thursday, June 29, 2006 9:27 AM  To: Asterisk Users Mailing List - Non-Commercial Discussion  Subject: RE: [Asterisk-Users] Realtime SIP Registrations 
   On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:   How about fixing realtime SIP so that multiple Asterisk  boxes can reference the same database?  
   Doug.   That's kinda what I'm hoping to work towards :) I'm surprised you even knew about that. There seems to be a common misconception that this should work (caused by common sense maybe). Every time I bring it up, people go 'Of course it works!', or 'Works for me!' (still don't know why it works for some and not others.)
 Doug. ___ --Bandwidth and Colocation provided by Easynews.com -- Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users___
--Bandwidth and Colocation provided by Easynews.com --Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit: 
http://lists.digium.com/mailman/listinfo/asterisk-users___--Bandwidth and Colocation provided by Easynews.com --
Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
-- MikeSales Managerhttp://www.theclubvoip.comMaking it happen1.888.470.7253
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Registrations

2006-06-29 Thread Doug G
Well, to dial a peer direclty the only thing that is missing in realtime is the 
status of the sip peer.  (registered, Unregistered, unknown, reachable).   If 
you dial a peer via ip and it is unavaliable you get dead air.  So you need to 
know the status of the peer before dialing it.   The change basicly updates 
realtime with the peers status.  I did the same thing for IAX as well..
 
Doug
 



From: [EMAIL PROTECTED] on behalf of Mike Lynchfield
Sent: Thu 6/29/2006 1:43 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [Asterisk-Users] Realtime SIP Registrations


can you elaborate on modify sip to update the status on the sip friends in 
realtime
thanks


On 6/29/06, Doug G  [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]  wrote: 

What I did was modify sip to update the status on the sip friends in 
realtime.   Then via FAGI dial them directly with the data found in real-time. 
(ie dial ( SIP/[EMAIL PROTECTED]:5060) Of course you need to check the status 
in realtime data before you dial.  This allows MANY Asterisk servers to share 
the same SIP data.I then load balance with DNS SRV..  Yes I have tested in 
failover it works. 



I too have been told that by many that this will not work.  So I keep 
expecting to hit some problem with it, but to date I have not...



Doug





 

From: [EMAIL PROTECTED] on behalf of David Thomas
Sent: Thu 6/29/2006 1:05 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion 
Subject: Re: [Asterisk-Users] Realtime SIP Registrations



I think lots of us know about it... We're just not sure how to go
about fixing it. :-(
I know it's been a thorn in my side since I started using Asterisk. 

I would suspect that many of those saying works for me have never
actually tested their system in failure scenarios, or they are working
in a controlled environment without NAT and such...

regards,
David

On 6/29/06, Douglas Garstang [EMAIL PROTECTED] wrote:
  -Original Message-
  From: Aaron Daniel [mailto: [EMAIL PROTECTED] mailto:[EMAIL 
PROTECTED] ]
  Sent: Thursday, June 29, 2006 9:27 AM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: RE: [Asterisk-Users] Realtime SIP Registrations
  
 
  On Thu, 2006-06-29 at 09:15 -0600, Douglas Garstang wrote:
   How about fixing realtime SIP so that multiple Asterisk
  boxes can reference the same database?
   
   Doug.
 
  That's kinda what I'm hoping to work towards :)

 I'm surprised you even knew about that. There seems to be a common 
misconception that this should work (caused by common sense maybe). Every time 
I bring it up, people go 'Of course it works!', or 'Works for me!' (still don't 
know why it works for some and not others.) 

 Doug.
 ___
 --Bandwidth and Colocation provided by Easynews.com --

 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___ 
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users



___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users







-- 
Mike
Sales Manager
http://www.theclubvoip.com
Making it happen
1.888.470.7253 
winmail.dat___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Realtime SIP Registrations

2006-06-28 Thread Aaron Daniel
Has anyone considered the idea of splitting the sip registration
information in a realtime database from the actual configuration of the
peers?

I mean, instead of having a table full of the configuration information
(i.e. name, regexten, secret, etc) and registration information (i.e.
ipaddr, fullcontact, etc), you have separate tables with their own
information.  This way, you can have separate tables with config
information, and use a view for the actual compiled configuration,
instead of how it is now, where there may be repeating info all over the
database.

Does any of that make sense?

--
Aaron Daniel



signature.asc
Description: OpenPGP digital signature
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-22 Thread Olle E Johansson


21 mar 2006 kl. 19.07 skrev Douglas Garstang:


Ready to scream here..


No one is surprised ;-)

1. After 6 months with Asterisk I'm STILL trying to understand the  
difference between a SIP user, friend and peer.
* A friend is a peer object and a user object. It's just a  
configuration shorthand, not a type.
* A user is someone who uses your PBX to place calls, we match  
incoming calls on users.

* A peer is someone we place calls to, outgoing calls.

Peers register with Asterisk.

So far, it's simple. In some cases however, the peer is used for  
incoming calls. This is mostly used

when connecting to service providers.

2. Exactly what resource does Asterisk use to send MWI to  
registered phones? I thought it was astdb?

How did you come to that conclusion?

You can configure a mailbox for a peer. If you do, we send MWI to  
peers we have in memory, static

peers or cached realtime peers.

3. It looks like it isn't astdb. It looks like it will only send  
MWI to a phone if it shows up in 'sip show peers'.

Only peers we have in memory are supported for MWI and qualification.

4. WHY then does a reload clear this list? Doesn't this list come  
from the astdb file?

I explained this in the bug tracker.

Reload clears everything but registered static peers, these are re- 
configured from astdb.

We do not support this for realtime peers.


5. Why is this such a damn mess?
I guess it's history. I am trying to clear this up. Follow my work in  
the test branch and the
sippeers branch and you'll see that I've started cleaning this up.  
The user is disappearing
and will in chan_sip3 be device. Chan_sip3 will have these three  
objects:


* Phone:	 	A device that uses Asterisk as it's PBX for outgoing and  
incoming calls

* Trunk:Another PBX or SIP proxy that we peer with
* Service: 	A service we subscribe to, acting as a phone that  
connects to it


/Olle
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-22 Thread Andrew Kohlsmith
On Wednesday 22 March 2006 08:34, Olle E Johansson wrote:
  4. WHY then does a reload clear this list? Doesn't this list come
  from the astdb file?

 I explained this in the bug tracker.

 Reload clears everything but registered static peers, these are re-
 configured from astdb.
 We do not support this for realtime peers.

I have to agree with Douglas here -- why make the distinction?  I don't 
understand it.  Peers are peers, whether they come from a flat file or from a 
DB.  If a reload is performed, it should clear the entire registered list, or 
none of it.

Your explanation in the bugtracker didn't make sense as to why one is 
considered static or more permanent than the other.  Peers are (or rather 
should be) peers, no matter where they come from.  Is this the plan with your 
sip3 work?

-A.
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-22 Thread Olle E Johansson


22 mar 2006 kl. 15.02 skrev Andrew Kohlsmith:


On Wednesday 22 March 2006 08:34, Olle E Johansson wrote:

4. WHY then does a reload clear this list? Doesn't this list come
from the astdb file?


I explained this in the bug tracker.

Reload clears everything but registered static peers, these are re-
configured from astdb.
We do not support this for realtime peers.


I have to agree with Douglas here -- why make the distinction?  I  
don't
understand it.  Peers are peers, whether they come from a flat file  
or from a
DB.  If a reload is performed, it should clear the entire  
registered list, or

none of it.


That would mean that we would have to go through each entry in the
realtime database at load time (or reload) and reconfigure the peers.
Is that something you want your asterisk to do? Considering this can
be 10.000 peers.



Your explanation in the bugtracker didn't make sense as to why one is
considered static or more permanent than the other.  Peers are  
(or rather
should be) peers, no matter where they come from.  Is this the plan  
with your

sip3 work?

Static peers are static peers and dynamic peers are dynamic,  
regardless of

storage.

This is the way the dynamic peers work. They're not meant to occupy  
memory.
If you need the properties of a static peer - why don't configure  
them that way?


/O
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-22 Thread Douglas Garstang


 -Original Message-
 From: Olle E Johansson [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, March 22, 2006 8:41 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [Asterisk-Users] Realtime / SIP Peers etc
 
 
 
 22 mar 2006 kl. 15.02 skrev Andrew Kohlsmith:
 
  On Wednesday 22 March 2006 08:34, Olle E Johansson wrote:
  4. WHY then does a reload clear this list? Doesn't this list come
  from the astdb file?
 
  I explained this in the bug tracker.
 
  Reload clears everything but registered static peers, these are re-
  configured from astdb.
  We do not support this for realtime peers.
 
  I have to agree with Douglas here -- why make the distinction?  I  
  don't
  understand it.  Peers are peers, whether they come from a 
 flat file  
  or from a
  DB.  If a reload is performed, it should clear the entire  
  registered list, or
  none of it.
 
 That would mean that we would have to go through each entry in the
 realtime database at load time (or reload) and reconfigure the peers.
 Is that something you want your asterisk to do? Considering this can
 be 10.000 peers.
 
 
  Your explanation in the bugtracker didn't make sense as to 
 why one is
  considered static or more permanent than the other.  Peers are  
  (or rather
  should be) peers, no matter where they come from.  Is this 
 the plan  
  with your
  sip3 work?
 
 Static peers are static peers and dynamic peers are dynamic,  
 regardless of
 storage.
 
 This is the way the dynamic peers work. They're not meant to occupy  
 memory.
 If you need the properties of a static peer - why don't configure  
 them that way?

I'm not sure I'm talking about the same thing, but if this is true, it may 
clear a few things up.
Firstly, from what I've been told my Kevin Fleming on this list, and by calling 
Digium directly, support for multiple Asterisk systems accessing the same MySQL 
database for sip user/peer information, does not exist. Digium told me they 
where aware of it, and it would probably take a single person the better part 
of a year to fix.

Given that, I wanted to use realtime to load and cache the peer information, 
and that's it. If Asterisk has to refer to the database each time a peer 
registers, it just plain doesn't work! 


 
 /O
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-22 Thread Aaron Daniel

I'm not sure I'm talking about the same thing, but if this is true, it may 
clear a few things up.
Firstly, from what I've been told my Kevin Fleming on this list, and by calling 
Digium directly, support for multiple Asterisk systems accessing the same MySQL 
database for sip user/peer information, does not exist. Digium told me they 
where aware of it, and it would probably take a single person the better part 
of a year to fix.

Given that, I wanted to use realtime to load and cache the peer information, 
and that's it. If Asterisk has to refer to the database each time a peer 
registers, it just plain doesn't work!


This is true and false.  We had two servers pulling from the same db for a 
long time, until we switched to two separate DB's on their own servers 
since it was a single point of failure (and when it failed, whoa...). 
From talking with the developers, the only thing this causes problems with 
is phones behind NATs.  I don't remember us ever having problems using the 
same DB for sip registrations ever, even for NAT'ed phones.  I think it's 
one of those try and see type things, cause we tried and it worked for 
us.


 --
Aaron Daniel Computer Systems Technician
Sam Houston State University
[EMAIL PROTECTED]
(936) 294-4198
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Realtime / SIP Peers etc

2006-03-21 Thread Douglas Garstang



Ready 
to scream here..

1. 
After 6 months with Asterisk I'm STILL trying to understand the difference 
between a SIP user, friend and peer.
2. 
Exactly what resource does Asterisk use to send MWI to registered phones? I 
thought it was astdb? 
3. It 
looks like it isn't astdb. It looks like it will only send MWI to a phone if it 
shows up in 'sip show peers'.
4. WHY 
then does a reload clear this list? Doesn't this list come from the astdb 
file?
5. Why 
is this such a damn mess?

Doug.

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread Douglas Garstang
I've been using realtime for sip users information.

I noticed that when you are doing this, if you do a 'reload' or restart 
asterisk, the information in a 'sip show peers' goes away. When I do this, MWI 
stops working. I always though MWI used the astdb file ('database show') to 
determine where to send MWI but it must be using 'sip show peers' because when 
this is cleared, it stops working. 

When I stop using realtime and instead provision users in sip.conf, a reload or 
restart DOES NOT clear 'sip show peers'. It must be populating this list from 
the astdb file in that case.

I'm going to scoot over to bugs.digium.com and report this as a bug, because 
this is a real show stopper, and completely nullifies Realtime's use for us.

Doug
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread Barry Flanagan
Douglas Garstang wrote:
 I've been using realtime for sip users information.
 
 I noticed that when you are doing this, if you do a 'reload' or restart 
 asterisk, the information in a 'sip show peers' goes away. When I do this, 
 MWI stops working. I always though MWI used the astdb file ('database show') 
 to determine where to send MWI but it must be using 'sip show peers' because 
 when this is cleared, it stops working. 
 
 When I stop using realtime and instead provision users in sip.conf, a reload 
 or restart DOES NOT clear 'sip show peers'. It must be populating this list 
 from the astdb file in that case.
 
 I'm going to scoot over to bugs.digium.com and report this as a bug, because 
 this is a real show stopper, and completely nullifies Realtime's use for us.
 

Doug,

I think this is documented behaviour. With realtime the peers do not
show up under sip show peers, and MWI does not happen. I think though if
you use rtcachefriends=yes in your [general] section of sip.conf that it
will work as you desire.

Hope this helps.

-- 

-Barry Flanagan
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread David Thomas
Try googling the archives using the keywords rtcachefriends  mwi.
You should find more info about this.

regards,
David
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread Rich Adamson

David Thomas wrote:

Try googling the archives using the keywords rtcachefriends  mwi.
You should find more info about this.


Google doesn't work anymore; the subjects are listed just fine, but 
clicking on one leads to page not found.


___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread Douglas Garstang
I do have rtcachefriends=yes in sip.conf, and my astdb file is full of sip 
contacts.
That's not the problem.

 -Original Message-
 From: Barry Flanagan [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, March 21, 2006 12:12 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [Asterisk-Users] Realtime SIP Persistency
 
 
 Douglas Garstang wrote:
  I've been using realtime for sip users information.
  
  I noticed that when you are doing this, if you do a 
 'reload' or restart asterisk, the information in a 'sip show 
 peers' goes away. When I do this, MWI stops working. I always 
 though MWI used the astdb file ('database show') to determine 
 where to send MWI but it must be using 'sip show peers' 
 because when this is cleared, it stops working. 
  
  When I stop using realtime and instead provision users in 
 sip.conf, a reload or restart DOES NOT clear 'sip show 
 peers'. It must be populating this list from the astdb file 
 in that case.
  
  I'm going to scoot over to bugs.digium.com and report this 
 as a bug, because this is a real show stopper, and completely 
 nullifies Realtime's use for us.
  
 
 Doug,
 
 I think this is documented behaviour. With realtime the peers do not
 show up under sip show peers, and MWI does not happen. I 
 think though if
 you use rtcachefriends=yes in your [general] section of 
 sip.conf that it
 will work as you desire.
 
 Hope this helps.
 
 -- 
 
 -Barry Flanagan
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP Persistency

2006-03-21 Thread Douglas Garstang
I have rtcachefriends=yes in sip.conf.
It is caching friends because as I said in my post, astdb has all the contacts, 
ie they're cached.
It's the behaviour of 'sip show peers' that's not working.

 -Original Message-
 From: David Thomas [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, March 21, 2006 12:21 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [Asterisk-Users] Realtime SIP Persistency
 
 
 Try googling the archives using the keywords rtcachefriends  mwi.
 You should find more info about this.
 
 regards,
 David
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime / SIP Peers etc

2006-03-21 Thread pdhales



User - sends you calls
Peer - you send calls
Friend - Both ways

later,

Paul HalesTechnical 
ManagerAsteriskIT


  - Original Message - 
  From: 
  Douglas 
  Garstang 
  To: Asterisk Users Mailing List - 
  Non-Commercial Discussion 
  Sent: Wednesday, March 22, 2006 5:07 
  AM
  Subject: [Asterisk-Users] Realtime / SIP 
  Peers etc
  
  Ready to scream here..
  
  1. 
  After 6 months with Asterisk I'm STILL trying to understand the difference 
  between a SIP user, friend and peer.
  2. 
  Exactly what resource does Asterisk use to send MWI to registered phones? I 
  thought it was astdb? 
  3. 
  It looks like it isn't astdb. It looks like it will only send MWI to a phone 
  if it shows up in 'sip show peers'.
  4. 
  WHY then does a reload clear this list? Doesn't this list come from the astdb 
  file?
  5. 
  Why is this such a damn mess?
  
  Doug.
  
  
  

  ___--Bandwidth and 
  Colocation provided by Easynews.com --Asterisk-Users mailing 
  listTo UNSUBSCRIBE or update options visit: 
  http://lists.digium.com/mailman/listinfo/asterisk-users
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Realtime SIP users/peers

2006-03-18 Thread Douglas Garstang
Just spent hours dicking around with SIP Realtime.

Every time a phone came up and sent a registration to Asterisk, Asterisk would 
simply NOT query the database. I had sipusers in extconfig, but added sippeers 
as well. NOW I can see Asterisk doing a 'SELECT * FROM sippeers WHERE name = 
'2944093''. 

Huh??? Uhm, why? It's not a peer! It's a bloody phone, and in my mind should be 
a user or a friend! It should be looking in sippeers! How does it decide which 
table to use?

Has anyone made sense of this mess?

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [Asterisk-Users] Realtime SIP users/peers - Screwed?

2006-03-18 Thread Douglas Garstang
Oh heck. It really looks like realtime has been seriously screwed up.

When a call comes in to Asterisk, I can see asterisk executing these queries.
SELECT * FROM ast_sip_peers WHERE host = '2XX.YYY.142.205'
SELECT * FROM ast_sip_peers WHERE name = '2944093'
SELECT * FROM ast_sip_peers WHERE name = '2944093'

So, the first thing it does is check and see if there are any records in 
sip_peers where the IP address of the message matches. What happens if this 
user may make calls from multiple IP addresses? Will I need one entry for each 
IP address that calls may come from? Will this even work? Would I be so 
frustrated if this stuff was documented somewhere?


 -Original Message-
 From: Douglas Garstang 
 Sent: Saturday, March 18, 2006 11:55 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: [Asterisk-Users] Realtime SIP users/peers
 
 
 Just spent hours dicking around with SIP Realtime.
 
 Every time a phone came up and sent a registration to 
 Asterisk, Asterisk would simply NOT query the database. I had 
 sipusers in extconfig, but added sippeers as well. NOW I can 
 see Asterisk doing a 'SELECT * FROM sippeers WHERE name = '2944093''. 
 
 Huh??? Uhm, why? It's not a peer! It's a bloody phone, and in 
 my mind should be a user or a friend! It should be looking in 
 sippeers! How does it decide which table to use?
 
 Has anyone made sense of this mess?
 
 Doug.
 ___
 --Bandwidth and Colocation provided by Easynews.com --
 
 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP users/peers - Screwed?

2006-03-18 Thread Tim Panton


On 18 Mar 2006, at 19:21, Douglas Garstang wrote:


Oh heck. It really looks like realtime has been seriously screwed up.

When a call comes in to Asterisk, I can see asterisk executing  
these queries.

SELECT * FROM ast_sip_peers WHERE host = '2XX.YYY.142.205'
SELECT * FROM ast_sip_peers WHERE name = '2944093'
SELECT * FROM ast_sip_peers WHERE name = '2944093'

So, the first thing it does is check and see if there are any  
records in sip_peers where the IP address of the message matches.  
What happens if this user may make calls from multiple IP  
addresses? Will I need one entry for each IP address that calls may  
come from? Will this even work? Would I be so frustrated if this  
stuff was documented somewhere?




From the wiki:
---
Asterisk matches incoming calls to the name of a device with  
type=user based on the From: user name (ignoring the SIP domain). The  
other way that incoming SIP requests are matched to [xxx] sections in  
this file, is to examine the IP address that the request is coming  
from, and look for a peer [xxx] section that has a matching Host=  
value. If Host=dynamic, then no match is possible until the SIP  
client has registered.

 and -
When Asterisk receives an incoming SIP call, the SIP Channel Module
first tries to find a [user] section matching the caller name (From:  
username),

then tries to find a [peer] section matching the caller's IP address.
If no matching user or peer is found, the call is sent to the context  
defined in the [general] section of sip.conf.

--
(I know that doesn't entirely explain the behavior but it is a  
start)


I'm guessing that the sql query immediately before your extract was a  
name search that came up

with nothing



Tim Panton
[EMAIL PROTECTED]



___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Realtime SIP

2006-03-14 Thread Douglas Garstang
Is anyone using realtime sip for friends (ie phones) with multiple Asterisk 
boxes all pointing to the one central MySQL database? Does it work? Are phones 
that are registered to the database from Asterisk box able to reach phones 
registered to the database from another Asterisk box?

Doug.

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP

2006-03-14 Thread Aaron Daniel
We were using this setup for a while (well, it was using odbc, but same 
concept).  What we did was configured the phones to register with all 
the servers basically, so each phone was reachable by each server, and 
if a phone didn't register with a server for some reason, we have 
mechanisms in place to send the call to another server to check there. 
Worked like a charm :)


Aaron

Douglas Garstang wrote:

Is anyone using realtime sip for friends (ie phones) with multiple Asterisk 
boxes all pointing to the one central MySQL database? Does it work? Are phones 
that are registered to the database from Asterisk box able to reach phones 
registered to the database from another Asterisk box?

Doug.

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Realtime SIP

2006-03-14 Thread Simon Woodhead
Hi Doug,We use Realtime SIP via a central MySQL database (2 actually in Master  Master config) but registration is only available on the box to which the client has registered. Clients can register with any database and the table does get updated with some registration information (ip address, expiry time etc.) but they are not reachable by any of the other boxes sharing the config. I've been following the cluster thread with great interest for a workable solution to this.
All the best,SimonOn 3/14/06, Douglas Garstang [EMAIL PROTECTED] wrote:
Is anyone using realtime sip for friends (ie phones) with multiple Asterisk boxes all pointing to the one central MySQL database? Does it work? Are phones that are registered to the database from Asterisk box able to reach phones registered to the database from another Asterisk box?
Doug.___--Bandwidth and Colocation provided by Easynews.com --Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


  1   2   >