我想看看PostgreSQL日志文件,看看我的应用程序写了什么,但我找不到它们。
有什么想法吗?
发布于 2010-04-03 07:47:22
在OS X上,如果您使用的是PostgreSQL的EnterpriseDB安装,您的日志文件将位于/Library/PostgreSQL/8.4/data/pg_log
中
当然,无论您运行的是哪个版本号,您都希望替换为8.4。
发布于 2015-06-20 09:41:44
在OSX Homebrew安装中,可以在以下位置找到日志:
/usr/local/var/log/postgres.log
或用于旧版本的postgres (< 9.6)
/usr/local/var/postgres/server.log
发布于 2010-04-02 04:46:57
只需询问您的数据库:
SELECT
*
FROM
pg_settings
WHERE
category IN( 'Reporting and Logging / Where to Log' , 'File Locations')
ORDER BY
category,
name;
在我的例子中,它在"/Library/PostgreSQL/8.4/data/pg_log“中。
https://stackoverflow.com/questions/2563494
复制相似问题