zoukankan      html  css  js  c++  java
  • mysql缓存问题 相关参数的查看

    查询缓存参数

    show global variables like '%query_cache%';
    
    have_query_cache	      YES     #查询缓存是否可用
    query_cache_limit	      1048576   #可缓存具体查询结果的最大值
    query_cache_min_res_unit	 4096
    query_cache_size	      1048576   #查询缓存的大小
    query_cache_type	      OFF       #阻止或是支持查询缓存
    query_cache_wlock_invalidate	 OFF
      
    

      其他参数查看

    Qcache_free_blocks	1
    Qcache_free_memory	1031872
    Qcache_hits	      0
    Qcache_inserts	      0
    Qcache_lowmem_prunes	0
    Qcache_not_cached	4218739
    Qcache_queries_in_cache	0
    Qcache_total_blocks	1
    

      表示查询缓存中目前还有多少剩余的blocks,如果该值显示较大,则说明查询缓存中的内存碎片过多了,可能在一定的时间进行整理。    减少碎片: 合适的query_cache_min_res_unit可以减少碎片,这个参数最合适的大小和应用程序查询结果的平均大小直接相关,

  • 相关阅读:
    Codeforces Round #388(div 2)
    Codeforces Round #387(div 2)
    Codeforces Round #386(div 2)
    Codeforces Round #385(div 2)
    Codeforces Round #384(div 2)
    Wannafly Union Goodbye 2016
    写在2016的最后一天——给未来的自己
    2016HDU校赛
    2016BUAA校赛决赛
    codevs 1344 模拟退火
  • 原文地址:https://www.cnblogs.com/torchstar/p/15548052.html
Copyright © 2011-2022 走看看