Re: [asterisk-users] sending sms from Asterisk server

2010-08-18 Thread asterisk asterisk
Could you share your AGI script?

CK

On Wed, Aug 18, 2010 at 5:43 AM, Johann Hoehn johann.ho...@ecommerce.comwrote:

 On 08/17/2010 09:00 AM, Tino wrote:
  Hello,
 
  I would like to send sms to some external phone numbers from my
  asterisk server. Is it possible to send sms via softphones like X-Lite
  ? . Any tips regarding this will be helpful
 
  thanks
 
 
 This is easy to do by using email to SMS gateways.  A list of them is on
 wikipedia (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the
 Asterisk side, you have an extension that sends the email.  I personally
 use an AGI script for this part, but you could use a System() call as well.


 --johann

 --
 _
 -- 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] sending sms from Asterisk server

2010-08-18 Thread Per Jessen
Johann Hoehn wrote:

 On 08/17/2010 09:00 AM, Tino wrote:
 Hello,

 I would like to send sms to some external phone numbers from my
 asterisk server. Is it possible to send sms via softphones like
 X-Lite ? . Any tips regarding this will be helpful

 thanks


 This is easy to do by using email to SMS gateways.  A list of them is
 on wikipedia (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For
 the Asterisk side, you have an extension that sends the email.  I
 personally use an AGI script for this part, but you could use a
 System() call as well.

Many telcos provide an SMSC, often also accessible over a landline.  We
use the Swisscom SMSC at 062210.  (Swisscom subscription required).


/Per Jessen, Zürich

-- 
http://www.spamchek.com/ - your spam is our business.


-- 
_
-- 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] IAX2 debug of registration - Only getting RX and there is no TX response from Asterisk - is that normal?

2010-08-18 Thread Nasir Iqbal
Hi,

Use requirecalltoken=no in your peer configuration

Regards

On Wed, Aug 11, 2010 at 4:28 AM, bruce bruce bruceb...@gmail.com wrote:

 Hello Everyone,

 I am trying to diagnose issue with my IAX2 extension not working.

 When I have iax2 set debug on all I see is this:

 *Rx-Frame Retry[ No] -- OSeqno: 000 ISeqno: 000 Type: IAX Subclass:
 REGREQ *
 *   Timestamp: 3ms  SCall: 00130  DCall: 0 [64.229.229.111:64823]*
 *   USERNAME: 100*
 *   REFRESH : 60*
 *
 *
 *Rx-Frame Retry[ No] -- OSeqno: 001 ISeqno: 001 Type: IAX Subclass:
 ACK*
 *   Timestamp: 3ms  SCall: 00130  DCall: 1 [64.229.229.111:64823]*


 So, all the packets are coming in, but there is no Tx response. Is that
 normal and is that how IAX2 works according to RFC to not respond back?

 I have checked my firewall and all is set fine. I have any WAN address to
 come in through port 4569 to map to the server and it worked last week but
 now it doesn't.

 Any suggestions?

 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




-- 
Nasir Iqbal

ICT Innovations
http://www.ictinnovations.com/
-- 
_
-- 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] MySQL Connect problem...

2010-08-18 Thread Nasir Iqbal
Avoid to use MySQL dialplan application, instead write an AGI script for
this purpose

On Tue, Aug 17, 2010 at 4:59 PM, Geraint Lee gera...@gmail.com wrote:

 Right, I'm baffled.

 I have:
 exten = s,1,MYSQL(Connect DB1 127.0.0.1 geraint xxx amis2)
 exten = s,n,MYSQL(Query NORESULT ${DB1} INSERT\ INTO\ recordings\
 (caller_number\,called_number\,date_created\,date_started\,in_use\,server_id)\
 VALUES\ (\'${CALLERID(number)}\'\,\'${ARG1}\'\,NOW()\,NOW()\,\'Yes\'\,12))
 exten = s,n,MYSQL(Query RESULT1 ${DB1} SELECT\ LAST_INSERT_ID())
 exten = s,n,MYSQL(Fetch FOUND1 ${RESULT1} VALUE1)
 exten = s,n,MYSQL(Clear ${RESULT1})
 exten = s,n,MYSQL(Disconnect ${DB1})
 exten = s,n,MixMonitor(${VALUE1}.wav)
 exten = s,n,Set(CALLERID(all)=xxx)
 exten = s,n,Dial(SIP/prov1/${ARG1})

 in a macro to dial numbers...

 Every few hours or so every call hangs on the s,1 MYSQL(Connect) and won't
 work until i restart asterisk.

 The mysql server has a maximum connections of 2048 (of which around 90 are
 in use) so it's not a mysql connection limit problem from what i can tell
 since while asterisk is stuck i can still log in to mysql just fine, as
 can the web server.

 Does anyone have any suggestions what could be causing asterisk to get
 stuck here? i don't see anything in cli and core show channels just shows
 everyone stuck in state ring on the connect string with no errors.

 Cheers

 Geraint

 --
 _
 -- 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




-- 
Nasir Iqbal

ICT Innovations
http://www.ictinnovations.com/
-- 
_
-- 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] Enhancing snmp mib

2010-08-18 Thread Benoit

Hi,

I'm quite pleased with the asterisk/res_snmp integration (at least a 
right one :) not some hackish scripted thingy)
but i felt it's missing quite a few datas.

What i would need is:
   *  Per channels, number of inbound call received since asterisk 
startup (like a network interface)
   *number of outbound call sent
   *  SIP status (peer reachable)
   *  DAHDI show channels equivalent
   *  queues status (number of calls proceeded, availability, )
   * Custom  oid, dialplan controlled, and/or dialpan readable
   *  Accessing internal * database could be nice too

For examples i would like to graph the numbers of calls received and 
sent on a channel type
like a network interface (for monitoring PRI/BRI usage for exemple).
However the current values is a realtime snapshot, not the best for this 
thing

Is there already some work planned on the snmp interface ?

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 Context

2010-08-18 Thread Ishfaq Malik

Unless I've got some massive misunderstanding, yes we do

as described here

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

Why do you ask?

On 17/08/10 17:27, Zeeshan Zakaria wrote:


Ishfaq, do you use the asterisk real-time architecture?

Zeeshan A Zakaria

--
www.ilovetovoip.com http://www.ilovetovoip.com

On 2010-08-17 11:45 AM, Ishfaq Malik i...@pack-net.co.uk 
mailto:i...@pack-net.co.uk wrote:


So that we can create a custom interface for our customers to be able 
to do simple stuff like adding extensions, changing dialplans without 
our (for our read my!) intervention.


