Fatal error during restore

electronicmonkey - May 12, 2008 - 18:18
Project:Backup and Migrate
Version:5.x-1.0
Component:Miscellaneous
Category:support request
Priority:normal
Assigned:Unassigned
Status:won't fix
Description

Fatal error: Maximum execution time of 30 seconds exceeded in C:\wamp\www\mysite\includes\database.mysql.inc on line 153

#1

ronan - May 12, 2008 - 18:48
Status:active» won't fix

Yup, for anything but the smallest of databases, the standard 30 seconds is not going to be enough for a restore. You'll need to increase the php execution time on your server to get this to work. If you have the devel module installed, make sure it is not logging sql statements as that will increase your likelihood of timing out or running out of memory.

Hope this helps
Ronan

#2

electronicmonkey - May 12, 2008 - 19:46
Status:won't fix» active

I am running on WAMP. Where do I increase the php execution time ?

#3

ronan - May 12, 2008 - 20:08
Status:active» won't fix

That's a little beyond the scope of my expertise and the scope of this module, but some quick searches in the usual places may turn up some helpful links:
http://www.google.com/search?q=php+increase+execution+time
http://drupal.org/search/node/php+increase+max+execution+time

Good luck

#4

yidog - May 16, 2008 - 02:24

Hi electronicmonkey,

I had the exact same problem and was able to fix it in the following manner:

  • Left-click the WAMP icon in your task bar.
  • Scroll to Config Files --> php.ini
  • Open the php.ini file [it will probably open with Notepad or something similar]
  • In the "Resource Limits" section of the file [you can do a "Edit --> find" to get to this section quickly], look for "max_execution_time = 30"
  • Change the 30 to a higher number [I used 300]
  • Save the file
  • Close WAMP, then Re-open it
  • Retry the Backup - it should work.

Once I figured that out, this module has been awesome. Big thumbs up.

Danny

#5

electronicmonkey - May 16, 2008 - 19:44

I tried the module on two live sites to move content from one to the other but the content wasn't moved. Do I need a fresh database to move to ? It says "restore complete" but I can't find the data anywhere.

#6

bryan kennedy - July 21, 2008 - 15:15

I really like the concept of this module, but it isn't possible to change the max execution time long enough on most production environments. That sort of makes this method of backup less useful. I wonder if there is a way to execute a shell script that would run the mysqldump as a background process instead. I am looking into whether you can do this with exec() or system().

If this is something I was able to figure out would you be open or interested incorporating this functionality into the module as an option?

#7

ronan - July 21, 2008 - 17:02

Working on mitigating the timeout issue is something i'm pondering, although I'm not sure there are a lot of safe ways to break the import/export down into smaller chunks so it's on the back burner until I figure out something better.

As for shell access, you may want to look into drush (http://drupal.org/project/drush) which allows you run drupal functions via the command line. I don't use it myself, so I've no idea if you can use it with backup and migrate (or whether drush support has to be integrated into the module itself). But if you find out one way or the other please let me know. When I get some time I'll try and investigate this myself.

Thanks
r

 
 

Drupal is a registered trademark of Dries Buytaert.