
1st June 2006, 09:48
|
|
Senior Member
|
|
Join Date: Sep 2005
Location: UK, East Midlands
Posts: 517
Thanks: 1
Thanked 2 Times in 2 Posts
|
|
My Backup List
I am running Suse 10 64bit and the following list is what I intend to backup on a daily basis for both standard backups and also a disaster recovery.
Disaster Recovery would be a total system crash and I re-install the system using the same passwords and configuration and then replace all files that I have modified.
List:
/etc/passwd
/etc/shadow
/etc/group
/srv/www
/home/admispconfig
/etc/apache2
/etc/proftpd.conf
/etc/proftpd_ispconfig.conf
/etc/ssh
/etc/postfix
Am I missing anything??
Thanks
|

1st June 2006, 10:32
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,883
Thanks: 691
Thanked 4,187 Times in 3,204 Posts
|
|
I recommend to backup also:
/var/lib/mysql (your mysql databases)
/etc/gshadow (dont know if SuSE has this file too)
If you use mbox format for mail storage, backup also:
/var/spool/mail
|

1st June 2006, 11:11
|
|
Senior Member
|
|
Join Date: Sep 2005
Location: UK, East Midlands
Posts: 517
Thanks: 1
Thanked 2 Times in 2 Posts
|
|
I use maildir so thats not a problem. Thanks for the information.
Will I need to temp stop any services in order to tar them. Like apache and ispconfig ect.... I thought I read in another post that you have to do some special commands to backup sql databases.
Thanks
|

1st June 2006, 17:23
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
No, you don't need to stop services.
If you want to back up MySQL databases, I'd use this way: http://www.howtoforge.com/faq/6_3_en.html
|

1st June 2006, 23:15
|
|
Local Meanie
|
|
Join Date: Apr 2006
Location: Switzerland
Posts: 1,046
Thanks: 4
Thanked 33 Times in 31 Posts
|
|
If you want to make backups for each individual mysql-db you can use that:
Quote:
#Dump new files
USER=root
PASSWORD=.........
HOST=localhost
for i in $(echo 'SHOW DATABASES;' | mysql -u$USER -p$PASSWORD -h$HOST|grep -v '^Database$'); do
mysqldump \
-u$USER -p$PASSWORD -h$HOST \
-Q -c -C --add-drop-table --add-locks --quick --lock-tables \
$i > /mysql_backup/$i.sql;
done;
|
Just alther the paramaters to what you need.
|

6th June 2006, 09:55
|
|
Senior Member
|
|
Join Date: Sep 2005
Location: UK, East Midlands
Posts: 517
Thanks: 1
Thanked 2 Times in 2 Posts
|
|
Falko using the method described in your link, if I am reading it right this would require me to know the names of all the databases so if I have 100 customers each with 2 databases that would mean 200 mysql databases so I would need a method that would just backup all of them.....
I think the method left by sjau would do this without any human interaction ie if one night I have 200 databases then all of these would get backed up if on the next night there are 201 I dont need to alter any scripts the new database would get backed up. Am I right in thinking this???
Thanks
|

6th June 2006, 11:38
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
Quote:
|
Originally Posted by mphayesuk
Falko using the method described in your link, if I am reading it right this would require me to know the names of all the databases so if I have 100 customers each with 2 databases that would mean 200 mysql databases so I would need a method that would just backup all of them.....
|
Yes, that right.
Quote:
|
Originally Posted by mphayesuk
I think the method left by sjau would do this without any human interaction ie if one night I have 200 databases then all of these would get backed up if on the next night there are 201 I dont need to alter any scripts the new database would get backed up. Am I right in thinking this???
|
That's also correct.
|

6th June 2006, 11:55
|
|
Senior Member
|
|
Join Date: Sep 2005
Location: UK, East Midlands
Posts: 517
Thanks: 1
Thanked 2 Times in 2 Posts
|
|
Do I need to backup /var/lib/mysql if I am going to include the code by sjau in my backup script.
|

6th June 2006, 12:33
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
No, either back up using sjau's way, or back up /var/lib/mysql. Otherwise you back up the same data twice.
|

6th June 2006, 12:35
|
|
Senior Member
|
|
Join Date: Sep 2005
Location: UK, East Midlands
Posts: 517
Thanks: 1
Thanked 2 Times in 2 Posts
|
|
Are there any pros and cons of the two methods.
1) Will backing up /var/lib/mysql using tar and then restoring using tar get anything wrong corrupt data ect...
2) Which is the best method... what would you recommend.
Thanks
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 17:20.
|
|
Recent comments
2 days 8 hours ago
2 days 17 hours ago
2 days 19 hours ago
2 days 21 hours ago
2 days 22 hours ago
3 days 14 min ago
3 days 1 hour ago
3 days 2 hours ago
3 days 18 hours ago
3 days 19 hours ago