Correct,
query cache is disabled by default in ndb. This is because it is not
maintained across several mysql servers. I.e. if you insert a value in
one mysql
server this will not be noticed by the query cache in the other server.
So potential _danger_ in using it.
But, if _you_ want to use it, we can supply a setting for turning it on
_anyway_. But you need to know the limitaions and dangers of using it.
Please state if you want to use it.
For 5.x we will fix this so that the query cache is invalidated across
several servers...
T
Olivier Kaloudoff wrote:
> Hi,
>
>
> I'm trying to improve performance for a 2 Nodes
> NDB based cluster, launched mysqld with --query-cache-size=32M,
> and did some repetitive queries, but qcache does not seems to be
> used..
>
> mysql> SHOW VARIABLES LIKE '%query_cache%';
> +------------------------------+----------+
> | Variable_name | Value |
> +------------------------------+----------+
> | have_query_cache | YES |
> | query_cache_limit | 1048576 |
> | query_cache_min_res_unit | 4096 |
> | query_cache_size | 33554432 |
> | query_cache_type | ON |
> | query_cache_wlock_invalidate | OFF |
> +------------------------------+----------+
> 6 rows in set (0.00 sec)
>
> mysql> SHOW STATUS LIKE 'Qcache%';
> +-------------------------+----------+
> | Variable_name | Value |
> +-------------------------+----------+
> | Qcache_free_blocks | 1 |
> | Qcache_free_memory | 33545640 |
> | Qcache_hits | 0 |
> | Qcache_inserts | 0 |
> | Qcache_lowmem_prunes | 0 |
> | Qcache_not_cached | 827 |
> | Qcache_queries_in_cache | 0 |
> | Qcache_total_blocks | 1 |
> +-------------------------+----------+
> 8 rows in set (0.00 sec)
>
>
> is qcache already implemented on top of NDB ?
>
>
> Olivier
>