views:

69

answers:

2

I'm having trouble with a liferay installation that is suddenly (without any code modifications) failing with "dulplicate id" errors. We've identified that the issue may be solved by changing the mysql engine to InnoDB.

I'm planning the change now, but i'm not sure what complications are likely in the process.

I've checked for full text indexes mentioned in this question

http://stackoverflow.com/questions/1228672/converting-table-from-myisam-to-innodb

Are there any other likely problems I should

+1  A: 

Biggest problem is not having a backup of the database before conversion. With a backup, you can experiment all you like. Naturally you're doing this on a test database, right? (Not a production database.)

wallyk
tests ran well, but the test environment for this application hasn't been reliable. The app is in the middle of a "development team transition"
Andrew Neelands
A: 

Andrew, there are lots of differences between MyISAM and InnoDB, the least of which is the fact that they are controlled by different configuration options in the MySQL conf. There is also the fact that InnoDB is ACID compliant unlike MyISAM. Also, backups cant be done with just copying MYI and MYD files anymore. Then there is the matter of different size requirements, different index types, and different performance characteristics between the two engines.

Even though I like InnoDB is most cases, may I ask what leads you to believe that a switch to InnoDB will solve your problem? and perhaps you should be seeking an alternate answer to THAT question instead of this one?

Mike Sherov
Anthony,Thanks for the response. The move to innoDB has been recommended for the reasons you've outlined. Certain parts of the site are failing with "duplicate id" exceptions and we believe that ACID compliance is a step in the right direction. The database in question is being related to one that's already using InnoDB and as they grow we're seeing more problems.
Andrew Neelands
Backups cannot be done with "just copying MYI and MYD files" in MyISAM either. At least, not if you want consistent ones.
MarkR
Mark, I was oversimplifying the process, as outlined for MyISAM here: http://dev.mysql.com/doc/refman/5.0/en/replication-howto-additionalslaves.html what I meant was that for innodb, copying the data directory doesn't work, and you need to perform a dump of the tables instead of just copying files around.
Mike Sherov