修改设定参数postgresql.conf及pg_hba.conf
vi /export/home/postgres/data/postgresql.conf
修改下列参数
tcpip_socket = true
max_connections = 256
shared_buffers = 1024
vi /var/lib/pgsql/data/pg_hba.conf
加入下面二行
local all all trust
host all all 127.0.0.1 255.255.255.255 trust
原文提到如果您的系统支持IPv6则可加入(不支持建议不要增加)
host all all ::1 ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff trust
以 postgres 用户登录,
# su - postgre
建立数据库目录:
$ mkdir data