Home > Uncategorized > 如何找到PostgreSQL的数据存储位置

如何找到PostgreSQL的数据存储位置

每当需要重启一个PostgreSQL,都需要知道数据库在磁盘上的具体位置。在重启前,可以通过如下方法找到数据库在磁盘上的位置。

postgres=# show data_directory;
 data_directory
----------------
 /export/db/postgres
(1 row)</pre>
Categories: Uncategorized Tags:
  1. No comments yet.
  1. No trackbacks yet.