CentOS 安装 PostgreSQL 9.2
来源:互联网 发布:绿萼梅 知乎 编辑:程序博客网 时间:2024/05/18 00:23
1 到官方下载CentOS版的最新版
下载:postgres-9.2.1-1.i386.openscg.rpm
地址:http://www.openscg.com/se/postgresql/packages.jsp
命令:cd /root
wget http://oscg-downloads.s3.amazonaws.com/packages/postgres-9.2.1-1.i386.openscg.rpm
2 安装PSQL
rpm -ivh postgres-9.2.1-1.i386.openscg.rpm
等待安装完毕即可
3 配置远程连接
默认下,PSQL是不可以远程连接的,需要变更两个配置文件。
默认安装的data路径在/opt/postgres/9.2/data/
# cd /opt/postgres/9.2/data/
Pg_hba.conf
# vi pg_hba.conf
在文件host all all 127.0.0.1/32 md5行下添加以下配置,或者直接将这一行修改为红色部分
# IPv4 local connections:
host all all 127.0.0.1/32 md5
host all all 0.0.0.0/0 md5
:wq
如果不希望允许所有IP远程访问,则可以将上述配置项中的0.0.0.0设定为指定的IP值。
如设IP段:192.168.1.1/24 能访问。
postgresql.conf
# vi postgresql.conf
将该文件中的listen_addresses项值设定为“*”
:wq
重启PSQL服务
# service postgres-9.2-openscgstop
# service postgres-9.2-openscgstart
4 Windows客户端工具
直接使用官方windows版本的安装包安装即可,里面自带一个不错的客户端。
- CentOS 安装 PostgreSQL 9.2
- CentOS下安装postgresql
- centos 下安装postgresql
- centos安装psotgis+postgresql
- CentOS下安装PostgreSQL
- centos 安装postgresql
- CentOS 安装PostgreSQL 9.1
- CentOS安装PostgreSQL数据库
- centos 安装postgreSQL
- CentOS安装PostgreSQL 9.4
- centos 安装postgresql
- centos 下 PostgreSql安装
- CentOS 7 安装 PostgreSQL
- centos 操作系统 安装 postgresql-9.4 postgresql-9.3
- CentOS从源码安装PostgreSQL
- CentOS下源码安装PostgreSQL
- CentOS下,yum安装PostgreSQL
- CentOS下安装postgresql 9.4
- 【网络】HTTP中GET和POST方法的区别
- 你真的有工作经验吗?
- 硬件工程师基础知识
- 八大技巧精通JDBC连接Oracle数据库
- php实现页面跳转的几种方法
- CentOS 安装 PostgreSQL 9.2
- 双向队列(动态数组实现)
- apr动态加载.dll和.so
- 图解SQL的Join(转)
- C# 使用Get,Post,Soap方式调用WebService
- 构造函数调用构造函数
- igt 三色排序问题
- Android高手进阶教程(四)之----Android 中自定义属性(attr.xml,TypedArray)的使用! .
- linux 内存管理 - paging_init 函数