DEV Community

Discussion on: PostgreSQL temp files usage

Collapse
 
stephen_price profile image
Stephen Price

You mentioned that you avoided using "pg_ls_tmpdir" in the query since it's new as of PG12, but the query is using it. Is there an earlier version of the query that does not use it?
I ask because I'm trying to wrap my head around which queries are eating up my temp space, and due to the fact that I'm running Aurora PostgreSQL in AWS RDS, I cannot use "pg_ls_tmpdir" (the "rds_superuser" permissions explicitly deny it).

Collapse
 
bolajiwahab profile image
Bolaji Wahab • Edited

Hi, I believe you mean pg_ls_dir and pg_stat_file? Both functions are restricted to only superusers by default but execute can be granted to any user by a superuser.
I am not totally conversant with rds_superuser so you might not be able to call these functions.