The DB storage is the main thing for us.



On 17/08/10 16:09, Zeeshan Zakaria wrote:

 The whole point of using real-time, as the word 'rea...


--
_
-- 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


--
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 Context

2010-08-18 Thread Zeeshan Zakaria
So why you need a reload when you are using the real-time architecture? Are
you adding contexts in extensions.conf? If yes then where are you using the
real-time?

I asked because to me it seems you didn't understand what Dan is asking, and
also seems you don't know how real-time works in regards to add contexts
without reloading asterisk.

On 2010-08-18 4:25 AM, Ishfaq Malik i...@pack-net.co.uk wrote:

 Unless I've got some massive misunderstanding, yes we do

as described here

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

Why do you ask?



On 17/08/10 17:27, Zeeshan Zakaria wrote:

 Ishfaq, do you use the asterisk real-time architectu...

-- 
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
-- 
_
-- 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 Context

2010-08-18 Thread Ishfaq Malik

Hi

I'll give you an example process flow

Our customer logs onto our VoIP Portal and orders a SIP Geographic number
Geo number is successfully ordered which inserts an entry into our 
extensions table in MySQL DB in the default context which has a goto 
command to a newly created specific context for handling the incoming on 
that number.
The customer goes to the dial plan managing section of the portal and 
sets the number to ring an extension of his followed by going to 
voicemail. In the back end 2 new inserts are made into the extensions 
table for the newly created context.
Also, an insert is made into a table to say that the extensions table 
has been updated.


A cron runs and sees that the extensions table has been updated.
this gets a distinct list of contexts from the extensions table and 
writes each one to a new extensions.con putting in the realtime switch 
for each context.

The cron then executes a dialplan reload

If you can see a more elegant way of doing the above so that no 
intervention is required by anyone other that the customer, please let 
me know as I'm always willing to learn better ways of doing things.


Also, please bear in mind that we offer a hosted service for customers 
so we have lots of different companies all working off the same server(s)


Ish

On 18/08/10 10:37, Zeeshan Zakaria wrote:


So why you need a reload when you are using the real-time 
architecture? Are you adding contexts in extensions.conf? If yes then 
where are you using the real-time?


I asked because to me it seems you didn't understand what Dan is 
asking, and also seems you don't know how real-time works in regards 
to add contexts without reloading asterisk.


On 2010-08-18 4:25 AM, Ishfaq Malik i...@pack-net.co.uk 
mailto:i...@pack-net.co.uk wrote:


Unless I've got some massive misunderstanding, yes we do

as described here

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

Why do you ask?



On 17/08/10 17:27, Zeeshan Zakaria wrote:

 Ishfaq, do you use the asterisk real-time architectu...

--
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


--
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] Monitor asterisk

2010-08-18 Thread Shazaum
man, see monast http://monast.sourceforge.net/

--

Renato dos Santos
shazaum.wordpress.com



2010/8/17 Matt Riddell li...@venturevoip.com

 On 17/08/10 6:34 PM, Hans Witvliet wrote:
  On Mon, 2010-08-16 at 13:35 -0400, Jamie A. Stapleton wrote:
  Might be worth your time to check out:  http://www.humbuglabs.org/
 
 
  Though they write:
  ...
  insight into the enterprise’s telephony infrastructure. Utilizing a set
  of none-intrusive analytical technologies, Humbug is capable of
  interfacing directly with your PBX system, analyzing its traffic,
  plotting it and providing
  ...
 
  It looks (!) like an online-service.
  Who would give an outsider access to your phone-usage info?

 :) Take it you don't use Google Analytics, Facebook insights,
 Feedburner, Amazon EC3 etc etc.

 Sure you have to decide who you want to trust (personally I trust the
 humbuglabs guys) and what their level of protection is (are they looking
 after their own security), but it seems to be the way things are going
 at the mo.

 --
 Cheers,

 Matt Riddell
 ___

 http://www.venturevoip.com/news.php (Daily Asterisk News)
 http://www.venturevoip.com/exchange.php (Full ITSP Solution)
 http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer)

 --
 _
 -- 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 Context

2010-08-18 Thread Zeeshan Zakaria
Thanks for the details. I Agreed you know what you are doing. As for doing
it more elegantly, it is not possible to do a fruitful discussion without
knowing all the details of how your dialplan works, neither is this the goal
here. But I offer similar hosted PBX service, just use one context for all
the companies, use various logics in the dialplan to differentiate between
the tenants, their updates, new inserts etc., and never needed to do any
reload. I identify tenant by their account ids and one context works for
all. CDRs are perfectly fine, billing is even great and automated. If fact I
have developed/programmed three multi-tenant solutions for far, including
one for a busy client, and used the same logic. They all work perfectly
fine. That was why I wondered why you needed reloads. But you must be doing
something which genuinely requires a reload, not saying that you are not
doing it right.

Zeeshan A Zakaria

--
www.ilovetovoip.com

On 2010-08-18 6:49 AM, Ishfaq Malik i...@pack-net.co.uk wrote:

 Hi

I'll give you an example process flow

Our customer logs onto our VoIP Portal and orders a SIP Geographic number
Geo number is successfully ordered which inserts an entry into our
extensions table in MySQL DB in the default context which has a goto command
to a newly created specific context for handling the incoming on that
number.
The customer goes to the dial plan managing section of the portal and sets
the number to ring an extension of his followed by going to voicemail. In
the back end 2 new inserts are made into the extensions table for the newly
created context.
Also, an insert is made into a table to say that the extensions table has
been updated.

A cron runs and sees that the extensions table has been updated.
this gets a distinct list of contexts from the extensions table and writes
each one to a new extensions.con putting in the realtime switch for each
context.
The cron then executes a dialplan reload

If you can see a more elegant way of doing the above so that no intervention
is required by anyone other that the customer, please let me know as I'm
always willing to learn better ways of doing things.

Also, please bear in mind that we offer a hosted service for customers so we
have lots of different companies all working off the same server(s)

Ish



On 18/08/10 10:37, Zeeshan Zakaria wrote:

 So why you need a reload when you are using the real...

--
_
-- 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] Monitor asterisk

2010-08-18 Thread Zeeshan Zakaria
Look into astassisstant. I don't remember the website, but google will take
you their. It doesn't need any installations on the server, just a manager
user in manager.conf.

Zeeshan A Zakaria

--
www.ilovetovoip.com

On 2010-08-18 8:39 AM, Shazaum shaz...@gmail.com wrote:

man, see monast http://monast.sourceforge.net/

--

Renato dos Santos
shazaum.wordpress.com



