Jump to content


Photo

automatically back up my database


  • Please log in to reply
2 replies to this topic

#1 Mouse

Mouse
  • Members
  • PipPipPip
  • Advanced Member
  • 95 posts
  • LocationToo Close to LONDON

Posted 19 July 2006 - 11:06 AM

Dear all…

Ok so I’ve just about got the PHP thing under control and the JavaScript (so I can learn Ajax next) is coming along… so the next thing I need to sort out is a bit of backing up of MySQL.

Short of manually backing up my database each evening (hard to do as I am away a lot and the wife does like to see me occasionally) with a dump file via my host’s poor PHPMyAdmin, - or trusting them to do it correctly…

Question:
Is there a script / program / magic bit of hocus-pocus that will automatically back up my database and perhaps mail it to me every 24 hours or so?

Answer: … over to you!

Many thanks

Mouse


#2 designationlocutus

designationlocutus
  • Members
  • PipPipPip
  • Advanced Member
  • 62 posts

Posted 19 July 2006 - 01:04 PM

Look up Cron jobs :)

#3 fenway

fenway
  • Staff Alumni
  • MySQL Si-Fu / PHP Resident Alien
  • 16,199 posts
  • LocationToronto, ON

Posted 19 July 2006 - 03:51 PM

Well, mysqldump will export your DB, but you have to write a script that will execute it... MySQL 5.1 has an event scheduler, though I've never used it.  CRON is the way to go, for now.
Seriously... if people don't start reading this before posting, I'm going to consider not answering at all.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users