[Home]

Summary:ASTERISK-10041: AGI timing affect pass-through faxing
Reporter:Marek Cervenka (cervajs)Labels:
Date Opened:2007-08-08 03:12:51Date Closed:2007-12-05 10:50:02.000-0600
Priority:BlockerRegression?No
Status:Closed/CompleteComponents:Resources/res_agi
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:with this scenario
patton SN4960 - asterisk1 1.2.22 - sip - asterisk2 1.4.10(xen virtual) - linksys ATA (standard asterisk dial command)

i can make pass-through faxing (G711 Alaw)

with AGI script i CANNOT send faxes (comm error)

if i downgrade asterisk2 to asterisk1.2.22, faxing from AGI works
sip accounts are the same

****** ADDITIONAL INFORMATION ******

simple testing AGI skript

#!/usr/bin/php -q
<?php
 set_time_limit(30);
 require('phpagi.php');
 error_reporting(E_ALL);

 $agi = new AGI();
 $agi->answer();

 $dialstr = "SIP/asterisk1/111111111|300|HgL(610000:61000)";

 $myres = $agi->exec("DIAL $dialstr");


 $agi->hangup();
?>
Comments:By: Jason Parker (jparker) 2007-08-08 10:24:08

I wouldn't expect this scenario to work - regardless of the usage of AGI.

FAX over VoIP has never been reliable - and I doubt many people would recommend it.

I would suggest immensely simplifying your setup.

By: Marek Cervenka (cervajs) 2007-08-08 11:26:58

this is on local network with QoS. terminated over E1
(without AGI script we have 99% success sending faxes)

problem is in AGI ANSWER command. without this faxing works



By: Donny Kavanagh (donnyk) 2007-08-08 12:12:07

can you please include more information, dialplan, console output, agi debug, etc.

also does it work via dialplan in 1.4.9



By: Gaspar Zoltan (gasparz) 2007-08-08 13:59:46

Try not adding the answer and hangup from agi.
#!/usr/bin/php -q
<?php
 set_time_limit(30);
 require('phpagi.php');
 error_reporting(E_ALL);

 $agi = new AGI();
 $dialstr = "SIP/asterisk1/111111111|300|HgL(610000:61000)";

 $myres = $agi->exec("DIAL $dialstr");

?>

this way the channel will be answered and hanged up when the called channel answers and hangs up.

By: Marek Cervenka (cervajs) 2007-08-09 02:52:08

to juggie:

simplest scenario to reproduce bug

extensions.conf
exten => _X.,1,AGI(dial.php)

dial.php
#!/usr/bin/php -q
<?php
 set_time_limit(30);
 require('phpagi.php');
 error_reporting(E_ALL);
 $agi = new AGI();
 $agi->answer();
 $dialstr = "SIP/asterisk/${EXTEN}|300|HgL(610000:61000)";
 $myres = $agi->exec("DIAL $dialstr");
 $agi->hangup();
?>

try send fax with g711 alaw
after that remove
$agi->answer();
and try again

note: phpagi - http://phpagi.sf.net



By: Jason Parker (jparker) 2007-08-29 16:42:53

Closing.

As soon as you answer, audio will start coming from the sending fax machine.  If the fax machine on the SIP side doesn't get the first bit of audio, it can't possibly work.

Simple solution - don't answer fax calls via dialplan (or in your case, AGI)

By: Jason Parker (jparker) 2007-08-29 16:49:47

Reopening, and I retract my previous statement.

There was a bit of a miscommunication when I discussed this with other developers.

The receiving fax starts the transmission, upon answer.  The sending fax machine does not know the call has been answered.

By: Jason Parker (jparker) 2007-09-13 13:10:43

I wonder if this is at all related to ASTERISK-8662

By: Tilghman Lesher (tilghman) 2007-12-05 09:49:19.000-0600

Any progress?

By: Marek Cervenka (cervajs) 2007-12-05 10:07:20.000-0600

in 1.4.11 works ok

By: Tilghman Lesher (tilghman) 2007-12-05 10:50:02.000-0600

Okay, then, I'm closing this out as fixed.