[asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Kingsley Tart
kingsley at skymarket.co.uk
Wed May 12 05:36:05 CDT 2010
Hi,
I still think we've either got a bug in Asterisk or a bug in the
Asterisk::AGI module.
In a separate part of the dialplan we have a call to a (much simpler)
script that begins with the below code.
In the last 1000 calls, I've had a couple of "extension not returned by
AGI" errors from the script.
Prior to upgrading from Asterisk 1.4.23 we never saw this error in over
10 million calls.
Unless we're doing something obviously wrong here, it would seem that
there's either a bug somewhere in Asterisk or that the Asterisk Perl
modules we have are somehow incompatible with the version of Asterisk
we're now running. $Asterisk::AGI::VERSION returns 1.01 in our
installation.
Any ideas?
#!/usr/bin/perl -w
use strict;
use Asterisk::AGI;
our $AGI = new Asterisk::AGI;
my $cwd = '/var/lib/asterisk/agi-bin';
our $gatewayID;
open(STDERR,">>/var/log/agi_$application.err") or die "Failed to redirect STDERR";
eval
{
my $settings = require "$cwd/gw_settings.pl" || die "Cannot load settings from $cwd/gw_settings.pl";
$gatewayID = $settings->{'gatewayID'};
my %input = ($AGI->ReadParse());
my $dni = $input{'extension'} || die 'extension not returned by AGI';
...
--
Cheers,
Kingsley.
More information about the asterisk-users
mailing list