The idea behind the adminpack module is to give administrators a way to access the file system without SSH access. The package contains a couple of functions to make that possible.
To load the module into the database, run the following command:
test=# CREATE EXTENSION adminpack;CREATE EXTENSION
One of the most interesting features of the adminpack module is the ability to inspect log files. The pg_logdir_ls function checks out the log directory and returns a list of log files:
test=# SELECT * FROM pg_catalog.pg_logdir_ls() AS (a timestamp, b text);ERROR: the log_filename parameter must equal 'postgresql-%Y-%m-%d_%H%M%S.log'
The important thing here is that the log_filename parameter has to be adjusted to the adminspack ...