From d16bfa48ee33f07ebb60221267082002aea5c47b Mon Sep 17 00:00:00 2001 From: Clint Byrum Date: Thu, 18 Jun 2015 13:22:35 -0700 Subject: [PATCH] Tune mysql a bit better for concurrent operations With PyMySQL in the projects we can expect things to happen more concurrently now. The query cache is a hinderance to concurrency, and more connections will be required. Change-Id: Icfb8cdbb9ed39cfd7732ad05fe740e01c767af7b --- lib/databases/mysql | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/databases/mysql b/lib/databases/mysql index f097fb21cb..0e477ca264 100644 --- a/lib/databases/mysql +++ b/lib/databases/mysql @@ -95,7 +95,10 @@ function configure_database_mysql { sudo bash -c "source $TOP_DIR/functions && \ iniset $my_conf mysqld bind-address 0.0.0.0 && \ iniset $my_conf mysqld sql_mode STRICT_ALL_TABLES && \ - iniset $my_conf mysqld default-storage-engine InnoDB" + iniset $my_conf mysqld default-storage-engine InnoDB \ + iniset $my_conf mysqld max_connections 1024 \ + iniset $my_conf mysqld query_cache_type OFF \ + iniset $my_conf mysqld query_cache_size 0" if [[ "$DATABASE_QUERY_LOGGING" == "True" ]]; then