PostgreSQL database default location on Linux

后端 未结 8 1318
南笙
南笙 2020-12-12 12:56

What is the default directory where PostgreSQL will keep all databases on Linux?

8条回答
  •  悲&欢浪女
    2020-12-12 13:15

    On Centos 6.5/PostgreSQL 9.3:

    Change the value of "PGDATA=/var/lib/pgsql/data" to whatever location you want in the initial script file /etc/init.d/postgresql.

    Remember to chmod 700 and chown postgres:postgres to the new location and you're the boss.

提交回复
热议问题