2010/8/17 Matt Riddell li...@venturevoip.com



 On 17/08/10 6:34 PM, Hans Witvliet wrote:
  On Mon, 2010-08-16 at 13:35 -0400, Jamie A. Stapl...


--
_
-- 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] sending sms from Asterisk server

2010-08-18 Thread Tino
Hello Johann,

Thanks for your advice in this matter. But i am not sure how to pass the
numbers to be sent sms  in the dialplan.

On Wed, Aug 18, 2010 at 3:13 AM, Johann Hoehn johann.ho...@ecommerce.comwrote:

 On 08/17/2010 09:00 AM, Tino wrote:

 Hello,

 I would like to send sms to some external phone numbers from my asterisk
 server. Is it possible to send sms via softphones like X-Lite ? . Any tips
 regarding this will be helpful

 thanks


  This is easy to do by using email to SMS gateways.  A list of them is on
 wikipedia (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the
 Asterisk side, you have an extension that sends the email.  I personally use
 an AGI script for this part, but you could use a System() call as well.


 --johann

-- 
_
-- 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] Polycom 331 freezes connecting to FreePBX

2010-08-18 Thread Connor Spiess
On Tue, 2010-08-17 at 09:42 -1000, Ben Schorr wrote:
 Sorry, I should clarify - we have had a similar setup (IPSEC VPN, Polycom 
 331) working at a different location with a different handset for this same 
 firm.  We've never gotten the phone/VPN to work at this particular site.  I 
 was just trying to explain that it DOES appear to be successfully connecting 
 to the TFTP server that provisions the phones.  The TFTP server is sitting 
 right next to the Asterisk server so if it can connect to one it should be 
 able to connect to the other - basic connectivity, it appears, is working 
 between the sites.

 We currently have 57 other Polycom phones (most of them 331s)  working in 
 this system, with the current application, just fine, including maybe 10 that 
 connect over an IPSEC VPN from a 3rd location.

 That does give me an idea though...we could take the handset from the failing 
 location to the 3rd location (barely a mile away) and plug it in and see if 
 it works there.  If it does then the problem must be somewhere in the 
 connection and not with the handset itself.  If it doesn't work in the other 
 location either then the problem is probably with the phone and/or it's 
 configuration.

 Make sense?

 Ben M. Schorr
 Chief Executive Officer
 __
 Roland Schorr  Tower
 www.rolandschorr.com
 b...@rolandschorr.com


  -Original Message-
  From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-
  boun...@lists.digium.com] On Behalf Of David Backeberg
  Sent: Monday, August 16, 2010 11:04
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: Re: [asterisk-users] Polycom 331 freezes connecting to FreePBX
 
  On Mon, Aug 16, 2010 at 4:21 PM, Ben Schorr b...@rolandschorr.com wrote:
   We gave the phone a static IP address and pointed it to the
   configuration server on the remote end that has the CFG files for it.
   The phone starts up, downloads SIP and the new application and
   otherwise seems to be booting normally.  Then it gets to the LAN
   Properties screen that shows the phone's IP address, MAC address and
  firmware version and then...nothing.
   It just sits there frozen.
 
  I have a suggestion...
 
  Put back the 'old application', and determine whether the 'new application' 
  broke
  your phone boot. Since you don't mention changing anything else, survey 
  says it's
  probably the last thing you changed that broke things.
 
  --
Ben,

I have seen when trying to provision a Polycom phone over the WAN using
tftp the phone lock up. Usually this is cause the TFTP transfer is
crashing in the middle of one of the file transfers due the the nature
(UDP). What I did to fix was use ftp or http over the WAN (TCP) or fire
up a tftp server on the local LAN to do the initial provisioning of the
phone, then point it back to the provisioning server across the WAN.

Could be a problem with the link to. Never hurts to give it a try if you
have another office so close.

--Connor
  _
  
  -- 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


attachment: winmail.dat-- 
_
-- 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] Playing with sipvicious ..

2010-08-18 Thread Gordon Henderson

... using it as a tool and understanding what it does...

So one part of it's toolset identifys valid SIP accounts - and I was under 
the impression that alwaysauthreject=yes was supposed to stop this...

However, it sends a request for a highly probably non-existent account, 
then sends requests for probably existing accounts and I guess compares 
the results - account not found vs. bad username or password... It thus 
trivially, and very quickly finds valid accounts when fed with a list of 
accounts to try in the first place (e.g. 100-999, or 1000-, etc.)

I wonder if it's time to introduce yet another parameter  to it - which 
will cause asterisk to return the same error code for all 3 conditions - 
and return the not found error, even on bad username or password.

It breaks the RFC even more, but might it be worth it?

(I've just had 30GB of sipvicious traffic sent to my hosted servers in a 
12-hour period - it came from what looked like a VPS host in France - 
trivially firewalled out, but even dropping the packets didn't stop the 
flood! It's so badly written it appears to just ignore any return codes 
that it doesn't want, or even no returns at all!)

Gordon

-- 
_
-- 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] Fwd: AsteriskNow REGISTER'ing s@ extension for all inbound trunks

2010-08-18 Thread Joe Wood
Sending this to asterisk-users, in case anyone has AsteriskNOW
experience they can share.

Joe


-- Forwarded message --
From: Joe Wood sch...@gmail.com
Date: Wed, Aug 18, 2010 at 9:22 AM
Subject: AsteriskNow REGISTER'ing s@ extension for all inbound trunks
To: asterisk...@lists.digium.com


Hello.

Can someone tell me why AsteriskNow is reverting to registering s@ as
an extension?

18 Aug 00:01:09.301/GLOBAL/ser: RECEIVED message from 209.221.186.51:5060:
REGISTER sip:209.221.186.98 SIP/2.0
Via: SIP/2.0/UDP 209.221.186.51:5060;branch=z9hG4bK41fb6b8f;rport
Max-Forwards: 70
From: sip:2063161...@209.221.186.98;tag=as7608
To: sip:2063161...@209.221.186.98
Call-ID: 5ada9ee829ddb4d311c5cb092b8d3...@209.221.186.50
CSeq: 104 REGISTER
User-Agent: Asterisk PBX 1.6.2.11
Authorization: Digest username=2063161626,
realm=pugetsoundtelecom.net, algorithm=MD5,
uri=sip:209.221.186.98,
nonce=4c6b8544f41a0643a65f4e17199268a018b32070,
response=dcbb7adca43c6c7455c9942010c84423, qop=auth,
cnonce=45cc3d6b, nc=0002
Expires: 120
Contact: sip:s...@209.221.186.51
Content-Length: 0


