Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I recently started noticing that a large sum of my tmp tables of my MySQL is being created on my Disk rather then in the memory.

TEMP TABLES
Current max_heap_table_size = 128 M
Current tmp_table_size = 128 M
Of 73993 temp tables, 46% were created on disk
Perhaps you should increase your tmp_table_size and/or max_heap_table_size
to reduce the number of disk-based temporary tables
Note! BLOB and TEXT columns are not allow in memory tables.
If you are using these columns raising these values might not impact your
ratio of on disk temp tables.

How can I optimize this so that it uses memory rather then the disk since it would be faster.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

The text you printed tells you what you need to do:

Perhaps you should increase your tmp_table_size and/or max_heap_table_size to reduce the number of disk-based temporary tables

http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html#sysvar_tmp_table_size http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html#sysvar_max_heap_table_size

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.