I have a system that has a few thousand extensions.
I have an external script that runs occasionally runs that adds extensions by calling the bulk extensions module and then at the end calls:
That has been working fine for months now, but just recently if I run module_admin reload I’ve been getting the error:
sh: line 1: 27994 File size limit exceeded/var/lib/asterisk/bin/retrieve_conf 2>&1
Error(s) have occured, the following is the retrieve_conf output:
When I go to the FreePBX UI, I see the following under system status:
retrieve_conf failed, config not applied
Reload failed because retrieve_conf encountered an error: 153
Added 1 minute ago
Any thoughts on what the issue is?
Thanks in advance.
My /tmp/freepbx_debug.log had exceeded 2 gigabytes. When I deleted the log file the error went away.
What version of FreePBX was this because the logging should auto rotate before it hits 2GB for this reason.
I have 4 different sites running 188.8.131.52 distro and all have the same issue.
I do not see anywhere in any of the logrotate configs where /tmp/freepbx_debug.log is rotated.
Is it normal for FreePBX to write logs to /tmp?
To answer your question, I’m running the latest and greatest - FreePBX 184.108.40.206
There seems to be a “bug” in php or possibly some combination of php/CentOS that results in PHP crashing when trying to write a file bigger than 2G vs. returning with an error.
This is something that was addressed in 2.10 but I don’t think back ported to 2.9 which we need to have a look at. In addition, although you can turn off debug logging in either version, PHP errors/notices get logged to the debug file as well vs. to the configured PHP location since FreePBX replaces the error handler and these don’t get turned off.
The latter situation is something we need to have a look at and determine how we want to best deal with it.