18 Aug 00:01:09.301/5ada9ee829ddb4d311c5cb092b8d3...@209.221.186.50/ser:
processing REGISTER received from 209.221.186.51:5060
18 Aug 00:01:09.302/5ada9ee829ddb4d311c5cb092b8d3...@209.221.186.50/ser:
saving contact sip:s...@209.221.186.51 into the database
18 Aug 00:01:09.302/GLOBAL/ser: SENDING message to 209.221.186.51:5060:
SIP/2.0 200 OK
Via: SIP/2.0/UDP 209.221.186.51:5060;branch=z9hG4bK41fb6b8f;rport=5060
From: sip:2063161...@209.221.186.98;tag=as7608
To: sip:2063161...@209.221.186.98;tag=5fceb36a80dbc27aca680924f1b8b505-19ad
Call-ID: 5ada9ee829ddb4d311c5cb092b8d3...@209.221.186.50
CSeq: 104 REGISTER
Contact: sip:s...@209.221.186.51;expires=300
Server: Sippy Softswitch v2.0.80
Content-Length: 0

-- 
_
-- 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] Fwd: AsteriskNow REGISTER'ing s@ extension for allinbound trunks

2010-08-18 Thread Danny Nicholas
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Joe Wood
Subject: [asterisk-users] Fwd: AsteriskNow REGISTER'ing s@ extension for
allinbound trunks

snip

Since you can see the CLI log, please post your asterisk version (core show
version) so we can see what flavor of Asterisk your AN is operating under.


-- 
_
-- 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] sending sms from Asterisk server

2010-08-18 Thread Administrator TOOTAI
Le 18/08/2010 16:03, Tino a écrit :
 Hello Johann,

 Thanks for your advice in this matter. But i am not sure how to pass 
 the numbers to be sent sms  in the dialplan.
agi(script,param1,param2,...,paramX) from your dialplan where script 
lies in /var/lib/asterisk/agi-bin

 On Wed, Aug 18, 2010 at 3:13 AM, Johann Hoehn 
 johann.ho...@ecommerce.com mailto:johann.ho...@ecommerce.com wrote:

 On 08/17/2010 09:00 AM, Tino wrote:

 Hello,

 I would like to send sms to some external phone numbers from
 my asterisk server. Is it possible to send sms via softphones
 like X-Lite ? . Any tips regarding this will be helpful

 thanks


 This is easy to do by using email to SMS gateways.  A list of them
 is on wikipedia
 (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the
 Asterisk side, you have an extension that sends the email.  I
 personally use an AGI script for this part, but you could use a
 System() call as well.

-- 
Daniel

-- 
_
-- 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] WaitExten() always times out

2010-08-18 Thread Kathryn Jones
Hi,

My WaitExten() is not working as I expect it to. This is the relevant part
of my context. It is meant to receive incoming calls.

[incoming]
exten = xxx,1,Background(hello-world)
exten = xxx,2,WaitExten(7)

exten = _X,1,AGI(myAGI.php)

When I send the call from a .call, it works perfect, but when receiving an
incoming call WaitExten() times out no matter what.

[general]
static=yes
writeprotect=yes
autofallthrough=yes
clearglobalvars=no

I experimented changing autofallthrough to no and got the same result. Any
ideas about this strange behavior?
-- 
_
-- 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] IAX2 debug of registration - Only getting RX and there is no TX response from Asterisk - is that normal?

2010-08-18 Thread bruce bruce
That is set and here is what I get:

Rx-Frame Retry[ No] -- OSeqno: 000 ISeqno: 000 Type: IAX Subclass:
REGREQ
   Timestamp: 3ms  SCall: 01217  DCall: 0 [44.55.66.77:4569]
   USERNAME: 9988
   REFRESH : 60

Rx-Frame Retry[ No] -- OSeqno: 001 ISeqno: 001 Type: IAX Subclass: ACK

   Timestamp: 3ms  SCall: 01217  DCall: 1 [44.55.66.77:4569]

Any other suggestions. Anyone with a working pfsense configuration that can
share with me?

Thanks,
Bruce


On Wed, Aug 18, 2010 at 3:42 AM, Nasir Iqbal na...@ictinnovations.comwrote:

 Hi,

 Use requirecalltoken=no in your peer configuration

 Regards

 On Wed, Aug 11, 2010 at 4:28 AM, bruce bruce bruceb...@gmail.com wrote:

 Hello Everyone,

 I am trying to diagnose issue with my IAX2 extension not working.

 When I have iax2 set debug on all I see is this:

 *Rx-Frame Retry[ No] -- OSeqno: 000 ISeqno: 000 Type: IAX Subclass:
 REGREQ *
 *   Timestamp: 3ms  SCall: 00130  DCall: 0 [64.229.229.111:64823]
 *
 *   USERNAME: 100*
 *   REFRESH : 60*
  *
 *
 *Rx-Frame Retry[ No] -- OSeqno: 001 ISeqno: 001 Type: IAX Subclass:
 ACK*
 *   Timestamp: 3ms  SCall: 00130  DCall: 1 [64.229.229.111:64823]
 *


 So, all the packets are coming in, but there is no Tx response. Is that
 normal and is that how IAX2 works according to RFC to not respond back?

 I have checked my firewall and all is set fine. I have any WAN address to
 come in through port 4569 to map to the server and it worked last week but
 now it doesn't.

 Any suggestions?

 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




 --
 Nasir Iqbal

 ICT Innovations
 http://www.ictinnovations.com/


 --
 _
 -- 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] sending sms from Asterisk server

2010-08-18 Thread Steve Edwards

Un-top-posting...


On 08/17/2010 09:00 AM, Tino wrote:

I would like to send sms to some external phone numbers from my asterisk 
server. Is it possible to send sms via softphones like X-Lite ? . Any 
tips regarding this will be helpful


On Wed, Aug 18, 2010 at 3:13 AM, Johann Hoehn 
johann.ho...@ecommerce.com wrote:


This is easy to do by using email to SMS gateways.  A list of them is on 
wikipedia (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the 
Asterisk side, you have an extension that sends the email.  I personally 
use an AGI script for this part, but you could use a System() call as 
well.


Using system() is almost always a hack -- and not the good kind :)

On Wed, 18 Aug 2010, Tino wrote:

Thanks for your advice in this matter. But i am not sure how to pass the 
numbers to be sent sms  in the dialplan.


You have a choice: you can pass them as channel variables or as command 
line options. I use both, frequently in the same program. Unfortunately, I 
can't clearly articulate why I use one over the other. If the variable is 
something that exists for the life of the call like ${CLIENT-ID} I tend to 
access it as a channel variable. If it's something that modifies the 
behavior of the AGI (--debug or --verbose) I always pass it as a command 
line option and use getopt_long()


First, you need to pick a language. If this is a SOHOish hobby project, it 
doesn't matter -- pick a language you are comfortable with.


If this is a high volume, performance critical project -- I'd vote for c.

Once you've decided on a language, search out an established AGI library 
and learn a bit about the protocol. It's very simple but not always 
obvious. The 3 biggest stumbling blocks that trip up programmers are:


1) You have to read the AGI environment before anything else.

2) It's a request followed by a response. If you don't read the response, 
bad things will happen.


3) It's STDIN/STDOUT based. If you try to debug by writing variables or 
messages using echo/printf/puts/etc, bad things will happen.


Check out voip-info.org for more information on AGI.

--
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

[asterisk-users] WaitExten() always times out

2010-08-18 Thread Kathryn Jones
Hi,

My WaitExten() is not working as I expect it to. This is the relevant part
of my context. It is meant to receive incoming calls.

[incoming]
exten = xxx,1,Background(hello-world)
exten = xxx,2,WaitExten(7)

exten = _X,1,AGI(myAGI.php)

When I send the call from a .call, it works perfect, but when receiving an
incoming call WaitExten() times out no matter what.

[general]
static=yes
writeprotect=yes
autofallthrough=yes
clearglobalvars=no

I experimented changing autofallthrough to no and got the same result. Any
ideas about this strange behavior?
-- 
_
-- 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] WaitExten() always times out

2010-08-18 Thread Danny Nicholas
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Kathryn Jones
Subject: [asterisk-users] WaitExten() always times out

 

Hi,

My WaitExten() is not working as I expect it to. This is the relevant part
of my context. It is meant to receive incoming calls.

[incoming]
exten = xxx,1,Background(hello-world)
exten = xxx,2,WaitExten(7)

exten = _X,1,AGI(myAGI.php)

When I send the call from a .call, it works perfect, but when receiving an
incoming call WaitExten() times out no matter what.
snip
I experimented changing autofallthrough to no and got the same result. Any
ideas about this strange behavior? 

 

My best guess is that your problem is that _X isn't happy for whatever
reason.  Generally I use Waitexten for single digit processing like this

Exten = 1234,1,goto(waitdtmf,s,1)

 

[waitdtmf]

Exten = s,1,background(hello-world)

Exten = s,n,waitexten(7)

Exten = 1,1,AGI(myAGI.php)

Exten = 2,1,AGI(myAGI.php)

Exten = I,1,playback(invalid)

-- 
_
-- 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] Fwd: AsteriskNow REGISTER'ing s@ extension for allinbound trunks

2010-08-18 Thread Joe Wood
sg01*CLI core show version
Asterisk 1.6.2.11 built by root @ localhost.localdomain on a i686
running Linux on 2010-08-16 15:17:26 UTC

On Wed, Aug 18, 2010 at 10:19 AM, Danny Nicholas da...@debsinc.com wrote:
 From: asterisk-users-boun...@lists.digium.com
 [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Joe Wood
 Subject: [asterisk-users] Fwd: AsteriskNow REGISTER'ing s@ extension for
 allinbound trunks

 snip

 Since you can see the CLI log, please post your asterisk version (core show
 version) so we can see what flavor of Asterisk your AN is operating under.


 --
 _
 -- 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] WaitExten() always times out

2010-08-18 Thread Kathryn Jones
Thanks for you reply :).

I thought of that and tried replacing _X with a numbers it should match (9),
and it didn't work. It still times out as if no number was entered.




On Wed, Aug 18, 2010 at 2:11 PM, Danny Nicholas da...@debsinc.com wrote:

   *From:* asterisk-users-boun...@lists.digium.com [mailto:
 asterisk-users-boun...@lists.digium.com] *On Behalf Of *Kathryn Jones
 *Subject:* [asterisk-users] WaitExten() always times out



 Hi,

 My WaitExten() is not working as I expect it to. This is the relevant
 part of my context. It is meant to receive incoming calls.

 [incoming]
 exten = xxx,1,Background(hello-world)
 exten = xxx,2,WaitExten(7)

 exten = _X,1,AGI(myAGI.php)

 When I send the call from a .call, it works perfect, but when receiving
 an incoming call WaitExten() times out no matter what.
 snip

 I experimented changing autofallthrough to no and got the same result.
 Any ideas about this strange behavior?



 My best guess is that your problem is that _X isn’t happy for whatever
 reason.  Generally I use Waitexten for single digit processing like this

 Exten = 1234,1,goto(waitdtmf,s,1)



 [waitdtmf]

 Exten = s,1,background(hello-world)

 Exten = s,n,waitexten(7)

 Exten = 1,1,AGI(myAGI.php)

 Exten = 2,1,AGI(myAGI.php)

 Exten = I,1,playback(invalid)

 --
 _
 -- 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] WaitExten() always times out

2010-08-18 Thread Danny Nicholas
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Kathryn Jones
Subject: Re: [asterisk-users] WaitExten() always times out

 

Thanks for you reply :).

I thought of that and tried replacing _X with a numbers it should match
(9), and it didn't work. It still times out as if no number was entered.



When you do the .call,  it is probably on a local, SIP or IAX channel.  When
you hit the incoming, are you on a DAHDI channel?

Also, a workaround would be to do 

Exten = t,1,AGI(myagi.php) 

So when the DTMF doesn't work it just drops through anyway.






 

-- 
_
-- 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] CDR variables

2010-08-18 Thread Tiago Geada
Hello list!

I am trying to get hold of ${CDR(duration)} and ${CDR(billsec)} variables in
h

It seems that these variables always return 0. I am using  Asterisk version
1.6.2.11. Can't I get these values other than using CDR reccords ??
-- 
_
-- 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] WaitExten() always times out

2010-08-18 Thread Kathryn Jones
My .call file goes out to a pstn number.

That work around would be perfect :D, but I need the number given by the
caller.

On Wed, Aug 18, 2010 at 2:49 PM, Danny Nicholas da...@debsinc.com wrote:

   *From:* asterisk-users-boun...@lists.digium.com [mailto:
 asterisk-users-boun...@lists.digium.com] *On Behalf Of *Kathryn Jones
 *Subject:* Re: [asterisk-users] WaitExten() always times out



 Thanks for you reply :).

 I thought of that and tried replacing _X with a numbers it should match
 (9), and it didn't work. It still times out as if no number was entered.

  When you do the .call,  it is probably on a local, SIP or IAX channel.
 When you hit the incoming, are you on a DAHDI channel?

 Also, a workaround would be to do

 Exten = t,1,AGI(myagi.php)

 So when the DTMF doesn’t work it just drops through anyway.






 --
 _
 -- 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] WaitExten() always times out

