Difference between revisions of "Talk:UpgradeDisk"

From SME Server
Jump to navigationJump to search
m (Remove actioned discussion)
 
Line 1: Line 1:
This HOWTO really saved me. The only notes I have to add is concerning the mysql db's.
 
  
The mysql db's are kept in: /var/lib/mysql
 
 
Stop the mysql service:
 
  service mysqld stop
 
 
Change directories to the old mysql:
 
cd /mnt/old/var/lib/
 
 
Copy the mysql db's to the new install:
 
cp -R ./mysql /var/lib/
 
 
Change directories to the new mysql:
 
  cd /var/lib/
 
 
Change the ownership on the new install mysql directory:
 
  chown -R mysql:mysql ./mysql
 
 
Restart the mysqld service:
 
  service mysqld start
 
----
 
Looks like you are trying to recover your mysql database in the situation that you were not able to run pre-backup. Perhaps you would like to add a section within this wiki identifying the situation in which this is relevant. It obviously should not be the general case for this procedure; only if you are in a recovery situation where pre-backup is not option. --[[User:Christian|Christian]] 15:01, 25 December 2008 (UTC)
 
----
 
That was exactly the case. I had a sudden power outage that caused a corrupt filesystem and unbootable server. In the past I could fsck the system and it would boot within reasonable amount of time. While I tried to fsck the partition, it ran for more than 20 hours. It seemed faster to rebuild than to wait. While I could recover and transfer the data with this procedure, there is was no way identifying how to transfer the mysql db's. Since the db's constantly change in a 24 hour period, a periodic backup wouldn't really help. This solved that issue. In general, I'm still uncertain the best way to backup and recover. --[[User:kruhm|kruhm]]
 

Latest revision as of 18:49, 22 February 2013