Disable query cache by default

Bug #1160443 reported by Matt Lord
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mysql (Juju Charms Collection)
Fix Released
High
Unassigned

Bug Description

The only red flag that I saw at first glance was your query cache
usage. You mention using 20% of available RAM for it and I would very strongly recommend against doing
so. I would generally recommend that the query cache be disabled. 20% of total ram would
generally be bad. The reason for this is that the QC uses global write locks and it essentially
serializes access to mysqld in a single threaded fashion. It's very bad for high concurrency workloads. It
also holds a server level write lock when doing big purges. If your query cache is even 256M in size
then these purges can lock everything up for 10+ seconds. 20% of ram could easily cause very long
hangs.

I would also set the query_cache_type to OFF by default, as even with a
size of 0, it's locking is problematic in high concurrency environments.

We've done a lot of work recently for our defaults, as part of the 5.6
release. You can read about that work here:
  https://blogs.oracle.com/supportingmysql/entry/server_defaults_changes_in_mysql

Related branches

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Fixed for new deploys (no revision bump yet), thanks for the feedback Matt.

Changed in mysql (Juju Charms Collection):
status: New → Fix Released
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.