Sponsor: VoiceMeUp - Corporate & Wholesale VoIP Services

VoIP Mailing List Archives
Mailing list archives for the VoIP community
 SearchSearch 

[asterisk-users] Better info on call failure


 
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> Asterisk Users
View previous topic :: View next topic  
Author Message
nick at flhsi.com
Guest





PostPosted: Wed Aug 13, 2014 8:31 am    Post subject: [asterisk-users] Better info on call failure Reply with quote

Hey everyone,

Currently, I've got a PBX that is emailing me on call failures to an international SIP provider of ours.

I'm doing this with exten => 1,1,System(mail -s "Call from ${CALLERID(num)} to ${DNID} Failed with DialStatus ${DIALSTATUS}" nick@flhsi.com < /dev/null)

This works fine, However it's a little lacking. For Instance,

Our INTL SIP provider will bounce back SIP status messages if the call is rejected. 503 Service unavailable. 6XX over rate limit. 6XX blocked destination..etc. Anyone have any ideas about how I might capture that and include it in my email. Right now they just all bounce CHANUNAVAIL which is expected.

Thanks!

Nick Olsen Network Operations (855) FLSPEED x106
Back to top
kevin.larsen at pionee...
Guest





PostPosted: Wed Aug 13, 2014 8:40 am    Post subject: [asterisk-users] Better info on call failure Reply with quote

asterisk-users-bounces@lists.digium.com wrote on 08/13/2014 08:31:01 AM:

Quote:
From: "Nick Olsen" <nick@flhsi.com>
To: <asterisk-users@lists.digium.com>,
Date: 08/13/2014 08:31 AM
Subject: [asterisk-users] Better info on call failure
Sent by: asterisk-users-bounces@lists.digium.com

Hey everyone,

Currently, I've got a PBX that is emailing me on call failures to an
international SIP provider of ours.

I'm doing this with exten => 1,1,System(mail -s "Call from $
{CALLERID(num)} to ${DNID} Failed with DialStatus ${DIALSTATUS}"
nick@flhsi.com < /dev/null)

This works fine, However it's a little lacking. For Instance,

Our INTL SIP provider will bounce back SIP status messages if the
call is rejected. 503 Service unavailable. 6XX over rate limit. 6XX
blocked destination..etc. Anyone have any ideas about how I might
capture that and include it in my email. Right now they just all
bounce CHANUNAVAIL which is expected.

Thanks!

You could write a shell script that handles the actual mailing and pass in the information as arguments when calling the shell script.

exten => 1,1,System(/opt/scripts/asterisk/send-error-email.sh ${CALLERID(num)} ${DNID} ${DIALSTATUS} ${HANGUPCAUSE})

In this fashion you could also have a body in your message that contains all the extra information. This would work for basically any variable you wanted to pull in from Asterisk.
Back to top
jcolp at digium.com
Guest





PostPosted: Wed Aug 13, 2014 8:42 am    Post subject: [asterisk-users] Better info on call failure Reply with quote

Nick Olsen wrote:
Quote:
Hey everyone,
Currently, I've got a PBX that is emailing me on call failures to an
international SIP provider of ours.
I'm doing this with exten => 1,1,System(mail -s "Call from
${CALLERID(num)} to ${DNID} Failed with DialStatus ${DIALSTATUS}"
nick@flhsi.com < /dev/null)
This works fine, However it's a little lacking. For Instance,
Our INTL SIP provider will bounce back SIP status messages if the call
is rejected. 503 Service unavailable. 6XX over rate limit. 6XX blocked
destination..etc. Anyone have any ideas about how I might capture that
and include it in my email. Right now they just all bounce CHANUNAVAIL
which is expected.

If you are using Asterisk 11 or above you can use the hangup causes
functionality[1] to get more detail including the protocol specific reason.

Cheers,

[1] https://wiki.asterisk.org/wiki/display/AST/Hangup+Cause

--
Joshua Colp
Digium, Inc. | Senior Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
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
Back to top
Display posts from previous:   
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> Asterisk Users All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

VoiceMeUp - Corporate & Wholesale VoIP Services