something about the installation profile causes the installation to fail before it even gets to the initial splash screen. i expanded the tarball, hit index to run the install, and got this error message:

Fatal error: Maximum execution time of 30 seconds exceeded in /home/mysite/public_html/includes/file.inc on line 891

Comments

Version:6.x-1.x-dev»
Component:Documentation» Code
Priority:Normal» Critical
Status:Closed (fixed)» Active

Fatal error: Maximum execution time of XX seconds exceeded in...

This is because it takes more than XX seconds to get all the data from your "host" (edit>>> "dreambox").
The sollution is quite simple: Locate your php.ini file and open it with a text editor. Look for the line max_execution_time. It should say something like 30. Increase that number to 60.
Restart your apache to reload the php settings. Now you have 60 seconds the time to get the information from your dreambox. If this is still to less, just increase the number with 30 seconds each.

if you dont acess your sever >input : "php_value max_execution_time 0" in the .htacess file in your Drupal folder.
its like :# PHP 5, Apache 1 and 2.

php_value memory_limit 16M
php_value max_execution_time 0
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0

Title:installation fails in file.incFatal error: Maximum execution time of XX seconds exceeded in...

dreambox? i take it you believe i'm on dreamhost? for whatever it's worth, i'm not.

in any case, i'm installing this on the same machine on which i have already successfully installed a normal drupal 6.10 package, with no timeout errors whatsoever. which suggests to me that there's something problematic about the install profile specific to this distro.

that the failure apparently occurs during a core routine is very odd indeed.

are you a phase II tech?

datawench,

There is a lot more going on than just the Drupal 6.10 package install. The distro is adding content types, views, blocks, content, modules, etc. We suggest 60 seconds as necessary to get through the entire install. 30 seconds might do it on a very fast machine. So unfortunately, there isn't much we (Phase2) can do about that. If you are familiar with install profiles I suppose you could try breaking it up into smaller pieces yourself. Or try to do what huysonzone suggests and get your max exec time increased.

Thanks,
Mike

thank you very much, mike... hearing that from phase II directly helps a great deal.

cheers :-)

Some insider info... we're putting up a new release today. You should wait and try again with that one. We're fixing a couple problems with the previous.

thanks,
Mike

New release is up which fixes a couple issues. Give it a shot!

http://www.opensourceopenminds.com/openpublish/download

i'll check it out, thanks.

fyi, the opencalais site doesn't seem to want to email me my API key. it tells me that the key has been sent, but i never receive it.

You might want to crank up the suggested timeout to 90 or so. On a pretty much unused dedicated host, 60 failed for me. Or maybe break up that final step into multiple pieces?

Same thing happened to me and I followed what huysonzone had suggested and it finally worked.
I had to increase the time to 300 though, with 60 and 90 it still timed out.

I noticed that in tiny letters under the API key box there's:

"Make sure your PHP setting for max_execution_time is 60 or greater. It is currently set to 30"

How about making this an actual requirement in a hook_requirements() of whatever module is doing this long process, so that you can't accidentally get this far only to have your site hosed. :)

Oh, or option B, which would actually be much better... use Batch API to do whatever this thing is that's taking so long so that people don't need to futz with php.ini settings that they may not have access to.

And a basic option C, which is set the value yourself in the script w/ ini_set(). This might not work under all hosts, but it could work under some.

Status:Active» Fixed

Thanks for all the suggestions. Having a configuration set to 60 to 90 in PHP itself would be best, but since that is not always the case I have just released a new version of OpenPublish (build 268) http://www.opensourceopenminds.com/openpublish/download

In this release I use set_time_limit(120). So for all those sites that are not in SafeMode this should help make it all the way through the installation.

@webchick, I would try the batch api, but honestly these damn install profiles are hard enough as it is, I could not imagine trying to integrate it with bath processing too :) If this continues to be a sticking point I will do that though. Good ideas always win. :)

@webchick, I would try the batch api, but honestly these damn install profiles are hard enough as it is, I could not imagine trying to integrate it with bath processing too :)

Totally do not blame you one bit. ;) And IMO if someone has safe mode in this day and age, screw 'em. ;)

Just checking in to say that with build 268 and 30 sec max_execution_time in php.ini, I'm now getting none of the previous installation errors I was getting. Hooray!! :D Thanks so much, febbraro!

Sweet. Glad to see some of the frustrations of the day have paid off. Thanks again, you were a great help today.

Hi,

Even if I setup my PHP max_execution_time to 300, which is fine for previous tasks, I got a max execution timeout at Calais API configuration task. This is because of the set_time_limit(120); in file openpublish.profile line 104.

You should at least add a condition before the statement to execute it only if the actual limit is below your 120s:

if (ini_get('max_execution_time') < 120) {
    set_time_limit(120);
}

Assigned:Unassigned» febbraro

@benoit.borrel Great idea, thanks! It is in our repository and ready for the next build.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Wanted to add one more nugget info for those that are having troubles with max_execution time being exceeded.

