[pgpool-general: 8261] Re: Shared memory cache size formula

Avi Raboah avi.raboah at gmail.com
Mon Jun 27 14:35:51 JST 2022


Hi thanks.

But in case I have very large result that I want to store in the cache how
I should calculate the cache total size?

On Mon, 27 Jun 2022 at 8:27 Tatsuo Ishii <ishii at sraoss.co.jp> wrote:

> > Do you know what is the best formula to calculate the cache size when
> using
> > shared memory, in case I want a greater query result size.
> >
> > How do I address to the block size and the number of cache entries?
>
> Unless your queries return very large results, usually you don't need
> to adjust the cache block size.
>
> For the number of cache entries (num_hash_entries), you should consult
> "show pool_cache" command. Here are some advices:
>
> - If cache_hit_ration is good enough (for example over 0.9), then you
>   do not need to adjst num_hash_entries.
>
> - If cache_hit_ration is not good, try to increase num_hash_entries so
>   that pgpool can hold more cache entries. However, it is possible
>   that the cache hit ratio won't be better because your system is
>   write heavy. In this case you should think more if you really want
>   to use the cache system.
>
> Good luck!
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese:http://www.sraoss.co.jp
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pgpool.net/pipermail/pgpool-general/attachments/20220627/423d014d/attachment.htm>


More information about the pgpool-general mailing list