If am running AppServ as a LAMP development environment on a Windows machine,

PHP 5.1.4
Drupal 5.12
MySQL database 5.0.22

i am trying to upgrade to Drupal 5.14.

while i am trying to disable modules i am getting Fatal error: Maximum execution time of 240 seconds exceeded in includes\database.mysql.inc

Changes I tried in php.ini file:
mysql.connect_timeout = -1
max_execution_time = 3000

and restarted the Server . but still i am getting the error.

Any other leads on a setting to look at? Thanks.

Comments

alakesh’s picture

That's may be a php timeout error message. You can change the settings in the php.ini file.

Or you can simply try this -> edit sites/default/settings.php and added the following line:

ini_set('max_execution_time', 0);

mennonot’s picture

It sounds like one of the module that is being disable is calling the node_access_rebuild function. This functions sets a limit of 240 seconds on itself. If you have a lot of nodes on your site, this might not be long enough. You may have to temporarily (or possibly permanently) increase the time out limit at line 2981 in the node module at modules/node/node.module:

set_time_limit(240);

you could even remove it all together (the max_execution_time in php.ini will eventually kick in):

set_time_limit(0);

Thanks to bestknight for pointing this one out.

alex.koloskov’s picture

Also check includes/common.inc file at line 2713:

function drupal_cron_run() {
  // Try to allocate enough time to run all the hook_cron implementations.
  if (function_exists('set_time_limit')) {
    @set_time_limit(240);
  }

and includes/locale.inc file at line 1039:

function _locale_import_po($file, $langcode, $mode, $group = NULL) {
  // Try to allocate enough time to parse and import the data.
  if (function_exists('set_time_limit')) {
    @set_time_limit(240);
  }