LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-02-2012, 10:15 AM   #1
pingu
Senior Member
 
Registered: Jul 2004
Location: Skuttunge SWEDEN
Distribution: Debian preferably
Posts: 1,350

Rep: Reputation: 127Reputation: 127
Mysql: Restore backup but only differences


Situation is this:
We have a dedicated server "OLD" which we wanted to ditch in favour for a cloud-based server "ECS".
Everything was copied from OLD to ECS and we got it working.
After 2 weeks ECS crashed...
The hosting provider took a LOONG time to give us backups, we had to switch all our clients back to OLD before that.

So now our clients (we're talking Typo3-sites here) have made changes on ECS during the 2 weeks it ran, then on OLD after the crash.
Therefore I need to add data only for the period 27/7 -9/8 to the actual running database on OLD.

I have found a few commercial apps that claims they can do it, but first I'm looking for a free solution - we've already lost a lot of money in this crash...

It's data in one pretty large database that's most important, it contains around 15 Typo3-installations (yes, all in one database...)
The dumpfile is 150 MB.

All mysql-tools I've found and other tools like phpmyadmin seems to go for "all or nothing".
Any ideas?
 
Old 09-02-2012, 07:10 PM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,349

Rep: Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750
You'll need to talk to the guys at Typo3; they may(!) be able to help, but in general, unless all your recs (or at least all the key ones) are date/time stamped, I don't see how for a general backup/restore tool.
The problem with an automated DB Merge Op is to decide which 'version' takes precedence. After all, if you had to go back to previous DB, the users likely tried to re-insert, update lost recs, but they likely won't be exactly the same as the now-recovered ones.
Actually, in that case, it may be worth asking if you NEED to bring back the lost recs at all...

You could write some code yourself eg take a mysqldump (which is plain text) of each db and work out the differences using eg Perl.
You need to consider rules for:
1. new recs
2. amended recs
3. deleted recs

separately.


Good Luck.

Do let us know how you solved it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
S/w for backup/restore for Mysql gurnav General 12 03-19-2012 01:50 AM
[SOLVED] tar backup & restore in mysql ramecare Linux - Server 4 05-06-2011 11:12 PM
[SOLVED] Mysql Backup & Restore scripts ramecare Linux - Server 3 04-11-2011 05:29 AM
Restore MySQL Dump File But I want it to restore with different names? helptonewbie Linux - Newbie 5 07-08-2009 05:09 AM
restore mysql backup gabsik Linux - Software 3 01-15-2007 12:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration