An error caused by turning on Query Cache
Call the police today with an error:host xxxx has more lowmem_prunes,please add Memory....
This alarm was written by a shell script.
Qcache_lowmem_prunes= `$ Procedure_source-h$host-P$Port-uadmin-pxxxx-e "show status" | grep "Qcache_lowmem_prunes" | awk'{print $2} '`if [$Qcache_lowmem_prunes-gt 700000000] thenecho "$host has more lowmem_prunes,please add Memory" | mail-s "$host has more lowmem_prunes,now lowmem_prunes is $Qcache_lowmem_prunes `date +% R% F" `"$maillist elseecho" $host lowmem_prunes ok "fi
The official document's interpretation of Qcache_lowmem_prunes:
The number of queries that were deleted from the query cache because of low memory.
It probably means that the cache pool is full, resulting in query pruning.
Combined with the following two articles, the decision is made as follows: change the my.cnf file, query_cache_type=1- > 0 query_cache_size=1G- > 0
Be sure to restart
Reference: http://t.cn/RAF4d7z http://t.cn/RAF4d7Z