2010-08-18 Thread Miguel Molina

Hi,

Are you sure asterisk is receiving and processing DMTF correctly? Are 
you using rfc2833, SIP INFO or inband DMTF? What is your asterisk 
version? I use WaitExten(5) all the time, no matter if they are 
single-digit or multiple-digit extensions.


Regards,

--
Ing. Miguel Molina
Grupo de Tecnología
Millenium Phone Center
PBX: (+57 1)6500800 ext. 1201
Fax: (+57 1)6500816
Móvil: (+57)3138873587


El 18/08/10 15:39, Kathryn Jones escribió:

Thanks for you reply :).

I thought of that and tried replacing _X with a numbers it should 
match (9), and it didn't work. It still times out as if no number was 
entered.





On Wed, Aug 18, 2010 at 2:11 PM, Danny Nicholas da...@debsinc.com 
mailto:da...@debsinc.com wrote:


*From:* asterisk-users-boun...@lists.digium.com
mailto:asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com
mailto:asterisk-users-boun...@lists.digium.com] *On Behalf Of
*Kathryn Jones
*Subject:* [asterisk-users] WaitExten() always times out

Hi,

My WaitExten() is not working as I expect it to. This is the
relevant part of my context. It is meant to receive incoming calls.

[incoming]
exten = xxx,1,Background(hello-world)
exten = xxx,2,WaitExten(7)

exten = _X,1,AGI(myAGI.php)

When I send the call from a .call, it works perfect, but when
receiving an incoming call WaitExten() times out no matter what.
snip

I experimented changing autofallthrough to no and got the same
result. Any ideas about this strange behavior?

My best guess is that your problem is that _X isn’t happy for
whatever reason.  Generally I use Waitexten for single digit
processing like this

Exten = 1234,1,goto(waitdtmf,s,1)

[waitdtmf]

Exten = s,1,background(hello-world)

Exten = s,n,waitexten(7)

Exten = 1,1,AGI(myAGI.php)

Exten = 2,1,AGI(myAGI.php)

Exten = I,1,playback(invalid)


--
_
-- 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] MySQL Connect problem...

2010-08-18 Thread Geraint Lee
This is what I ended up doing, working fine now.

Cheers

On 18 August 2010 08:52, Nasir Iqbal na...@ictinnovations.com wrote:

 Avoid to use MySQL dialplan application, instead write an AGI script for
 this purpose

 On Tue, Aug 17, 2010 at 4:59 PM, Geraint Lee gera...@gmail.com wrote:

 Right, I'm baffled.

 I have:
 exten = s,1,MYSQL(Connect DB1 127.0.0.1 geraint xxx amis2)
 exten = s,n,MYSQL(Query NORESULT ${DB1} INSERT\ INTO\ recordings\
 (caller_number\,called_number\,date_created\,date_started\,in_use\,server_id)\
 VALUES\ (\'${CALLERID(number)}\'\,\'${ARG1}\'\,NOW()\,NOW()\,\'Yes\'\,12))
 exten = s,n,MYSQL(Query RESULT1 ${DB1} SELECT\ LAST_INSERT_ID())
 exten = s,n,MYSQL(Fetch FOUND1 ${RESULT1} VALUE1)
 exten = s,n,MYSQL(Clear ${RESULT1})
 exten = s,n,MYSQL(Disconnect ${DB1})
 exten = s,n,MixMonitor(${VALUE1}.wav)
 exten = s,n,Set(CALLERID(all)=xxx)
 exten = s,n,Dial(SIP/prov1/${ARG1})

 in a macro to dial numbers...

 Every few hours or so every call hangs on the s,1 MYSQL(Connect) and won't
 work until i restart asterisk.

 The mysql server has a maximum connections of 2048 (of which around 90 are
 in use) so it's not a mysql connection limit problem from what i can tell
 since while asterisk is stuck i can still log in to mysql just fine, as
 can the web server.

 Does anyone have any suggestions what could be causing asterisk to get
 stuck here? i don't see anything in cli and core show channels just shows
 everyone stuck in state ring on the connect string with no errors.

 Cheers

 Geraint

 --

 _
 -- 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




 --
 Nasir Iqbal

 ICT Innovations
 http://www.ictinnovations.com/


 --
 _
 -- 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] WaitExten() always times out

2010-08-18 Thread Danny Nicholas
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Kathryn Jones
Subject: Re: [asterisk-users] WaitExten() always times out

My .call file goes out to a pstn number.

That work around would be perfect :D, but I need the number given by the
caller.

My bet is that the pstn/DAHDI delay is eating part of your message (it takes
3-7 seconds from Dial to actually connect).  Try putting a wait(5) in front
of the Background command.

-- 
_
-- 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] CDR variables

2010-08-18 Thread Danny Nicholas
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Tiago Geada
Subject: [asterisk-users] CDR variables

 

Hello list!

I am trying to get hold of ${CDR(duration)} and ${CDR(billsec)} variables
in h

It seems that these variables always return 0. I am using  Asterisk version
1.6.2.11. Can't I get these values other than using CDR reccords ??

 

In cdr.conf, is endbeforehexten=yes ?

-- 
_
-- 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] WaitExten() always times out

2010-08-18 Thread Kathryn Jones
I must not be receiving them properly, since I can't make it work. I just
can't see why :P.

My asterisk version is 1.6.2.6. Like I said before, for outgoing .call files
WaitExten works fine, it's on incoming calls that I cannot receive the
number I need.

I had not checked my dtmf mode, this is new to me. So I was using asterisk
default rfc2833. I am making pstn calls from regular telephones, through
asterisk. What dtmfmode should I use? Could that be my problem?


