Last active
May 23, 2022 22:16
-
-
Save ajsharma/56e6e011a66a67bc0a568c745b424daf to your computer and use it in GitHub Desktop.
How to tail Homebrew Postgres logs in terminal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# File located at /opt/homebrew/var/postgres/postgresql.conf | |
# Find `log_statement` and set it to 'all'. | |
log_statement = 'all' | |
# Postgres must be restarted before changes take effect. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# After updating config, run | |
brew services restart postgresql | |
# Then, to follow the logs | |
tail -f /opt/homebrew/var/log/postgres.log |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment