* Jonathan Edwards
> I'm running MySQL on a Linux server with 2 processors, 4 Gb memory and
> SCSI disks. I am using MySQL to manage a database with 3 million reports
> and various auxiliary tables which are also fairly large.
>
> My question is: How do I make the best use of the 4 Gb memory available?
>
> I've tried increasing the key_buffer to 512M because most queries are
> between 3-6 tables using indexed fields. What other tuning should I try?

If you only use MyIsam tables, key_buffer_size is one of the most important
variables, you could probably increase it even more. If possible, make it so
big that all your index files (*.MYI-files) would fit, but not more than 50%
of your total memory:

<URL: http://www.mysql.com/doc/en/SHOW_VARIABLES.html >
<URL: http://www.mysql.com/doc/en/Server_parameters.html >

If you also use InnoDb tables, there are a number of other variables you
should look at:

<URL: http://www.mysql.com/doc/en/InnoDB_start.html >
<URL: http://www.mysql.com/doc/en/InnoDB_tuning.html >

You don't describe your data or your usage pattern of the data. Are the rows
very big? What's the total data size? index size? Are your tables fully
normalized? Do you retrieve many rows at a time? Are there many simultanous
users? Are the rows being updated? deleted?

These things matter when it comes to optimization. :)

--
Roger


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to