Clear query cache without restarting server : MySQL

Rate this post

Clear Memory Cache on Linux centos

RESET QUERY CACHE will clear out the query cache, but needs RELOAD privileges.



FLUSH QUERY CACHE does NOT clear out the query cache, 
it simply defrags it leaving the cached query results in place.



Related Posts

  • 40
    By default, every Linux OS has an efficient memory management system used to clear the buffer cache periodically. You can manually free up the memory cache with the following simple command: linux:~$ sudo sh -c "sync; echo 3 > /proc/sys/vm/drop_caches" However, if you want to force the Linux OS to…
    Tags: linux, cache, memory, clear, flush
  • 39
    A Shell script for killing slow MySQL queries: #!/bin/sh # Credentials for a MySQL user with PROCESS, SUPER permissions USERNAME= PASSWORD= # MySQL Server location HOST= PORT=3306 TIMEOUT=60 # 1 minute TARGET_USER= # MySQL user to monitor MYSQL="mysql -u $USERNAME --password=$PASSWORD -h $HOST -P $PORT -B" $MYSQL -N -e 'SHOW…
    Tags: mysql, linux, server, query
  • 36
    I connect to mysql from my Linux shell. Every now and then I run a SELECT query that is too big. It prints and prints and I already know this is not what I meant. I would like to stop the query. Hitting Ctrl+C (a couple of times) kills mysql…
    Tags: mysql, query, linux
  • 35
    The core logic of a database application is performed through SQL statements, whether issued directly through an interpreter or submitted behind the scenes through an API. The tuning guidelines of this post will help to speed up all kinds of MySQL applications. The guidelines cover SQL operations that read and…
    Tags: query, cache, memory, mysql
  • 33
    MySQL Server has several logs that can help you find out what activity is taking place. By Default , No Logs are enabled in MySQL. By default, the server writes files for all enabled logs in the data directory. Logs can be flush by Issuing FLUSH LOGS statement. Binary log…
    Tags: query, server, mysql

Satya Prakash

VOIP Expert: More than 8 years of experience in Asterisk Development and Call Center operation Management. Unique Combination of Skill Set as IT, Analytics and operation management.

Leave a Reply

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

%d bloggers like this: