mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #39233
[Bug 1636090] A patch has been submitted for review
Patch for "master" branch: https://reviews.mahara.org/7204
--
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1636090
Title:
Execution timeout during 16.10 upgrade when fixing broken user data
Status in Mahara:
New
Bug description:
Mahara: 16.10.0
DB: Postgres
OS: Linux
Browser: FF
While upgrading from 16.04 to 16.10, we are getting the following
error:
PHP Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/clients/mahara/htdocs/lib/mahara.php on line 1569
PHP Stack trace:
PHP 1. {main}() /var/www/clients/mahara/htdocs/admin/cli/upgrade.php:0
PHP 2. upgrade_mahara() /var/www/clients/mahara/htdocs/admin/cli/upgrade.php:53
PHP 3. upgrade_core() /var/www/clients/mahara/htdocs/lib/mahara.php:265
PHP 4. xmldb_core_upgrade() /var/www/clients/mahara/htdocs/lib/upgrade.php:347
PHP 5. set_profile_field() /var/www/clients/mahara/htdocs/lib/db/upgrade.php:4733
PHP 6. safe_require() /var/www/clients/mahara/htdocs/lib/user.php:536
We have over 45K users in the DB and it's timing out.
I've fixed it by adding the following immediately after 'if ($oldversion < 2016090206) {':
$cur_max_execution_time = @ini_get('max_execution_time');
ini_set('max_execution_time', 0);
And, at the end of the if statement (to set the time back to the original timeout):
ini_set('max_execution_time', $cur_max_execution_time);
I didn't use raise_time_limit(0) as it didn't seem to make a
difference. It still timeout after 30 seconds.
Thanks,
Ghada
To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1636090/+subscriptions
References