负载/redis内存/mysql query cache

top

P cpu排序

M 缓存占比排序

登陆redis-cli

info memory

mysql查询缓存是根据sql查询语句计算出hash值,将query cache放入hash得一个链表中,如果涉及到相关数据表得修改,系统就会使相关query cache失效

have_query_cache 是否支持query cache

query_cache_limit  query cache单条最大结果集

query_cache_min_res_unit  query cache最小结果集

query_cache_size  系统分配query cache得内存大小

query_cache_type  系统是否打开了query_cache

query cache适合变化不频繁得表,成千上万得并发每次都要查询query cache hash链表带来得资源消耗还是很大

猜你喜欢

转载自www.cnblogs.com/changfengSven/p/9044422.html