Where are the files for a PostgreSQL database stored?
Postgresql – Where does PostgreSQL store the database
postgresql
Related Topic
- Sql – Save PL/pgSQL output from PostgreSQL to a CSV file
- Postgresql – How to drop all the tables in a PostgreSQL database
- Postgresql – How to drop a PostgreSQL database if there are active connections to it
- Postgresql – How to exit from PostgreSQL command line utility: psql
- PostgreSQL error: Fatal: role “username” does not exist
- Postgresql – How to change PostgreSQL user password
- Postgresql – Which version of PostgreSQL am I running
- Postgresql – psql: FATAL: database “
” does not exist
Best Answer
To see where the data directory is, use this query.
To see all the run-time parameters, use
You can create tablespaces to store database objects in other parts of the filesystem. To see tablespaces, which might not be in that data directory, use this query.