not sure its a stack overflow question

I have a Mac and am hosting a Apache MySQL server on it using MAMP Pro. If I back up my data on the time machine, is MySQL database also backed up or do I have to create mysqldump and backup up as a cron job? In case of a crash do I do a normal restore in case it can be backed up on time machine.

Thanks

有帮助吗?

解决方案

Make a regular dump with MySQL dump or use another specific database back-up tool. A copy of the data folder is not ok.

MySQL dump will really read the data and can be checked. It is not always true that all data is written completely to the data file and lockings give issues.

If you have a specific time of back-up just run a cron before that moment and verify whether it is safe and finished. MySQL will take care of lockings, changes, transactions etc.

Always, read always, verify your back-up with a restore test.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top