[horde] Recovering addressbooks

Edward Francis Klimowicz edwardk at voicenet.com
Wed Sep 26 20:42:50 UTC 2007


Ashley M. Kirchner wrote:
> Edward Francis Klimowicz wrote:
>> you'd restore it by doing something like
>>
>> $mysql horde < horde.mysql
>>   
>     That would pull in *everything* in that dump, which is not what I 
> want.  I just want their addressbooks.  So am I just pulling the 
> turba_objects table back in?  Looking at the table structure, the old 
> 1.2.2 version doesn't match what I'm running now, 2.0.4.  What about the 
> object_ids in the table?  Do they match anything else that I need to be 
> aware of?
> 
>     That's why I asked if there's a way to get the data out and somehow 
> reinsert them into the new db...I can't simply dump the data back in 
> from the mysqldump files.
> 
>     -- A

You have a full dump of a database prior to a crash, and you're being picky
about having saved too much data from disaster/obliteration?  That's hubris.

The preferable solution would have been to recreate your install exactly as it
was before the crash.  However, in this case, what I would do, would be copy
the dump over to a temporary mysql server.  Restore the full dump to the temp
db.  Then selectively dump out just the address book info, that is:

$mysqldump horde turba_objects > turba.mysql

then on the real mysql server do

$mysql horde < turba.mysql

Now, if you have a full turba install (possibly just available from CVS, i'm
not terribly sure, as that's only what i use), there's a sql script.  In my
install, it's located at
/var/www/localhost/htdocs/horde/turba/scripts/upgrades/1.2_to_2.0.sql .

So, do something like

$mysql horde < 1.2_to_2.0.sql

After you run this script, your turba data should be ready to go.  It's just a
few alterations/additions to the mysql schema.

Best of luck, hope it works.


More information about the horde mailing list