Updated on 2024-09-02 GMT+08:00

PGXC_DISK_CACHE_STATS

PGXC_DISK_CACHE_STATS records the usage of file cache. This system view is supported only by clusters of version 9.1.0 or later.

Table 1 PGXC_DISK_CACHE_STATS columns

Column

Type

Description

node_name

text

Node name.

total_read

bigint

Total number of accesses to disk cache.

local_read

bigint

Total number of times disk cache reads from local disk.

remote_read

bigint

Total number of times disk cache reads from remote storage.

hit_rate

numeric(5,2)

Hit rate of disk cache.

cache_size

bigint

Total size of data saved in disk cache, in KB.

fill_rate

numeric(5,2)

Fill rate of disk cache.

Example

Query the hit rate of disk cache on each node.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
SELECT hit_rate FROM pgxc_disk_cache_stats;
 hit_rate
----------
    56.91
    56.85
      NaN
      NaN
      NaN
      NaN
(6 rows)