diff --git a/INSTALL.txt b/INSTALL.txt index 5b4f588b7..18eae9d07 100644 --- a/INSTALL.txt +++ b/INSTALL.txt @@ -50,11 +50,10 @@ Internet Explorer 7 or later |* PHP Configuration *| ----------------------- In the PHP configuration file (php.ini), set the following settings: - memory_limit = 120M + memory_limit = 256M file_uploads = On short_open_tag = On -The memory_limit may be a minimum of 80MB, but it is recommended to set it to -120MB. If planning on uploading large Input Documents and attached files, then +If planning on uploading large Input Documents and attached files, then increase the max_post_size and upload_max_filesize to larger than the default 2MB: max_post_size = 2M diff --git a/framework/src/Maveriks/WebApplication.php b/framework/src/Maveriks/WebApplication.php index 82a9c5e97..46c788a23 100644 --- a/framework/src/Maveriks/WebApplication.php +++ b/framework/src/Maveriks/WebApplication.php @@ -536,7 +536,6 @@ class WebApplication ini_set('error_reporting', $arraySystemConfiguration['error_reporting']); ini_set('short_open_tag', 'On'); //?? ini_set('default_charset', 'UTF-8'); //?? - ini_set('memory_limit', $arraySystemConfiguration['memory_limit']); ini_set('soap.wsdl_cache_enabled', $arraySystemConfiguration['wsdl_cache']); ini_set('date.timezone', TIME_ZONE); //Set Time Zone diff --git a/gulliver/bin/tasks/templates/sysGeneric.php.tpl b/gulliver/bin/tasks/templates/sysGeneric.php.tpl index 79914245e..f89aba6fe 100644 --- a/gulliver/bin/tasks/templates/sysGeneric.php.tpl +++ b/gulliver/bin/tasks/templates/sysGeneric.php.tpl @@ -3,7 +3,6 @@ /*** enable display_error On to caught even fatal errors ***/ ini_set('display_errors','On'); ini_set('error_reporting', E_ALL ); -ini_set('memory_limit', '80M'); $path = Array(); $sf = $_SERVER['SCRIPT_FILENAME']; diff --git a/gulliver/system/class.dbMaintenance.php b/gulliver/system/class.dbMaintenance.php index cfa1ce711..bb3905a58 100644 --- a/gulliver/system/class.dbMaintenance.php +++ b/gulliver/system/class.dbMaintenance.php @@ -436,7 +436,6 @@ class DataBaseMaintenance */ public function restoreFromSql($sqlFile, $type = 'file') { - ini_set('memory_limit', '64M'); if ($type == 'file' && !is_file($sqlFile)) { throw new Exception("the $sqlFile doesn't exist!"); } diff --git a/gulliver/system/class.g.php b/gulliver/system/class.g.php index ee129521e..486670b0c 100644 --- a/gulliver/system/class.g.php +++ b/gulliver/system/class.g.php @@ -2750,11 +2750,6 @@ class G if (!array_key_exists("channels", $imageInfo)) { $imageInfo["channels"] = 3; } - $memoryNeeded = Round(($imageInfo[0] * $imageInfo[1] * $imageInfo['bits'] * $imageInfo['channels'] + Pow(2, 16)) * 1.95) / (1024 * 1024); - if ($memoryNeeded < 80) { - $memoryNeeded = 80; - } - ini_set('memory_limit', intval($memoryNeeded) . 'M'); $functions = array(IMAGETYPE_GIF => array('imagecreatefromgif', 'imagegif' ), IMAGETYPE_JPEG => array('imagecreatefromjpeg', 'imagejpeg'), IMAGETYPE_PNG => array('imagecreatefrompng', 'imagepng')); diff --git a/thirdparty/phing/Phing.php b/thirdparty/phing/Phing.php index ca9ca7fd6..a44c4cfd8 100644 --- a/thirdparty/phing/Phing.php +++ b/thirdparty/phing/Phing.php @@ -1111,12 +1111,6 @@ class Phing { ini_set('default_charset', 'iso-8859-1'); ini_set('register_globals', 'off'); ini_set('allow_call_time_pass_reference', 'on'); - - // should return memory limit in MB - $mem_limit = (int) ini_get('memory_limit'); - if ($mem_limit < 32) { - ini_set('memory_limit', '32M'); // nore: this may need to be higher for many projects - } } /** diff --git a/workflow/engine/PmBootstrap.php b/workflow/engine/PmBootstrap.php index 4745282c4..4f38b2eec 100644 --- a/workflow/engine/PmBootstrap.php +++ b/workflow/engine/PmBootstrap.php @@ -36,7 +36,6 @@ class PmBootstrap extends Bootstrap ini_set('error_reporting', $e_all); ini_set('short_open_tag', 'On'); ini_set('default_charset', "UTF-8"); - ini_set('memory_limit', $this->pmConfig['memory_limit']); ini_set('soap.wsdl_cache_enabled', $this->pmConfig['wsdl_cache']); ini_set('date.timezone', (isset($_SESSION['__SYSTEM_UTC_TIME_ZONE__']) && $_SESSION['__SYSTEM_UTC_TIME_ZONE__'])? 'UTC' : $this->pmConfig['time_zone']); //Set Time Zone diff --git a/workflow/engine/bin/cron.php b/workflow/engine/bin/cron.php index 5aa50b485..7b552d923 100644 --- a/workflow/engine/bin/cron.php +++ b/workflow/engine/bin/cron.php @@ -101,7 +101,6 @@ try { ini_set('error_reporting', $e_all); ini_set('short_open_tag', 'On'); ini_set('default_charset', 'UTF-8'); - ini_set('memory_limit', $arraySystemConfiguration['memory_limit']); ini_set('soap.wsdl_cache_enabled', $arraySystemConfiguration['wsdl_cache']); ini_set('date.timezone', $systemUtcTimeZone ? 'UTC' : $arraySystemConfiguration['time_zone']); diff --git a/workflow/engine/bin/cron_single.php b/workflow/engine/bin/cron_single.php index 2306f622a..83c5fa260 100644 --- a/workflow/engine/bin/cron_single.php +++ b/workflow/engine/bin/cron_single.php @@ -95,7 +95,6 @@ try { restore_error_handler(); // Do not change any of these settings directly, use env.ini instead - ini_set('memory_limit', $arraySystemConfiguration['memory_limit']); ini_set('display_errors', $arraySystemConfiguration['debug']); ini_set('error_reporting', $e_all); ini_set('short_open_tag', 'On'); diff --git a/workflow/engine/bin/reindex_solr.php b/workflow/engine/bin/reindex_solr.php index 67fe269d2..74f255211 100644 --- a/workflow/engine/bin/reindex_solr.php +++ b/workflow/engine/bin/reindex_solr.php @@ -87,8 +87,6 @@ if(count ($argv) > 3) { $debug = 1; ini_set ('display_errors', 1); -//error_reporting (E_ALL); -ini_set ('memory_limit', '256M'); // set enough memory for the script $e_all = defined( 'E_DEPRECATED' ) ? E_ALL & ~ E_DEPRECATED : E_ALL; $e_all = defined( 'E_STRICT' ) ? $e_all & ~ E_STRICT : $e_all; diff --git a/workflow/engine/bin/verify_solr.php b/workflow/engine/bin/verify_solr.php index 043a8a3e8..6223b15d8 100644 --- a/workflow/engine/bin/verify_solr.php +++ b/workflow/engine/bin/verify_solr.php @@ -52,8 +52,6 @@ $debug = 1;//enable o disable notice, this mechanism is inherited from '/process ini_set ('display_errors', 1); -ini_set ('memory_limit', '256M'); // set enough memory for the script - $e_all = defined( 'E_DEPRECATED' ) ? E_ALL & ~ E_DEPRECATED : E_ALL; $e_all = defined( 'E_STRICT' ) ? $e_all & ~ E_STRICT : $e_all; $e_all = $debug ? $e_all : $e_all & ~ E_NOTICE; diff --git a/workflow/engine/classes/class.pmFunctions.php b/workflow/engine/classes/class.pmFunctions.php index e99854804..c204b82a5 100644 --- a/workflow/engine/classes/class.pmFunctions.php +++ b/workflow/engine/classes/class.pmFunctions.php @@ -947,9 +947,8 @@ function PMFSendMessage( $delIndex = 0, $config = [] ) { - ini_set ( "pcre.backtrack_limit", 1000000 ); - ini_set ( 'memory_limit', '-1' ); - @set_time_limit ( 100000 ); + ini_set("pcre.backtrack_limit", 1000000); + @set_time_limit(100000); global $oPMScript; diff --git a/workflow/engine/controllers/InstallerModule.php b/workflow/engine/controllers/InstallerModule.php index 0ab4eacbf..49606d9f4 100644 --- a/workflow/engine/controllers/InstallerModule.php +++ b/workflow/engine/controllers/InstallerModule.php @@ -1181,7 +1181,6 @@ class InstallerModule extends Controller { $filter = new InputFilter(); ini_set('max_execution_time', '0'); - ini_set('memory_limit', '256M'); $serv = 'http://'; if (isset($_SERVER['HTTPS']) && !empty(trim($_SERVER['HTTPS']))) { diff --git a/workflow/engine/controllers/adminProxy.php b/workflow/engine/controllers/adminProxy.php index 8ecb2e07f..5516af836 100644 --- a/workflow/engine/controllers/adminProxy.php +++ b/workflow/engine/controllers/adminProxy.php @@ -65,11 +65,6 @@ class adminProxy extends HttpProxyController $updatedConf['expiration_year'] = $httpData->expiration_year; } - $httpData->memory_limit .= 'M'; - if ($sysConf['memory_limit'] != $httpData->memory_limit) { - $updatedConf['memory_limit'] = $httpData->memory_limit; - } - if ($sysConf['proxy_host'] != $httpData->proxy_host) { $updatedConf['proxy_host'] = $httpData->proxy_host; } @@ -126,7 +121,7 @@ class adminProxy extends HttpProxyController $msg = ", Host -> " . $httpData->proxy_host . ", Port -> " . $httpData->proxy_port . ", User -> " . $httpData->proxy_user; } - G::auditLog("UploadSystemSettings", "Time Zone -> " . $httpData->time_zone . ", Memory Limit -> " . $httpData->memory_limit . ", Cookie lifetime -> " . $httpData->max_life_time . ", Default Skin -> " . $httpData->default_skin . ", Default Language -> " . $httpData->default_lang . $msg); + G::auditLog("UploadSystemSettings", "Time Zone -> " . $httpData->time_zone . ", Cookie lifetime -> " . $httpData->max_life_time . ", Default Skin -> " . $httpData->default_skin . ", Default Language -> " . $httpData->default_lang . $msg); } public function uxUserUpdate($httpData) @@ -1584,12 +1579,6 @@ class adminProxy extends HttpProxyController */ public static function validateDataSystemConf($httpData, $envFile) { - if (!((is_numeric($httpData->memory_limit)) && ((int)$httpData->memory_limit == $httpData->memory_limit) && - ((int)$httpData->memory_limit >= -1)) - ) { - throw new Exception(G::LoadTranslation('ID_MEMORY_LIMIT_VALIDATE')); - } - if (!((is_numeric($httpData->max_life_time)) && ((int)$httpData->max_life_time == $httpData->max_life_time) && ((int)$httpData->max_life_time > 0)) ) { diff --git a/workflow/engine/src/ProcessMaker/Core/Installer.php b/workflow/engine/src/ProcessMaker/Core/Installer.php index 1706e684a..e93baa821 100644 --- a/workflow/engine/src/ProcessMaker/Core/Installer.php +++ b/workflow/engine/src/ProcessMaker/Core/Installer.php @@ -376,9 +376,7 @@ class Installer } //ACTIVE ENTERPRISE - ini_set('max_execution_time', '0'); - ini_set('memory_limit', '256M'); $serv = 'http://'; if (isset($_SERVER['HTTPS']) && trim($_SERVER['HTTPS']) != '') { diff --git a/workflow/engine/src/ProcessMaker/Core/System.php b/workflow/engine/src/ProcessMaker/Core/System.php index 91ad8ab49..3fb29ea34 100644 --- a/workflow/engine/src/ProcessMaker/Core/System.php +++ b/workflow/engine/src/ProcessMaker/Core/System.php @@ -36,7 +36,6 @@ class System 'debug_time' => 0, 'debug_calendar' => 0, 'wsdl_cache' => 1, - 'memory_limit' => "256M", 'time_zone' => 'America/New_York', 'expiration_year' => '1', 'memcached' => 0, diff --git a/workflow/engine/templates/admin/system.js b/workflow/engine/templates/admin/system.js index 7dc38aa8e..e8d14efad 100644 --- a/workflow/engine/templates/admin/system.js +++ b/workflow/engine/templates/admin/system.js @@ -96,21 +96,6 @@ Ext.onReady(function(){ items: [ cmbTimeZone, { - xtype: 'numberfield', - id: 'memory_limit', - name: 'memory_limit', - fieldLabel: _('ID_MEMORY_LIMIT'), - allowBlank: false, - allowDecimals: false, - minValue: -1, - autoCreate: {tag: "input", type: "text", autocomplete: "off", maxlength: 15}, - value: sysConf.memory_limit, - listeners: { - change: function () { - changeSettings(); - } - } - }, { xtype: 'numberfield', id: 'max_life_time', name: 'max_life_time', diff --git a/workflow/public_html/bootstrap.php b/workflow/public_html/bootstrap.php index dd9348d49..cf58c3128 100644 --- a/workflow/public_html/bootstrap.php +++ b/workflow/public_html/bootstrap.php @@ -52,7 +52,6 @@ $config = PmSystem::getSystemConfiguration(); $filter = new InputFilter(); $config['display_errors'] = $filter->validateInput($config['display_errors']); $config['error_reporting'] = $filter->validateInput($config['error_reporting']); -$config['memory_limit'] = $filter->validateInput($config['memory_limit']); $config['wsdl_cache'] = $filter->validateInput($config['wsdl_cache'], 'int'); $config['time_zone'] = $filter->validateInput($config['time_zone']); // Do not change any of these settings directly, use env.ini instead @@ -60,7 +59,6 @@ ini_set('display_errors', $filter->validateInput($config['display_errors'])); ini_set('error_reporting', $filter->validateInput($config['error_reporting'])); ini_set('short_open_tag', 'On'); ini_set('default_charset', "UTF-8"); -ini_set('memory_limit', $filter->validateInput($config['memory_limit'])); ini_set('soap.wsdl_cache_enabled', $config['wsdl_cache']); ini_set('date.timezone', (isset($_SESSION['__SYSTEM_UTC_TIME_ZONE__']) && $_SESSION['__SYSTEM_UTC_TIME_ZONE__']) ? 'UTC' : $config['time_zone']); //Set Time Zone diff --git a/workflow/public_html/sysGeneric.php b/workflow/public_html/sysGeneric.php index bb5c9eb63..a18f7ded0 100644 --- a/workflow/public_html/sysGeneric.php +++ b/workflow/public_html/sysGeneric.php @@ -315,7 +315,6 @@ ini_set('display_errors', $config['display_errors']); ini_set('error_reporting', $config['error_reporting']); ini_set('short_open_tag', 'On'); ini_set('default_charset', "UTF-8"); -ini_set('memory_limit', $config['memory_limit']); ini_set('soap.wsdl_cache_enabled', $config['wsdl_cache']); ini_set('date.timezone', (isset($_SESSION['__SYSTEM_UTC_TIME_ZONE__']) && $_SESSION['__SYSTEM_UTC_TIME_ZONE__']) ? 'UTC' : $config['time_zone']); //Set Time Zone @@ -572,7 +571,6 @@ ini_set('display_errors', $config['display_errors']); ini_set('error_reporting', $config['error_reporting']); ini_set('short_open_tag', 'On'); ini_set('default_charset', "UTF-8"); -ini_set('memory_limit', $config['memory_limit']); ini_set('soap.wsdl_cache_enabled', $config['wsdl_cache']); ini_set('date.timezone', TIME_ZONE); //Set Time Zone