
correlation https://teguhth.blogspot.com/2024/02/enable-pgaudit-pgauditlogtofile-in.html
https://teguhth.blogspot.com/2024/04/convert-pgaudit-pgauditlogtofile-log.html
1. config postgresql.conf & restart systemctl restart postgresql-18
listen_addresses='*'
shared_preload_libraries = 'pgaudit,pgauditlogtofile'
pgaudit.log_exclude = 'pg_catalog,information_schema'
pgaudit.log_directory = '/var/lib/pgsql/18/data/log'
pgaudit.log_filename = 'pgaudit-teguhth.log'
pgaudit.log = 'write,ddl,role'
#pgaudit.log = 'all'
pgaudit.log_catalog = off
pgaudit.log_relation = on
pgaudit.log_statement = on
pgaudit.log_parameter = off
pgaudit.log_rows = off
pgaudit.log_execution_time = off
pgaudit.log_execution_memory = off
# pgaudit.log_format = csv



.jpeg)








.jpeg)











