RedHat 7 安装PostgreSQL 10.5
系统环境
Redhat:
Version: 7.4.1708
Architecture: x86_64
Address:
10.127.1.11
User:
root
Uassword:
redhat
Postgresql:
version: 10
platform: Redhat Enterprise Linux 7
architecture: x86_64
Address:
10.127.1.11
User:
postgres
Uassword:
redhat
具体安装
- Install the repository RPM:
yum install https://download.postgresql.org/pub/repos/yum/10/redhat/rhel-7-x86_64/pgdg-redhat10-10-2.noarch.rpm
- Install the client packages:
yum install postgresql10
- Optionally install the server packages:
yum install postgresql10-server
- Optionally initialize the database and enable automatic start:
/usr/pgsql-10/bin/postgresql-10-setup initdb
systemctl enable postgresql-10
systemctl start postgresql-10
远程连接
- Modify user password
su - postgres
切换用户,执行后提示符会变为 '-bash-4.2$'
psql -U postgres
登录数据库,执行后提示符变为 'postgres=#'
ALTER USER postgres WITH PASSWORD 'postgres';
设置postgres用户密码为postgres
\q
退出数据库
- Open remote access
vim /var/lib/pgsql/10/data/postgresql.conf
修改#listen_addresses = 'localhost'
为 listen_addresses='*'
当然,此处'*'也可以改为任何你想开放的服务器IP
- Trusted remote connection
vim /var/lib/pgsql/10/data/pg_hba.conf
修改如下内容,信任指定服务器连接
# IPv4 local connections:
host all all 127.0.0.1/32 ident
host all all 0.0.0.0/0 (需要连接的服务器IP) md5
- Reboot service
systemctl restart postgresql-10
- Test connection
参考网子
https://www.postgresql.org/download/
RedHat 7 安装PostgreSQL 10.5的更多相关文章
- 在CentOS 7 / RHEL 7安装PostgreSQL 10
CentOS 到了7.x版本, PostgreSQL也来到了10.x版本. 前些天MySQL都直接跨到了8.0版本. 本文是一篇在CentOS 7.4上安装安装PostgreSQL 10.3 的教程. ...
- Ubuntu下编译安装postgreSQL 10.5
Ubuntu下编译安装postgreSQL 10.5 ubuntu 16.04 LTS系统postgreSQL 10.5 安装包准备 1.从PostgreSQL官网下载PostgreSQL的安装包 安 ...
- install postgresql 10 on redhat linux 7 Redhat 安装 postgresql 10
---恢复内容开始--- 1. install linux 2. 切换mirror a. 备份原来的repo 文件, [root@localhost ~]# mv /etc/yum.repos.d/ ...
- Redhat 7.2 编译安装PostgreSQL 10
1.环境说明 CentOS7.2 postgresql10.4 2.下载 postgresql的官方地址 https://www.postgresql.org/ftp/source/ 在下载列表中根据 ...
- Linux 安装 PostgreSQL
Linux 安装 PostgreSQL CentOS 7 安装 PostgreSQL 10 步骤 官网安装步骤,选择服务器和数据库版本,会给出相应的安装命令 # 安装 yum install -y h ...
- CentOS 7 安装、配置、使用 PostgreSQL 10 安装及基础配置
官网安装方法:https://www.postgresql.org/download/linux/redhat/ 卸载的话使用 yum remove 相应的安装 Install the reposit ...
- Ubuntu 18.04 下 PostgreSQL 10 的安装与基础配置
下载安装 在命令行执行如下语句: apt-get install postgresql-10 该指令会帮助你下载如下PostgreSQL组件: name |explain | ------------ ...
- Windows 10平台安装PostgreSQL 14.2详细教程
Windows 10平台安装postgreSQL 14.2.1,安装步骤很简单,基本上是点击下一步(next). 使用SQL Shell(psql)进行交互:使用pgAdmin工具进行管理. tips ...
- centos6.4下面安装postgresql以及客户端远程连接
一.安装 centos6.4服务器IP:192.168.220.131 window7客户端IP:192.168.199.218 在centos官网http://www.postgresql.org/ ...
随机推荐
- 开启Apache Server Status
开启Apache Server Status 发布时间:August 1, 2008 分类:Apache <DdZend工具提供下载> <PHP中MD5函数效率> Apache ...
- Linux 64位 CentOS下安装 Docker 容器,启动、停止
一.Docker简介 Docker 提供了一个可以运行你的应用程序的封套(envelope),或者说容器,是轻量级的“容器引擎+映像仓库”,在LXC(linux轻量级容器)的基础上构建,可以运行任何应 ...
- Android Studio 打包生成 APK
1. 第一步 Build -> Generate Signed APK 2. 之后会要求开发者输入相关的密钥文件和密码 如果有则找到对应的 .jks 文件输入密码完成相应操作,否则则创建一个对应 ...
- 每天一道剑指offer-二叉树的下一个结点1
题目 每天一道剑指offer-二叉树的下一个结点https://www.nowcoder.com/practice/ef068f602dde4d28aab2b210e859150a?tpId=13&a ...
- bzoj 5341: [Ctsc2018]暴力写挂
Description Solution 边分治+边分树合并 这个题很多做法都是启发式合并的复杂度的,都有点卡 以前有个套路叫做线段树合并优化启发式合并,消掉一个 \(log\) 这个题思路类似,建出 ...
- DelegatingFilterProxy类的作用
使用过springSecurity的朋友都知道,首先需要在web.xml进行以下配置 <filter> <filter-name>springSecurityFilterCha ...
- 线程池ThreadPoolExecutor使用原理
本文来源于翁舒航的博客,点击即可跳转原文观看!!!(被转载或者拷贝走的内容可能缺失图片.视频等原文的内容) 若网站将链接屏蔽,可直接拷贝原文链接到地址栏跳转观看,原文链接:https://www.cn ...
- Android开发之旅1:环境搭建及HelloWorld
——工欲善其事必先利其器 引言 本系列适合0基础的人员,因为我就是从0开始的,此系列记录我步入Android开发的一些经验分享,望与君共勉!作为Android队伍中的一个新人的我,如果有什么不对的地方 ...
- HDU2612(KB1-N)
Find a way Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total ...
- CodeForces765A
A. Neverending competitions time limit per test:2 seconds memory limit per test:512 megabytes input: ...