silent0608

[其他] Centos6.4 用yum安装postgresql9.0

[root@localhost ~]# wget http://yum.postgresql.org/9.0/redhat/rhel-6-x86_64/pgdg-centos90-9.0-5.noarch.rpm

[root@localhost ~]# rpm -ivh pgdg-centos90-9.0-5.noarch.rpm

[root@localhost ~]# less /etc/yum.repos.d/pgdg-90-centos.repo  //确认repo

PostgreSQL依赖包删除

[root@localhost ~]# vi /etc/yum.repos.d/CentOS-Base.repo

[base]

exclude=postgresql*

[updates]

exclude=postgresql*

安装PostgreSQL

[root@localhost ~]# yum -y install postgresql postgresql-server postgresql-libs 


启动Postgresql

[root@localhost ~]# service postgresql-9.0 initdb //初始化postgresql

[root@localhost ~]# service postgresql-9.0 start

[root@localhost ~]# chkconfig postgresql-9.0 on


#1楼
发帖时间:2014-2-5   |   查看数:0   |   回复数:0
游客组