IVR: Allowed memory size of 536870912 bytes exhausted (tried to allocate 88497240 bytes)

We are having an ongoing issue with accessing IVR’s with more than about 8 options.
/etc/php.ini memory limit=2048M
/etc/php.d/freepbx.ini memory_limit=2048M

Yet, FreePBX does not seem to allocate more than 536M.

Where do I set to increase the memory_limit?

Your assistance is greatly appreciated.

Whoops\Exception\ErrorException thrown with message “Allowed memory size of 536870912 bytes exhausted (tried to allocate 88497240 bytes)”

Stacktrace:
#1 Whoops\Exception\ErrorException in /var/www/html/admin/libraries/view.functions.php:161
#0 {main} in /var/www/html/admin/config.php:0


/var/www/html/admin/libraries/view.functions.php

 */
function load_view($view_filename_protected, $vars = array()) {
 
    //return false if we cant find the file or if we cant open it
    if (!$view_filename_protected || !file_exists($view_filename_protected) || !is_readable($view_filename_protected) ) {
        dbug('load_view failed to load view for inclusion:', $view_filename_protected);
        return false;
    }
 
    // Import the view variables to local namespace
    extract( (array) $vars, EXTR_SKIP);
 
    // Capture the view output
    ob_start();
 
    // Load the view within the current scope
    include($view_filename_protected);
 
    // Get the captured output
    **$buffer = ob_get_contents();**
 
    //Flush & close the buffer
    ob_end_clean();
 
    //Return captured output
    return $buffer;
}
 
/**
 * Show View
 *
 * This function is used to show a "view" file. It has two parameters:
 *
 * 1. The name of the "view" file to be included.
 * 2. An associative array of data to be extracted for use in the view.
 *
 * This simply echos the output of load_view() if not false.
 *
 * NOTE: you cannot use the variable $view_filename_protected in your views!
 *

Arguments

"Allowed memory size of 536870912 bytes exhausted (tried to allocate 88497240 bytes)"

Did you set those new numbers lately (like, since your last restart)?

You need to restart the httpd service on the server for your updated options to take effect.

/etc/php.ini has been set for some time
/etc/php.d/freepbx.ini was just set today (no httpd restart yet).

It would appear that the memory_limit value is coming from /etc/php.d/freepbx.ini
and not /etc/php.ini,

Setting memory_limit in the freepbx.ini and restarting httpd has resolved the issue.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.