On Wed, Aug 18, 2010 at 2:57 PM, Miguel Molina mmol...@millenium.com.cowrote:

  Hi,

 Are you sure asterisk is receiving and processing DMTF correctly? Are you
 using rfc2833, SIP INFO or inband DMTF? What is your asterisk version? I use
 WaitExten(5) all the time, no matter if they are single-digit or
 multiple-digit extensions.

 Regards,

 --
 Ing. Miguel Molina
 Grupo de Tecnología
 Millenium Phone Center
 PBX: (+57 1)6500800 ext. 1201
 Fax: (+57 1)6500816
 Móvil: (+57)3138873587


 El 18/08/10 15:39, Kathryn Jones escribió:

 Thanks for you reply :).

 I thought of that and tried replacing _X with a numbers it should match
 (9), and it didn't work. It still times out as if no number was entered.




 On Wed, Aug 18, 2010 at 2:11 PM, Danny Nicholas da...@debsinc.com wrote:

   *From:* asterisk-users-boun...@lists.digium.com [mailto:
 asterisk-users-boun...@lists.digium.com] *On Behalf Of *Kathryn Jones
 *Subject:* [asterisk-users] WaitExten() always times out


 Hi,

 My WaitExten() is not working as I expect it to. This is the relevant
 part of my context. It is meant to receive incoming calls.

 [incoming]
 exten = xxx,1,Background(hello-world)
 exten = xxx,2,WaitExten(7)

 exten = _X,1,AGI(myAGI.php)

 When I send the call from a .call, it works perfect, but when receiving
 an incoming call WaitExten() times out no matter what.
  snip

 I experimented changing autofallthrough to no and got the same result.
 Any ideas about this strange behavior?



 My best guess is that your problem is that _X isn’t happy for whatever
 reason.  Generally I use Waitexten for single digit processing like this

 Exten = 1234,1,goto(waitdtmf,s,1)



 [waitdtmf]

 Exten = s,1,background(hello-world)

 Exten = s,n,waitexten(7)

 Exten = 1,1,AGI(myAGI.php)

 Exten = 2,1,AGI(myAGI.php)

 Exten = I,1,playback(invalid)

 --
 _
 -- 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

-- 
_
-- 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 Context

2010-08-18 Thread Matt Riddell
We don't use a context for that.

We set up dialplan code in a non asterisk part of MySQL called routing 
types.

When a customer selects a DDI number they can choose a routing type to 
use with it.

These routing types allow for variable substitution - i.e. if someone 
adds the routing type Direct Routing With Failover, there is a 
variable with this type called failover routing.

The call is then sent to their SIP or IAX2 device (if not on the same 
machine that has the DDI number it uses DUNDI to find the appropriate 
machine).  If somebody is unavailable on all machines, it sets the 
account code to the customer and goes to the outbound context for dialling.

The difference is that in the routing type we don't use extensions (just 
applications).

When someone adds the routing type to their DDI realtime extensions are 
created with extension 5551234 (or whatever their DDI number is) and 
priorities which increase.  It makes some things a bit harder, but you 
can always use labels and the read application.

-- 
Cheers,

Matt Riddell
___

http://www.venturevoip.com/news.php (Daily Asterisk News)
http://www.venturevoip.com/exchange.php (Full ITSP Solution)
http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer)

-- 
_
-- 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 Context

2010-08-18 Thread Zeeshan Zakaria
Hi Matt,

That's somewhat closer to what I do in my dialplan as well. But Dan
apparantly wants to add new contexts in his `extensions` table.

Zeeshan A Zakaria

--
www.ilovetovoip.com

On 2010-08-18 6:02 PM, Matt Riddell li...@venturevoip.com wrote:

We don't use a context for that.

We set up dialplan code in a non asterisk part of MySQL called routing
types.

When a customer selects a DDI number they can choose a routing type to
use with it.

These routing types allow for variable substitution - i.e. if someone
adds the routing type Direct Routing With Failover, there is a
variable with this type called failover routing.

The call is then sent to their SIP or IAX2 device (if not on the same
machine that has the DDI number it uses DUNDI to find the appropriate
machine).  If somebody is unavailable on all machines, it sets the
account code to the customer and goes to the outbound context for dialling.

The difference is that in the routing type we don't use extensions (just
applications).

When someone adds the routing type to their DDI realtime extensions are
created with extension 5551234 (or whatever their DDI number is) and
priorities which increase.  It makes some things a bit harder, but you
can always use labels and the read application.

--
Cheers,

Matt Riddell
___

http://www.venturevoip.com/news.php (Daily Asterisk News)
http://www.venturevoip.com/exchange.php (Full ITSP Solution)
http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer)

--

_
-- Bandwidth and Colocation Pr...
-- 
_
-- 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] IXJ issues on 1.4.35

2010-08-18 Thread Infra

My thanks for previous help on fixing IXJ issues in 1.2.40; I now
have problems with a just-built 1.4.35 on the same host:

[Aug 18 17:26:48] WARNING[27209]: app_dial.c:1298 dial_exec_full: Unable
to create channel of type 'Phone' (cause 0 - Unknown)
  == Everyone is busy/congested at this time (1:0/0/1)

O/S: Linux 2.4.27; IXJ driver for Linux Rev. 3.5, gcc 3.01

I applied the patch for dialtone as per my issue on 1.2.40.

Build log contains no warnings for chan_phone.

Build tested using install to DESTDIR=/tmp/asterisk; make samples;
edited 'extensions.conf' to uncomment extension '1265' (Phone/phone0);
added skinny extension to test Cisco 7920 (which worked except for
audio stalling):

exten = 1266,1,Dial(Skinny/1...@7920-1)
exten = 1266,n,Goto(s,5)

Asterisk started with -vvv -C /tmp/asterisk/etc/asterisk/asterisk.conf
and controlled from 'asterisk -r'

What other debugging should I enable?

Again, all help is much appreciated.

Michael



-- 
_
-- 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] IXJ issues on 1.4.35

2010-08-18 Thread Infra
On Wed, 18 Aug 2010, Infra wrote:


 My thanks for previous help on fixing IXJ issues in 1.2.40; I now
 have problems with a just-built 1.4.35 on the same host:

 [Aug 18 17:26:48] WARNING[27209]: app_dial.c:1298 dial_exec_full: Unable
 to create channel of type 'Phone' (cause 0 - Unknown)
   == Everyone is busy/congested at this time (1:0/0/1)

 O/S: Linux 2.4.27; IXJ driver for Linux Rev. 3.5, gcc 3.01

 I applied the patch for dialtone as per my issue on 1.2.40.

 Build log contains no warnings for chan_phone.

 Build tested using install to DESTDIR=/tmp/asterisk; make samples;
 edited 'extensions.conf' to uncomment extension '1265' (Phone/phone0);
 added skinny extension to test Cisco 7920 (which worked except for
 audio stalling):

 exten = 1266,1,Dial(Skinny/1...@7920-1)
 exten = 1266,n,Goto(s,5)

 Asterisk started with -vvv -C /tmp/asterisk/etc/asterisk/asterisk.conf
 and controlled from 'asterisk -r'

 What other debugging should I enable?

 Again, all help is much appreciated.


