Mailing List Archive

Database in RAM
A friend of mine told me that MySQL might soon store databases in RAM,
and synchronize to the disk every now and then. I had thought about
trying to accomplish this with MythTV. Since I know when the changes are
made to the database, I know when is a good time to synchronize (for
example, right after mythfilldatabase or after indexing music). I still
haven't gotten MythTV to work (waiting for my new soundcard to arrive),
but I was wondering if anyone had any ideas about it, or if anyone can
forsee a technical problem with it. The main reason I want to do this is
that I have a ton of RAM and MythTV seems to be fairly disk-intensive. I
hypothesize that queries made to RAM will be much quicker than queries
made to disk.
Re: Database in RAM [ In reply to ]
> A friend of mine told me that MySQL might soon store databases in RAM,
> and synchronize to the disk every now and then. I had thought about
> trying to accomplish this with MythTV. Since I know when the changes are
> made to the database, I know when is a good time to synchronize (for
> example, right after mythfilldatabase or after indexing music). I still
> haven't gotten MythTV to work (waiting for my new soundcard to arrive),
> but I was wondering if anyone had any ideas about it, or if anyone can
> forsee a technical problem with it. The main reason I want to do this is
> that I have a ton of RAM and MythTV seems to be fairly disk-intensive. I
> hypothesize that queries made to RAM will be much quicker than queries
> made to disk.

There shouldn't really be any need for this. MySQL (as do most database
programs) already caches important data in RAM, and the linux kernel
does the same with oft-accessed files, libraries, etc (supposed to be
even better with the 2.5 tree). Thus, the more RAM you have, the more
stuff should be loaded into RAM.

It'd be a better idea to look at the tables and queries themselves and
see what can be optimized. MythTV doesn't seem to have all that much
trouble with db stuff (MythMusic on the other hand...).

Then again, loading more things into RAM can't hurt.

-Chris