In doing a bunch of install tests on windows, it ran into timeouts when setting the limit to 300 or more. Turns out you can add a bit of performance configuration that REALLY helps on windows (and likely on other platforms too). Since Drupal does a ton of includes/requires....LITERALLY a ton, and OpenPublish ships with a lot of modules, you can run into this problem. Anyway, setting realpath_cache_size to a value such as 512k or 1M or 2M should help dramatically. I had a site timing out at 300 seconds load in close to 15 seconds when set to 2M, so hopefully this helps someone else too. Remember that this is PER Apache thread/process so don't set it too high.

http://php.net/manual/en/ini.core.php#ini.realpath-cache-size

Component:Code» Documentation
Assigned:febbraro» Unassigned
Category:bug» task
Priority:Critical» Normal

I have a shared Linux web host account with GoDaddy.com. I was able to go through the install phases for Open Publish until it started to install the Calais feature at the end (got the 30 second max time out error). I tried going around this with a php.ini in my account's root directory but GoDaddy must have security settings preventing an override. They simply told me to get a dedicated server.

I thought of a clever work around involving me installing WAMP (PHP + MySQL + Apache, for the newbies here) on my local system, installing there and then moving everything over to my GoDaddy.com account as the 30 second max time out error (I assume) is associated with only the install piece. I really should have done this first to follow the practice of developing first locally and then pushing to production but this was for a personal web site that no one knew about yet.

Once you have Open Publish installed (the last piece involving the Calais install took me ~3 minutes on my system), you can either continue developing locally or move the files to your web host and then change the necessary paths. You'll want to change the settings/config file in Open Publish's file path and also change any necessary path settings in the MySQL database via phpMyAdmin for instance.

I simply just had to change the following in my php.ini file to make this work (I set them fairly high since I have a slow system):

max_execution_time = 2000
realpath_cache_size=2M

You can change the settings in WAMP by clicking on the task bar icon, go to PHP and then click on php.ini. Change the settings, save the file and then "restart all services" to associate the new settings with WAMP.

Hope this helps!

I am on a media temple virtual dedicated server and tried many times to get this to work without success. Anyone else use MT?

Facing the same issue... Even if I set maximum_execution_time = 300 and memory_limit=200M it's giving me the same error.
Is it too heavy to load? I am having 4 GB RAM on my laptop where I am trying to install it currently....

Any expert comment???

I'm not an expert at this, per say, but perhaps you can try increasing to an *very* high amount for install only? Such as:

max_execution_time = 99999999999 ; Maximum execution time of each script, in seconds
max_input_time = 99999999999 ; Maximum amount of time each script may spend parsing request data
memory_limit = 9999M ; Maximum amount of memory a script may consume (8MB)
realpath_cache_size=9999M

Does this help?

Version:» 6.x-1.x-dev
Category:task» bug

Any news about this issue?

I am not able to pass the first stage, "install.php?profile=openpublish" installing openpublish on windows appserv

Thanks

I changed max_execution_time to 2530 and worked fine.

Thanks

Are you using the brand new release? http://www.opensourceopenminds.com/openpublish/download. Version 1.6 has an improved installation process that takes fewer system resources.

Yes, I was using the last version 1.60.357 PHP Version 5.2.6 on a windows vista appserv

I mentioned this elsewhere, but might help here too.
I've installed 1.6 on my home computer using xampp. It is the latest xampp with php 5.3.0, which is not supposed to work with OP. However, at the moment it is working, but perhaps I will run into problems as I work with the program.
Anyway, as recommended I set the max_execution_time to 2530. But, it wouldn't install.
However, when I increased max_input_time to 600, the program installed. So, at this moment, it installed, is still working, and I'm doing more testing. memory_limit is set at 128M.

Hope this helps others. Oh, the computer is a dell E510 with windows xp.

For what it's worth, I just uploaded OP 1.6 to Dreamhost. It works. So far.
Wasn't sure it could be done after all the comments I've read about shared hosting.
At least, at this point, it is working.

Version:» 6.x-1.x-dev
Component:Code» Documentation
Priority:Critical» Normal
Status:Active» Closed (fixed)

i followed most of your post, like changing realpath_cache_size=16k & realpath_cache_ttl=120 and change it all to 120k & 360 respectively. same as max_execution_time=30 to 120 max_input_time=60 to 120. basically i try to change almost everthing in my php.ini, settings.php, etc. as per advise

but when i tried to check my phpinfo(), the values there are still the default values... weird eh? or am i missing somthing...? my directory path in php.ini is correct as seen on phpinfo(). anyone can help? thanks... im new to drupal btw =)

@mechdrupal,

Did you restart Apache after making the changes? You have to restart for these settings to take effect.

errr.. just as i was about to recheck it now, duno for what reason, all settings worked, lol.
i was certain i restarted my APACHE, i even reloaded my configuration yesterday. im using WAPP by d way, postgre. Everytime i make changes, i restarted, and refresh my pages to see the effect but, phpinfo() was remain unchanged. But to my amazement today, it seems phpinfo() changed after i opened and checked it. maybe because there was a brownout & my PC got restarted.

