HI All. I have a really strange issue that I'm two months into troubleshooting; however, I cannot figure it out. I have an AGI Script (PHP) that runs every time a call comes into my Asterisk box. Most of the time, it runs without any issue. However, every now and then, the PHP-AGI script fails after it is executed and simply returns 'returning 4'. I verify the PHP script begins to run. However, it appears to just stop. I have placed try/catch statements everywhere, but it does not seem to hit them. Just to verify, this is the same script running over and over with the same parameter. Any ideas/suggestions as of what can be happening? Thanks, Alex -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20210130/d6290aa9/attachment.html>
Out of RAM/swap? j On 1/30/21 1:18 PM, Alexander Perkins wrote:> HI All. I have a really strange issue that I'm two months into > troubleshooting; however, I cannot figure it out. I have an AGI > Script (PHP) that runs every time a call comes into my Asterisk box. > Most of the time, it runs without any issue. However, every now and > then, the PHP-AGI script fails after it is executed and simply returns > 'returning 4'. I verify the PHP script begins to run. However, it > appears to just stop. I have placed try/catch statements everywhere, > but it does not seem to hit them. > > Just to verify, this is the same script running over and over with the > same parameter. > > Any ideas/suggestions as of what can be happening? > > Thanks, > Alex >-- *Jeff LaCoursiere* STRATUSTALK, INC. / CTO Phone: *+1 703.496.4990 x108* Mobile: *+1 815.546.6599* Email: *jeff at stratustalk.com* <mailto:jeff at stratustalk.com> Website: *https://www.stratustalk.com* Address: *One Freedom Square 13th Floor Reston, VA 20190* <https://www.facebook.com/jeff.lacoursiere> <https://linkedin.com/in/jeff-lacoursiere-884361> <https://www.twitter.com/stratustalk> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20210130/38136846/attachment.html>
Dňa 30. 1. 2021 o 20:18 Alexander Perkins napísal(a):> HI All. I have a really strange issue that I'm two months into > troubleshooting; however, I cannot figure it out. I have an AGI > Script (PHP) that runs every time a call comes into my Asterisk box. > Most of the time, it runs without any issue. However, every now and > then, the PHP-AGI script fails after it is executed and simply returns > 'returning 4'. I verify the PHP script begins to run. However, it > appears to just stop. I have placed try/catch statements everywhere, > but it does not seem to hit them. > > Just to verify, this is the same script running over and over with the > same parameter. > > Any ideas/suggestions as of what can be happening?I think this can happen by hanging up the call by one party, when SIGHUP is sent to AGI script. PHP will exit on SIGHUP. It can be resolved by initializing signal handler in PHP script (pcntl_signal) for SIGHUP and doing nothing in it (return). -- Regards, Michal Rybarik