我使用 PostgreSQL 9.2 并有命令:
psql -h localhost -U testdb -d postgis
此命令具有无需密码即可连接数据库的能力。我想输入密码。
我pg_hba.cconf
的是:
local all all password
# IPv4 local connections:
host all all 127.0.0.1/32 md5
# IPv6 local connections:
host all all ::1/128 md5