heres what i did:
.htaccess file
php_value memory_limit 256M
php_value max_execution_time 120

php.ini file
ini_set('memory_limit', '256M');
max_execution_time=120
max_input_time=120
memory_limit=256M

Anyway thanks for the reply, i really appreciate it.

We're on a shared server with Hostgator... I'm trying to get OpenPublish installed on a WAMP server at home before uploading to the shared server...

I've set resources rediculously high in an attempt to beat the 60 second max_execution error... and now I'm wondering:

Can this product be used on a "normal" shared hosting server? If it requires this much resources, I'm guessing it would run very slowly and eat up a lot of bandwidth.

Has anyone got it up and running on a "typical" shared hosting server? Is it's operation as slow as its installation?

Thanks, Mike...

I am struggling through this with the latest (August, 2010) release on a WAMP server.

I've set the max execution time to something like 480 and still get the error. I've also re-set the memory limits in PHP.INI with no luck.

I posted elsewhere that I'm thinking this is a product intended for more powerful servers than we'd find on a "typical" shared hosting environment. Is this correct? If so, I'd love to see a "lite" version of OpenPublish that smaller media sites could use. Based on the online documentation and samples, OpenPublish is exactly what we're looking for.

Yes, it is intended for at least VPS servers. Shared hosting is not its target platform.

However some users have reported successfully running OP on some shared hosts. You should search posts at: http://groups.drupal.org/openpublish

For the benefit of those who come later, I am on one of the most generous shared hosting servers I've ever found (Deasoft) where I have 900MB of memory allocated and longer SQL execution times and I can control script timeouts through both my settings.php and my .htacess.

But I had to give up on installing OpenPublish (2.3RC1-build375). It timed out on max script execution time at the first install screen, so I pumped it up to 120 seconds in the settings.php. This allowed it to get to the database configuration, which then timed out again with 30 secs max exec time. So I bumped the exec time to 240 seconds in the .htaccess (tried "0" but that still timed out) and that allowed it to crash the MySQL database ("database has gone away"). After a couple of times with this happening I decided there was no use trying any further. Pity, because it really suited my new site's operating model.

By the way, before anyone talks about how big OpenPublish is and how many modules it has, one of my production sites uses over 50 modules including most of those quoted above and e-commerce. That's why I had to go to a more generous shared hosting provider. So I don't think it's all about the complexity. I have also been able to successfully install Acquia Drupal on this service.

websupportguy, latest OpenPublish has 150+ modules, so 50 is still few compared to it :)

One thing that you can try to avoid installation problems on a shared host is to install it locally (using XAMPP for instance) and then just upload to shared host,

Hope it helps.

same problem w/ drupal 6.19. I tried all the suggestions above nothing works.

I'm using xmlrpc i dont know if that causing the problem. any help..

subscribe

I tried installing locally using XAMPP but even with the settings pushed to the limits I could not get a complete installation.

Tony

Try to install Drupal clean (without any contributed modules under Sites/all/modules). This way Drupal is much lighter to install as it does not have to make provision for all these modules in the database.

That is how I overcome the timeout problem.

Oh my, that was painful. 5 hours on one install of a profile that's supposed to speed development! It finally worked, I think because I restarted it 10 times and some DB tabes were already there & it could skip steps. I did set I set php.ini settings ridiculously high with no noticeable impact.

One confusion, why did my error message say "maximum_execution_time 60 exceeded" when my php.ini and phpinfo said it was set to 120?

i had th same problem.

solved addind set_time_limit(120); to file.inc.

BTW, i don't have this function at openpublish.profile as said at #15

And my php.ini and .htaccess are set to 240, although the page got an error of limit to 60...

Where do I find the .htaccess file and the ini.php file?
I try to run the installation, but I get redirected to Hsphere-site with a message of contacting my host. No error-code mentioned when the installation stops.
My host recommended me to use i.e. drupal...

Quote from when the installation stops:
Error 500: Internal Server Error

The server encountered an unexpected condition which prevented it from fulfilling the request.

The problem is on the server side, not with your browser or the address. Most probably, a certain service (e.g., Tomcat engine) is down. Please contact your webmaster.

.htaccess is a file at the root of your Drupal install.
php.ini you need to ask where your server let's you configure it. some of then let it at the root folder, some serves need to be asked to change something.

Well, I cant find the commands that I have to change.
I guess i'll just abandon my OP-project... Seems too hard for me with less experience with these kind of programs.

read #31 and #43. ask your server host where is php.ini for you configure.
.htaccess is at your drupal (open publish) root folder

Great, I've rised the limites to 500 and it worked fine!

Thanks
Red Viciousse

it works for me with following setting, thanks.
realpath_cache_size=2M
max_execution_time = 300

I had the same problem and all I did was to increase the max_execution_time to 1000 and it worked out.

#1 works with me!
Many thanks