Hi Everyone,<div><br></div><div>I've been trying to get asynchronous AGIs working in some Asterisk code I have. I'm using Asterisk 1.8.7.0, and I'm very familiar with dialplan and AGI scripting overall. Here's my problem: I can't get Asterisk to execute *any* AGIs asynchronously.</div>
<div><br></div><div>Firstly, I discovered asynchronous AGIs via "Asterisk: The Definitive Guide". The asynchronous AGI information I read can be found online, here: <a href="http://ofps.oreilly.com/titles/9780596517342/AGI.html">http://ofps.oreilly.com/titles/9780596517342/AGI.html</a> (scroll down to the section titled "Async AGI--AMI Controlled AGI").</div>
<div><br></div><div>According to the book, since Asterisk 1.6.0 the AGI dialplan application has been able to execute AGI scripts asynchronously, via the syntax:</div><div><br></div><div>exten => s,1,AGI(async:script)</div>
<div><br></div><div>According to the book, using the "async:" prefix should have Asterisk run the AGI script in the background and instantly continue executing dialplan code.</div><div><br></div><div>So here's my Asterisk dialplan code that's being run:</div>
<div><br></div><div>[hangup]</div><div>exten => s,1,AGI(async:/etc/asterisk/scripts/hangup.py)</div><div>exten => s,n,Return()</div><div><br></div><div>Pretty simple context--essentially my AGI script just does some call clean up logic before a caller hangs up, talking to a few web servers and generating statistics for later usage. What happens when Asterisk executes this context, is:</div>
<div><br></div><div>WARNING[7911]: res_agi.c:1622 launch_script: Failed to execute '/var/lib/asterisk/agi-bin/async:/etc/asterisk/scripts/hangup.py': File does not exist.</div><div><br></div><div>As you can see, Asterisk is ignoring the async: directive, and treating it as part of the AGI script path.</div>
<div><br></div><div>Is there anyway for me to make asynchronous AGIs work? I've tried searching online to no avail.</div><div><br></div><div>I'd greatly appreciate any responses, thanks for your time.</div><div><br>
</div><div>-Randall<br><div><div><br></div>-- <br>Randall Degges<div><i><a href="http://rdegges.com/" target="_blank">http://rdegges.com/</a></i></div><br>
</div></div>