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

Tatsuo Ishii ishii at sraoss.co.jp
Mon Jun 27 14:27:25 JST 2022


> 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


More information about the pgpool-general mailing list