> -----Original Message-----
> From: Harald Fuchs [mailto:[EMAIL PROTECTED]]
> Sent: 28. januar 2003 10:46
> To: [EMAIL PROTECTED]
> Subject: Re: Mysqlhotcopy and reuilding indexes
> 
> 
> In article <[EMAIL PROTECTED]>,
> Erlend Hopsø Strømsvik <[EMAIL PROTECTED]> writes:
> 
> > Hi
> > Sorry if I'm just being feeble minded here but I can't get 
> this to work.
> 
> > First I take a copy of my database using:
> > mysqlhotcopy --allowold --noindices db_name /path/path
> 
> > using the '--noindices' since it says
> > "--noindices 
> > Don't include full index files in copy to make the backup 
> smaller and faster
> > The indexes can later be reconstructed with myisamchk -rq.. "
> > in the manual.
> 
> > But I can't for the life of me figure out how to restore 
> the index files
> > with myisamchk. All I get is "myisamchk: error: 
> 'blabla.MYD' is not a
> > MyISAM-table" or "myisamchk: error: 'blabla.frm' is not a 
> MyISAM-table".
> 
> Just omit the suffix: myisamchk -rq dbdir/blabla
> 


I'm pretty sure I tried that...
"myisamchk: error: File 'plassering' doesn't exist" is what I get when
trying to run it without the suffix.

But from the documentation I found this:
http://www.mysql.com/doc/en/REPAIR_TABLE.html

"As of MySQL 4.0.2, there is a USE_FRM mode for REPAIR. Use it if the `.MYI'
file is missing or if its header is corrupted. In this mode MySQL will
recreate the table, using information from the `.frm' file. This kind of
repair cannot be done with myisamchk."

So from MySQL 4.0.2 you can't do this with 'myisamchk'. So next time I
should include information about which version of MySQL I'm running too
*hangs head in shame* Allthough this -could- have been noted in the docs!


Maybe there should be a change in the documentation at the mysqlhotcopy page
soon then since a lot of people are starting to use MySQL 4.x.x:
http://www.mysql.com/doc/en/mysqlhotcopy.html

"--noindices 
Don't include full index files in copy to make the backup smaller and faster
The indexes can later be reconstructed with myisamchk -rq.. "

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to