CentOS7 yum安装、配置PostgreSQL 9.5
PostgreSQL 9.5安装
1、添加RPM
yum install https://download.postgresql.org/pub/repos/yum/9.5/redhat/rhel-7-x86_64/pgdg-centos95-9.5-2.noarch.rpm
2、安装PostgreSQL 9.5
yum install postgresql95-server postgresql95-contrib
3、初始化数据库
/usr/pgsql-9.5/bin/postgresql95-setup initdb
4、设置开机自启动
systemctl enable postgresql-9.5.service
5、启动服务
systemctl start postgresql-9.5.service
6、查看版本
psql --version

PostgreSQL 9.5安装配置
1、修改用户密码
su - postgres
psql -U postgres
ALTER USER postgres WITH PASSWORD '123456'
\q

2、开启远程访问
vi /var/lib/pgsql/9.5/data/postgresql.conf
修改#listen_addresses = 'localhost' 为 listen_addresses='*'
3、信任远程连接
vi /var/lib/pgsql/9.5/data/pg_hba.conf
修改如下内容,信任指定服务器连接
# IPv4 local connections:
host all all 127.0.0.1/32 ident
host all all 192.168.137.1/32(需要连接的服务器IP) trust

4、重启服务
systemctl restart postgresql-9.5.service
CentOS7 yum安装、配置PostgreSQL 9.5的更多相关文章
- centos7 yum安装配置redis 并设置密码
原文:https://www.cnblogs.com/fanlinglong/p/6635828.html centos7 yum安装配置redis 并设置密码 1.设置Redis的仓库地址 yum ...
- CentOS7 yum安装配置
一.安装必要包 yum install gcc 二.linux下安装 #下载 wget http://download.redis.io/releases/redis-3.0.0.tar.gz tar ...
- CentOS7 yum安装配置 drbd-84-utils (外部模式)
1 安装环境介绍 1.1 系统环境 内核:3.10.0-862.el7.x86_64 版本:CentOS Linux release 7.5.1804 (Core) 主服务器:hostname = ...
- centos7 yum安装配置redis
1.设置Redis的仓库地址 yum install epel-release 2.安装redis yum install redis 修改配置文件,监听所有的IP地址 vim /etc/redis. ...
- CentOS7 yum安装配置 +redis主从配置
一.安装必要包 yum install gcc 二.linux下安装 #下载 wget http://download.redis.io/releases/redis-3.0.0.tar.gz tar ...
- CentOS7 yum 安装配置 MySQL 5.7
1.配置yum源 # 下载mysql源安装包 wget http://dev.mysql.com/get/mysql57-community-release-el7-8.noarch.rpm # 安装 ...
- Centos7下安装配置Redsocks
Redsocks是一个开源的网络程序,代码依赖开源的libevent网络库.Redsocks允许你将所有TCP连接重定向到SOCKS或HTTPS代理,比如Shadowsocks(Centos7下安装配 ...
- centos7 yum安装MongoDB
centos7 yum安装MongoDB 原文博客地址http://xgs888.top/post/view?id=64 centos7 yum安装mongodb: 1:创建仓库 vi /etc/ ...
- CentOS7 yum 安装 Nginx最新版本
CentOS7 yum 安装 Nginx最新版本 下载对应当前系统版本的nginx包(package) # wget http://nginx.org/packages/centos/7/noarc ...
- centos7 rabbitmq安装/配置
原文:centos7 rabbitmq安装/配置 因为RabbitMQ是由erlang实现的,所以要先安装erlang再安装rabbitMQ 1.先配置yum软件源地址EPEL(EPEL是 ...
随机推荐
- Spring 使用介绍(五)—— AOP(一)
一.简单使用:Hello World实例 1.定义目标类 public interface Hello { void sayHello(); } public class HelloImpl impl ...
- SpringBoot2.0.3 + SpringSecurity5.0.6 + vue 前后端分离认证授权
新项目引入安全控制 项目中新近添加了Spring Security安全组件,前期没怎么用过,加之新版本少有参考,踩坑四天,终完成初步解决方案.其实很简单,Spring Security5相比之前版本少 ...
- mosquitto发布消息
./mosquitto_pub -t '$SYS/broker/clients/status/online' -m 1
- 一:Newtonsoft.Json 支持序列化与反序列化的.net 对象类型;
导航目录: Newtonsoft.Json 概述 一:Newtonsoft.Json 支持序列化与反序列化的.net 对象类型: 二:C#对象.集合.DataTable与Json内容互转示例: ...
- Codeforces551 C. GukiZ hates Boxes
二分答案 + 贪心 传送门:$>here<$ $Solution$ 二分时间+贪心验证.思维难度主要在验证上,然而坑人的点却在n的取值上.那么先来谈如何验证.在已知时间的条件下,能否用一种 ...
- Chessboard POJ - 2446(最大流 || 匹配)
there is a pair of integers (x, y) in each line, which represents a hole in the y-th row, the x-th c ...
- maven手动安装jar包到本地仓库,以ojdbc6为例
在做mybatis generator的中文注释实现时,感觉每次都要在配置文件中指定ojdbc6的位置太麻烦了,别人用也不方便,没有的还得自己去下,所以就想直接把ojdbc6打包到项目里,这样拿到就可 ...
- 【UOJ#236】[IOI2016]railroad(欧拉回路,最小生成树)
[UOJ#236][IOI2016]railroad(欧拉回路,最小生成树) 题面 UOJ 题解 把速度看成点,给定的路段看成边,那么现在就有了若干边,然后现在要补上若干边,以及一条\([inf,\) ...
- 【Luogu4707】重返现世(min-max容斥)
[Luogu4707]重返现世(min-max容斥) 题面 洛谷 求全集的\(k-max\)的期望 题解 \(min-max\)容斥的证明不难,只需要把所有元素排序之后考虑组合数的贡献,容斥系数先设出 ...
- CF285E Positions in Permutations(dp+容斥)
题意,给定n,k,求有多少排列是的 | p[i]-i |=1 的数量为k. Solution 直接dp会有很大的后效性. 所以我们考虑固定k个数字使得它们是合法的,所以我们设dp[i][j][0/1] ...