diff options
author | Nathan Bossart | 2024-10-11 16:02:09 +0000 |
---|---|---|
committer | Nathan Bossart | 2024-10-11 16:02:09 +0000 |
commit | 4e1fad37872e49a711adad5d9870516e5c71a375 (patch) | |
tree | b22f685d15c9a28aa22328f769d6b5c5bef61319 /doc/src | |
parent | add77755ce851fae2f72be4b9c56a606f9362895 (diff) |
Add pg_ls_summariesdir().
This function returns the name, size, and last modification time of
each regular file in pg_wal/summaries. This allows administrators
to grant privileges to view the contents of this directory without
granting privileges on pg_ls_dir(), which allows listing the
contents of many other directories. This commit also gives the
pg_monitor predefined role EXECUTE privileges on the new
pg_ls_summariesdir() function.
Bumps catversion.
Author: Yushi Ogiwara
Reviewed-by: Michael Paquier, Fujii Masao
Discussion: https://postgr.es/m/a0a3af15a9b9daa107739eb45aa9a9bc%40oss.nttdata.com
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/func.sgml | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index b26db3b04b0..9656d1891e8 100644 --- a/doc/src/sgml/func.sgml +++ b/doc/src/sgml/func.sgml @@ -30533,6 +30533,30 @@ SELECT pg_size_pretty(sum(pg_relation_size(relid))) AS total_size <row> <entry role="func_table_entry"><para role="func_signature"> <indexterm> + <primary>pg_ls_summariesdir</primary> + </indexterm> + <function>pg_ls_summariesdir</function> () + <returnvalue>setof record</returnvalue> + ( <parameter>name</parameter> <type>text</type>, + <parameter>size</parameter> <type>bigint</type>, + <parameter>modification</parameter> <type>timestamp with time zone</type> ) + </para> + <para> + Returns the name, size, and last modification time (mtime) of each + ordinary file in the server's WAL summaries directory + (<filename>pg_wal/summaries</filename>). Filenames beginning + with a dot, directories, and other special files are excluded. + </para> + <para> + This function is restricted to superusers and members of + the <literal>pg_monitor</literal> role by default, but other users can + be granted EXECUTE to run the function. + </para></entry> + </row> + + <row> + <entry role="func_table_entry"><para role="func_signature"> + <indexterm> <primary>pg_ls_archive_statusdir</primary> </indexterm> <function>pg_ls_archive_statusdir</function> () |