我已经在Centos 6.4 64位上安装了Postgres 8.4。我想用yun安装的phpPgAdmin-5.0.4-1管理Postgres数据库(如MySQL和phpMyadmmin)安装phpPgAdmin-5.0.4-1后,我无法通过访问192.168.7.4/ phpPgAdmin / (192.168.7.4是我的Centos服务器)登录到phpPgAdmin,它总是显示“登录失败”,虽然我确定我输入了用户名(postgres)和密码,希望你能帮助我:
netstat -tupln | grep postmaster
tcp 0 0 0.0.0.0:5432 0.0.0.0:* LISTEN 771/postmaster
tcp 0 0 :::5432 :::* LISTEN 771/postmaster
/etc/phpPgAdmin/config.inc.php
$conf['servers'][0]['desc'] = 'PostgreSQL';
$conf['servers'][0]['host'] = '192.168.7.4';
$conf['extra_login_security'] = false;
/var/lib/pgsql/data/postgresql.conf
listen_addresses = '*'
/var/lib/pgsql/data/pg_hba.conf
local all all ident
# IPv4 local connections:
host all all 127.0.0.1/32 ident
# IPv6 local connections:
host all all ::1/128 ident提前谢谢。
发布于 2018-03-17 20:03:29
我尝试了上面的解决方案,但仍然收到“登录失败”的消息。为了解决这个问题,我必须确保在pg_hba.conf文件中将IPv6设置为password。这样做:vi /var/lib/pgsql/9.4/data/pg_hba.conf并进行相应的编辑。然后重启httpd和postgresql (不管你使用的是什么版本)
https://stackoverflow.com/questions/23194369
复制相似问题