Mysql state invalidating

You can access the patch from: 2742 Kristofer Pettersson 2008-10-29 Bug#38551 query cache can still consume [very little] cpu time even when it is off.

You can access the patch from: 2917 Kristofer Pettersson 2008-11-07 Bug#38551 query cache can still consume [very little] cpu time even when it is off.

You can access the patch from: 2735 Kristofer Pettersson 2008-09-08 Bug#38551 query cache can still consume [very little] cpu time even when it is off.

When the query cache size is zero, all query cache functionallity should be skipped.

3) Only be able to disable query cache at compile time/startup time.

What is left to investigate is if it really is possible to read query_cache_size in a concurrent environment and if the rare but occasional lack of consistence when the query_cache_size change is an issue for the overall system performance. After review, it may be pushed to the relevant source trees for release in the next version.

The current code actually locks/unlocks the query_cache lock twice when the query_cache_size is zero! This can all be bypassed if the check for query_cache_size is done without holding the QC lock as in Query_cache::store_query The CPU time wasted is very less, however, in benchmark situations, every cpu cycle counts.

It often happens to see and hear of replication SQL thread almost always in state “invalidating query cache entries (table)” .

By using the command line option --query_cache_type=0, the user can disable the query cache permanently and avoid taking the query cache mutex.

At this time there is no plan to backport the fix to a stable release as it changes the behavior of the query_cache_type command line option.

The query mutex becomes a very hot spot especially if you are using RBR.

In fact, with RBR there is a binlog event for each modified row, thus the mutex is acquired for every row.

Search for mysql state invalidating:

mysql state invalidating-37mysql state invalidating-75

Since query_cache_size is protected from any changes by the barrier in Query_cache::resize() we can safely add a test at the begining of the invalidate* functions to avoid having mutexes locked when the query cache is ment to be disabled. After review, it may be pushed to the relevant source trees for release in the next version.

Leave a Reply

Your email address will not be published. Required fields are marked *

One thought on “mysql state invalidating”

  1. • As you arrive you’ll get given a badge containing your name and a number• You’ll also get given a date sheet, which is how you’ll let us know who you hit it off with• Once everyone has arrived you’ll be asked to sit at the table with your number on it• For the ladies, this is the table you’ll stay at for the evening• The host will ring a bell every five minutes to indicate that the date is over.

  2. This form is set up to collect information for a single product you found less than euphoric. To help us provide the best possible customer service, we will need some information from you.