Difference between revisions of "Database Backup"
From Amahi Wiki
(Created page with 'It's good practice to periodically backup up your database. This functionality is coming to Amahi soon, but until then there is a simple way to automatate it. Follow the steps …') |
|||
Line 10: | Line 10: | ||
''BACKUPDIR="/srv/backup/db" on line 51 to: | ''BACKUPDIR="/srv/backup/db" on line 51 to: | ||
BACKUPDIR="/var/hda/files/db" | BACKUPDIR="/var/hda/files/db" | ||
− | + | ''MAILADDR="maintenance@example.com"'' on line 65 to: | |
− | + | MAILADDR="root" | |
+ | ''DBEXCLUDE=""'' on line 76 to: | ||
+ | DBEXCLUDE="information_schema" | ||
+ | ''CREATE_DATABASE=no'' on line 79 to: | ||
+ | CREATE_DATABASE=yes | ||
+ | ''LATEST=no'' on line 94 to: | ||
+ | LATEST=yes | ||
== Tips == | == Tips == |
Revision as of 16:21, 11 November 2010
It's good practice to periodically backup up your database. This functionality is coming to Amahi soon, but until then there is a simple way to automatate it. Follow the steps below to help keep your data safe.
Installation
- Download the script AutoMySQLBcckup file to your home directory.
- Some changes will need to be made for this to work on your HDA as follows:
USERNAME=debian on line 39 to:
USERNAME=root
PASSWORD= on line 42 to:
PASSWORD=hda
BACKUPDIR="/srv/backup/db" on line 51 to:
BACKUPDIR="/var/hda/files/db"
MAILADDR="maintenance@example.com" on line 65 to:
MAILADDR="root"
DBEXCLUDE="" on line 76 to:
DBEXCLUDE="information_schema"
CREATE_DATABASE=no on line 79 to:
CREATE_DATABASE=yes
LATEST=no on line 94 to:
LATEST=yes