Fatal error: Maximum execution time of 30 seconds exceeded in /lib/moodlelib.php on line 5394
This is in the function get_string
Any help much appreciated.
I have even tried downloading a new version, but it is still the same! Should I file bug report?
Paolo
Re: Fatal error: Maximum execution time of 30 seconds exceeded
You may want to raise it editing max_execution_time on your php.ini file.
Re: Fatal error: Maximum execution time of 30 seconds exceeded
Presumably it is taking so long because it is looking for something in the get_string which it isn't finding.
Paolo
Re: Fatal error: Maximum execution time of 30 seconds exceeded
I very strongly doubt that. Because get_string is a simple little function that doesn't do a whole lot of searching. It is used a lot in all parts of Moodle. It's purpose is quite simply: to retrieve the correct string from the language pack the user has selected. Whenever Moodle needs to get a string of text in the language of choice, whether it's an error msg, a button label, etc., it calls get_string (or print_string) and it supplies the name of the file it should be in (default file name is moodle). The file extension is always assumed to be .php. Sometimes, a small number of alternate file names are also passed to get_string.
The function then looks for the string in that file in the current language pack. If it's there it finds it right away; if it's not there, it immediately knows that, and tries the alternate files, if any. If it's not there, it goes to the language pack for the parent language, if any. Finally, if it still hasn't found the right string, it tries the English language pack, if it isn't already there. If it's not there, it aborts.
It's much more likely that get-string is part of a loop that is getting run over and over until it times out.
RLE
Re: Fatal error: Maximum execution time of 30 seconds exceeded
nevertheless, something odd is going on with a clean install. if i get a chance i'll try and dig into the problem.
Re: Fatal error: Maximum execution time of 30 seconds exceeded
Hi
I am also facing the same problem, I have also changed the max_execution_time to 300 seconds in php.ini, but my moodle still consider only 60 seconds to upload a file. If uploading process take more time it agains throws same error "fatal error: Maximum execution time of 60 seconds exceeded".
Thanks in advance.
Re: Fatal error: Maximum execution time of 30 seconds exceeded
Log is about the last querry log before the error.
build:
Moodle 2.0 dev (Build: 20090513)
Error:
Fatal error: Maximum execution time of 30 seconds exceeded in C:\Inetpub\lib\dml\mysqli_native_moodle_database.php on line 418
Fatal error: Maximum execution time of 30 seconds exceeded in C:\Inetpub\lib\moodlelib.php on line 7806
Mysql Query log:
236 Query CREATE INDEX mdl_roleassi_rol_ix ON mdl_role_assignments (roleid)
236 Query CREATE INDEX mdl_roleassi_con_ix ON mdl_role_assignments (contextid)
236 Query CREATE INDEX mdl_roleassi_use_ix ON mdl_role_assignments (userid)
236 Query CREATE TABLE mdl_role_capabilities (
id BIGINT(10) unsigned NOT NULL auto_increment,
contextid BIGINT(10) unsigned NOT NULL DEFAULT 0,
roleid BIGINT(10) unsigned NOT NULL DEFAULT 0,
capability VARCHAR(255) NOT NULL DEFAULT '',
permission BIGINT(10) NOT NULL DEFAULT 0,
timemodified BIGINT(10) unsigned NOT NULL DEFAULT 0,
modifierid BIGINT(10) unsigned NOT NULL DEFAULT 0,
CONSTRAINT PRIMARY KEY (id)
)
236 Query ALTER TABLE mdl_role_capabilities COMMENT='permission has to be signed, overriding a capability for a p'
236 Query CREATE UNIQUE INDEX mdl_rolecapa_rolconcap_uix ON mdl_role_capabilities (roleid, contextid, capability)
236 Query CREATE INDEX mdl_rolecapa_rol_ix ON mdl_role_capabilities (roleid)
Re: Fatal error: Maximum execution time of 30 seconds exceeded
error is;
Fatal error: Maximum execution time of 60 seconds exceeded in \lib\dml\mysqli_native_moodle_database.php on line 418
Fatal error: Maximum execution time of 60 seconds exceeded in \lib\moodlelib.php on line 7806
and query log ends here;
246 Query CREATE INDEX mdl_file_use_ix ON mdl_files (userid)
246 Query CREATE TABLE mdl_files_cleanup (
id BIGINT(10) unsigned NOT NULL auto_increment,
contenthash VARCHAR(40) NOT NULL DEFAULT '',
CONSTRAINT PRIMARY KEY (id)
)
246 Query ALTER TABLE mdl_files_cleanup COMMENT='File pool cleanup candidates'
246 Query CREATE UNIQUE INDEX mdl_fileclea_con_uix ON mdl_files_cleanup (contenthash)
246 Query CREATE TABLE mdl_repository (
id BIGINT(10) unsigned NOT NULL auto_increment,
type VARCHAR(255) NOT NULL DEFAULT '',
visible TINYINT(1) unsigned DEFAULT 1,
sortorder BIGINT(10) unsigned NOT NULL DEFAULT 0,
CONSTRAINT PRIMARY KEY (id)
)
246 Query ALTER TABLE mdl_repository COMMENT='This table contains one entry for every configured external '
246 Query CREATE TABLE mdl_repository_instances (
id BIGINT(10) unsigned NOT NULL auto_increment,
name VARCHAR(255) NOT NULL DEFAULT '',
typeid BIGINT(10) unsigned NOT NULL,
userid BIGINT(10) unsigned NOT NULL DEFAULT 0,
contextid BIGINT(10) unsigned NOT NULL,
username VARCHAR(255),
password VARCHAR(255),
timecreated BIGINT(10) unsigned,
timemodified BIGINT(10) unsigned,
readonly TINYINT(1) unsigned NOT NULL DEFAULT 0,
CONSTRAINT PRIMARY KEY (id)
)
246 Query ALTER TABLE mdl_repository_instances COMMENT='This table contains one entry for every configured external '
246 Query CREATE TABLE mdl_repository_instance_config (
id BIGINT(10) unsigned NOT NULL auto_increment,
instanceid BIGINT(10) unsigned NOT NULL,
name VARCHAR(255) NOT NULL DEFAULT '',
Re: Fatal error: Maximum execution time of 30 seconds exceeded
it took 4 minutes on a decent win 2003 server. Will try an ubuntu or solaris see what happens. I never had to change this entry on php.ini before. Did we have major database structure change or this is an isolated problem?
I met the same problem when I tried to install Moodle 2.2 on my windows server 2003 pack 2. But it was quite by chance when I tried again to install the Moodle on the old windows server 2003 pack 1, it worked fine. Perhaps it was because of the Pack 2 system.
Use the default language "English" will have no porblem.
Re: Fatal error: Maximum execution time of 30 seconds exceeded
kindly assist. i am trying to install moodle 2.4.3 from my browser and it gives the following error: Fatal error: Maximum execution time of 30 seconds exceeded in C:\Moodle\MoodleWindowsInstaller-latest\server\moodle\mod\data\db\subplugins.php on line 3 even after changing the maximum execution time to 500 secs on php.ini
Re: Fatal error: Maximum execution time of 30 seconds exceeded
Chris,
Did you restart your webserver after you changed the configuration?
If no, please do so. This will load the new setting.
Re: Fatal error: Maximum execution time of 30 seconds exceeded
Re: Fatal error: Maximum execution time of 30 seconds exceeded
I am also having this proble and I can't find php.ini file, even on a system search
any ideas where it could be?