安装postgresql
直接yum安装 yum install postgresql
若失败试试
rpm -i http://yum.postgresql.org/9.1/redhat/rhel-6-x86_64/pgdg-redhat91-9.1-5.noarch.rpm
再输入 yum install postgresql91-server postgresql91-contrib
service postgresql-9.1 initdb
chkconfig postgresql-9.1 on
验证安装成功:一种:netstat -anp
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN 2447/postmaster
第二种:su postgres 登陆是否成功。
安装phppgadmin
安装包 yum install php-pgsql
下载phppgadmin放在var/www/html目录下
重启apache service httpd restart
打开localhost/phpPgAdmin查看是否安装成功
打开数据库: psql -U postgres -h localhost
若phppgadmin登陆不上,修改 /var/lib/pgsql/9.1/data/pg_hba.conf 最底下的 host all all 127.0.0.1/32 peer 的peer为trust
安装过程轻松愉快
本文介绍如何在Linux环境下安装PostgreSQL数据库及其管理工具phpPgAdmin,包括使用yum及rpm进行PostgreSQL安装的方法,以及配置数据库服务启动、验证安装成功的方式。同时,还提供了安装phpPgAdmin并进行相关配置的具体步骤。
1256

被折叠的 条评论
为什么被折叠?



