views:

106

answers:

2

I'm looking for documentation on how MySQL stores data on disk, in particular InnoDB and MyISAM.

I took a database course back in college (and wrote a primitive database) so I have a general idea.

I could ask a bunch of questions here about how various types are stored in rows, and how rows are stored on disk, or go whole-hog and just describe my entire system in excruciating detail and ask for how to structure it, but I think simply learning how it stores records would let me figure it out by myself with a lot less bandwidth.

Is this documented anywhere (outside of the source code)?

Thanks!

+3  A: 

Here is a presentation on InnoDB Internals/File Formats. And here is some documentation about MyISAM internals.

Asaph
Nice! These are great!
Ken
A: 

Hmmm...do you mean how and where the files are physically written to the disk? Well, you're going to need to add at least a few semesters as a computer science major to fully grok that. There is some relevance with clustered indexes where the physical layout is configured and affect performance, but this is more about query analyzing.

I can tell you that MySQL, as a RDBMS, stores MySQL tables as individual files, as opposed to MS SQL server and Oracle which tend to combine their database objects in files. Beyond that, the physical layout shouldn't concern you too much. It sounds like you might need to focus more on "System Design", such as database normalization, etc..

Can you tell us a little more about what you're looking for? Or what you're trying to do..?

cinqoTimo