When I do mysql> show status like '%qcache%'; it returns:

mysql> show status like '%qcache%';
+-------------------------+----------+
| Variable_name        | Value  |
+-------------------------+----------+
| Qcache_queries_in_cache | 19817   |
| Qcache_inserts          | 299528   |
| Qcache_hits            | 687127   |
| Qcache_lowmem_prunes  | 6702   |
| Qcache_not_cached    | 3171    |
| Qcache_free_memory      | 45631400 |
| Qcache_free_blocks      | 8163     |
| Qcache_total_blocks    | 48469    |
+-------------------------+----------+
8 rows in set (0.00 sec)
mysql>

Is this data acceptable? I'm reserving 100M for the query cache. Is that way too much for DaniWeb, where the entire site is powered by the db?

Why are there so many lowmem_prunes when there is so much free_memory available?

Can someone please explain to me about blocks and how to defragment them?

Thanks!

by running the command at mysql prompt : FLUSH QUERY CACHE
This defragments the query cache...if you want to delete the stuff then use RESET QUERY CACHE. But probably you just need to defrag it so that it doesn't slow down.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.