Announcement Module
No announcement yet.

Per thread buffers: What are they really?

Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Per thread buffers: What are they really?

    Basically commenting on memory-usage

    When computing maximum memory usage for a thread I have one source that says:
    read_buffer_size + read_rnd_buffer_size + sort_buffer_size + thread_stack + join_buffer_size

    another that says:
    sort_buffer_size + myisam_sort_buffer_size + read_buffer_size + join_buffer_size + read_rnd_buffer_size

    yet another:
    thread_stack + net_buffer_length X 2 + record_buffer and/or record_rnd_buffer + sort_buffer_size

    Regardless, all attest the importance of keeping per thread memory allocation reasonable; hoverver, there is no way to even generically estimate what it could/should be?

  • #2
    I'm not sure how it does it, but a tool I found tells you at the top what the max possible usage would be with the settings you have:


    • #3
      mysqltuner uses the first method. In full disclosure, that is the very reason why I sought a hard, fast answer. But there doesn't seem to be one.