3

I need a suitable backup automation script that will run in PHP on my apache server.

Some of my sites run Drupal. Which is the most suitable method to automatically backup both the code and the database?

  • You *really* don't want to try to do this from within the webserver: Most have a 5-minute request timeout, and a backup of a large site could take way more than that. Something scheduled out of cron would be better. – voretaq7 Jan 26 '11 at 19:35

1 Answers1

2

You should consider using tar in a daily script for your websites, and for the database, just dump it:

mysqldump -u USER -p DATABASE > filename.sql
Jonathan Rioux
  • 1,938
  • 6
  • 33
  • 57