Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ MySQL thread cache thread_cache_size parameter optimization     - MySQL / MariaDB database master-slave replication (Database)

- Intruder tools Knark Analysis and Prevention Linux environment (Linux)

- Linux automatically install service components and optimize the kernel parameters (Linux)

- Introduction to thread pooling and simple implementation (Programming)

- Oracle user lock how to know what causes (Database)

- LMMS 1.03 install on Ubuntu 14.04 (Linux)

- Debian 7.8 system installation and configuration process (Linux)

- PostgreSQL Select source code analysis (Database)

- rpm package specify the installation path (Linux)

- Linux Creating a new user error Creating mailbox file: File exists (Linux)

- The free command in Linux (Linux)

- MySQL event table to achieve timing build a small note (Database)

- JavaScript basic types and type conversion (Programming)

- Sublime Text Add instructions to insert the current time zone (Linux)

- Ubuntu 14.04 LTS installed Hadoop 1.2.1 (distributed cluster mode) (Server)

- CentOS directory structure Explanation (Linux)

- Docker command Detailed (Linux)

- OpenGL Superb Learning Notes - Depth Texture and Shadows (Programming)

- Nginx + Tomcat static and dynamic load balancing and separation configuration essentials under Linux (Server)

- tespeed - test speed of Python tools (Linux)

 
         
  MySQL thread cache thread_cache_size parameter optimization
     
  Add Date : 2017-01-08      
         
         
         
  Thread_cahe_size thread pool thread cache. Used to cache the idle thread, so as not to be destroyed, if the thread cache idle threads, you need to re-establish a new connection, it will invoke a cache priority thread pool, it will soon be able to respond to connection requests.

Each establish a connection, you need to match a thread

MariaDB [(none)]> show global status like '% thread%';

------------------------------------------ + ------ + ---- +

| Variable_name | Value |

------------------------------------------ + ------ + ---- +

| Delayed_insert_threads | 0 |

| Innodb_master_thread_1_second_loops | 4338823 |

| Innodb_master_thread_10_second_loops | 432031 |

| Innodb_master_thread_background_loops | 18974 |

| Innodb_master_thread_main_flush_loops | 18974 |

| Innodb_master_thread_sleeps | 4338819 |

| Performance_schema_thread_classes_lost | 0 |

| Performance_schema_thread_instances_lost | 0 |

| Slow_launch_threads | 0 |

| Threadpool_idle_threads | 0 |

| Threadpool_threads | 0 |

| Threads_cached | 0 | represents the current moment of idle threads in the thread cache

| Threads_connected | 11 | connections currently established on behalf of a number

The number of threads since the last service startup, created | | Threads_created | 11032160

| Threads_running | 2 | The number of threads currently active (non-sleep) of

------------------------------------------ + ------ + ---- +

thread_cache_size best arranged and threads_connected same. But few will thread_cache_size than 200 set large.

Configuration:

mysql> set global thread_cache_size = 30 with immediate effect

or

vim /etc/my.cnf

thread_concurrency = 30

Restart mysql.
     
         
         
         
  More:      
 
- What happens after the MySQL disk space is full (Database)
- KVM add virtual disks (Linux)
- Distributed Hadoop1.2.1 cluster installation (Server)
- Linux operating system to solve a serious fault handling (Linux)
- MySQL thread cache thread_cache_size parameter optimization (Database)
- Mac OS X system setup Google Go language development environment configuration tool Sublime Text 2 (Linux)
- Git uses a standard process (Linux)
- Using Java to build micro-services (Server)
- MySQLbinlog combat on using data recovery (Database)
- Ubuntu PPA install SMPlayer 14.9 (Linux)
- Ubuntu cut screen method (Linux)
- Linux server network penetration testing (Linux)
- Hackers is how the invasion and control of Things devices? (Linux)
- Python exception summary (Programming)
- Oracle creates split and splitstr functions (Database)
- Linux Network Programming - signal blocking and shielding (block, unblock) (Programming)
- C ++, overloading, cover, hide (Programming)
- Java development specifications summary (Programming)
- Linux start the process (Linux)
- Oracle Linux 6.4 (BOND) dual NIC teaming combat - Annotated (Linux)
     
           
     
  CopyRight 2002-2022 newfreesoft.com, All Rights Reserved.