On Mar 18, 2005, at 7:06 AM, Andy Hall wrote:
Hi,
I have tried the following process in order to try and replicate a database
with InnoDB files:
1. created a new database in PHPMyAdmin 2. via command line, copied all the .frm files from the old database directory into the new database directory 3. changed all the ownership and permissions 4. restarted mysql
The database is now recognised in PHPMyAdmin, but when I click on any of the
tables I get the message "cannot find [table].InnoDB". Originally, the
tables in the source database were MyISAM and then converted to InnoDB. I
tried renaming one of the [table].frm files to [table].InnoDB, but now this
does not show up on the table list.
I tried the described method as I have done this before with MyISAM tables
successfully.
What am I missing? Or is a completely invalid way to move the database?
Would a server restart fix it?
As someone else mentioned this won't work with InnoDB. InnoDB uses .frm files for table descriptions along with ibdata files and it's own log files. If you want to do something like this by moving files you could:
1. shut down mysqld cleanly
2. copy db directories, .frm files, all ibdata files and all InnoDB log files (not mysql binary logs, InnoDB logs) to the new machine
3. set ownership and permissions
4. start mysqld on new machine
Or you could us InnoDB hot backup tool, but in that case you still need to copy the .frm files and database directories.
This is all best described in the InnoDB manual (if you're using it you should read the entire thing as it handles a lot of things differently than MyISAM) and the MySQL replication section of it's manual.
Good luck, Ware
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]