Jumpped the gun -- I didn't finish editing the sample 'phone.conf' file;
the fxs line is now working, but without dialtone.  I will revert to the
unpatched version of chan_phone.c and test again.


-- 
_
-- 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] IXJ issues on 1.4.35

2010-08-18 Thread Infra
On Wed, 18 Aug 2010, Infra wrote:

 On Wed, 18 Aug 2010, Infra wrote:

 
  My thanks for previous help on fixing IXJ issues in 1.2.40; I now
  have problems with a just-built 1.4.35 on the same host:

snip

 
  I applied the patch for dialtone as per my issue on 1.2.40.

snip

 the fxs line is now working, but without dialtone.  I will revert to the
 unpatched version of chan_phone.c and test again.

No dialtone with the unpatched version.

-- 
_
-- 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] sending sms from Asterisk server

2010-08-18 Thread Tiago Geada
I would rather use .call files. So easy to produce a text file...

On 18 August 2010 21:02, Steve Edwards asterisk@sedwards.com wrote:

 Un-top-posting...

  On 08/17/2010 09:00 AM, Tino wrote:

 I would like to send sms to some external phone numbers from my asterisk
 server. Is it possible to send sms via softphones like X-Lite ? . Any tips
 regarding this will be helpful


  On Wed, Aug 18, 2010 at 3:13 AM, Johann Hoehn johann.ho...@ecommerce.com
 wrote:


  This is easy to do by using email to SMS gateways.  A list of them is on
 wikipedia (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the
 Asterisk side, you have an extension that sends the email.  I personally use
 an AGI script for this part, but you could use a System() call as well.


 Using system() is almost always a hack -- and not the good kind :)


 On Wed, 18 Aug 2010, Tino wrote:

  Thanks for your advice in this matter. But i am not sure how to pass the
 numbers to be sent sms  in the dialplan.


 You have a choice: you can pass them as channel variables or as command
 line options. I use both, frequently in the same program. Unfortunately, I
 can't clearly articulate why I use one over the other. If the variable is
 something that exists for the life of the call like ${CLIENT-ID} I tend to
 access it as a channel variable. If it's something that modifies the
 behavior of the AGI (--debug or --verbose) I always pass it as a command
 line option and use getopt_long()

 First, you need to pick a language. If this is a SOHOish hobby project, it
 doesn't matter -- pick a language you are comfortable with.

 If this is a high volume, performance critical project -- I'd vote for c.

 Once you've decided on a language, search out an established AGI library
 and learn a bit about the protocol. It's very simple but not always obvious.
 The 3 biggest stumbling blocks that trip up programmers are:

 1) You have to read the AGI environment before anything else.

 2) It's a request followed by a response. If you don't read the response,
 bad things will happen.

 3) It's STDIN/STDOUT based. If you try to debug by writing variables or
 messages using echo/printf/puts/etc, bad things will happen.

 Check out voip-info.org for more information on AGI.

 --
 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

-- 
_
-- 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] channel variables in AGI

2010-08-18 Thread Anthony Messina
On Wednesday, August 11, 2010 11:08:37 am Tino wrote:
 #!/bin/bash -x
 T=$agi_uniqueid
 
 I want to save value of 'agi_uniqueid' channel variable into a variable
 called 'T' in my script

When executing and AGI from the dialplan, it will dump out it's variables 
immediately, so you need to tell Bash to read them in and write them to 
whatever variables you want.  For example, see:
http://messinet.com/trac/asterisk-fax-gw/browser/fax-gw.agi#L622

Here, I set the variable name from Asterisk to the variable value from 
Asterisk.

So I end up with:

agi_uniqueid=123456... (or whatever the uniqueid was)

Then I could go on to say
T=$agi_uniqueid

-- 
Anthony - http://messinet.com - http://messinet.com/~amessina/gallery
8F89 5E72 8DF0 BCF0 10BE 9967 92DC 35DC B001 4A4E


signature.asc
Description: This is a digitally signed message part.
-- 
_
-- 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] sending sms from Asterisk server

2010-08-18 Thread Anton Raharja
On 08/19/2010 08:21 AM, Tiago Geada wrote:
 I would rather use .call files. So easy to produce a text file...

 On 18 August 2010 21:02, Steve Edwards asterisk.org
 http://asterisk.org@sedwards.com http://sedwards.com wrote:

 Un-top-posting...

 On 08/17/2010 09:00 AM, Tino wrote:

 I would like to send sms to some external phone numbers from
 my asterisk server. Is it possible to send sms via softphones
 like X-Lite ? . Any tips regarding this will be helpful


 On Wed, Aug 18, 2010 at 3:13 AM, Johann Hoehn
 johann.ho...@ecommerce.com
 mailto:johann.ho...@ecommerce.com wrote:


 This is easy to do by using email to SMS gateways.  A list of
 them is on wikipedia
 (http://en.wikipedia.org/wiki/List_of_SMS_gateways).  For the
 Asterisk side, you have an extension that sends the email.  I
 personally use an AGI script for this part, but you could use
 a System() call as well.


 Using system() is almost always a hack -- and not the good kind :)


 On Wed, 18 Aug 2010, Tino wrote:

 Thanks for your advice in this matter. But i am not sure how
 to pass the numbers to be sent sms  in the dialplan.


 You have a choice: you can pass them as channel variables or as
 command line options. I use both, frequently in the same program.
 Unfortunately, I can't clearly articulate why I use one over the
 other. If the variable is something that exists for the life of
 the call like ${CLIENT-ID} I tend to access it as a channel
 variable. If it's something that modifies the behavior of the AGI
 (--debug or --verbose) I always pass it as a command line option
 and use getopt_long()

 First, you need to pick a language. If this is a SOHOish hobby
 project, it doesn't matter -- pick a language you are comfortable
 with.

 If this is a high volume, performance critical project -- I'd vote
 for c.

 Once you've decided on a language, search out an established AGI
 library and learn a bit about the protocol. It's very simple but
 not always obvious. The 3 biggest stumbling blocks that trip up
 programmers are:

 1) You have to read the AGI environment before anything else.

 2) It's a request followed by a response. If you don't read the
 response, bad things will happen.

 3) It's STDIN/STDOUT based. If you try to debug by writing
 variables or messages using echo/printf/puts/etc, bad things will
 happen.

 Check out voip-info.org http://voip-info.org for more
 information on AGI.



Hi,

how do you get the text to send?
text that is sent from X-Lite for example.

thx,
anton


-- 
_
-- 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