一、首先去官网下载相关的安装包

https://yum.postgresql.org/rpmchart.php

二、下载安装包

1. 最小的数据库服务器安装包:

postgresql96-9.6.-1PGDG.rhel7.x86_64.rpm
postgresql96-libs-9.6.-1PGDG.rhel7.x86_64.rpm
postgresql96-server-9.6.-1PGDG.rhel7.x86_64.rpm

2. 扩展的一个rpm包:

(可以根据你的需求自主选择扩展下载包)

postgresql96-devel-9.6.5-1PGDG.rhel7.x86_64.rpm

三、安装顺序如下:

. rpm -ivh postgresql96-libs-9.6.-1PGDG.rhel7.x86_64.rpm
. rpm -ivh postgresql96-9.6.-1PGDG.rhel7.x86_64.rpm
. rpm -ivh postgresql96-server-9.6.-1PGDG.rhel7.x86_64.rpm
. rpm -ivh postgresql96-devel-9.6.-1PGDG.rhel7.x86_64.rpm

四、启动测试

1. 首先必须初始化数据库

/usr/pgsql-9.6/bin/postgresql96-setup initdb

2. 运行

systemctl start postgresql-9.6

3. 添加开机启动

systemctl enable postgresql-9.6

rpm安装PostgreSQL的更多相关文章

  1. Centos7 yum安装postgresql 9.5

    添加RPM yum install https://download.postgresql.org/pub/repos/yum/9.5/redhat/rhel-7-x86_64/pgdg-centos ...

  2. Linux CentOS安装postgresql 9.4

    一.前言 PostgreSQL通常也简称Postgres,是一个关系型数据库管理系统,适用于各种Linux操作系统.Windows.Solaris.BSD和Mac OS X.PostgreSQL遵循P ...

  3. CentOS6.5下安装PostgreSQL

    一.配置 YUM 仓库 修改原始的 yum 仓库配置: vim /etc/yum.repos.d/CentOS-Base.repo 在[base]和[updates] 节(section)部分的尾部插 ...

  4. centos 6.4下安装postgresql 9.2

    我的linux版本是centos 6.4 ,准备安装postgresql 9.2 根据官方说明: http://www.postgresql.org/download/linux/redhat/ 缺省 ...

  5. 安装postgreSQL出现configure:error:readline library not found解决方法

    要安装 readline , readline-dev 开发包,要么使用 --without-readline 选项关闭 readline 功能. #yum install readline; #yu ...

  6. 在CentOS上编译安装PostgreSQL

    http://my.oschina.net/tashi/blog 第一步:准备阶段 获取必需软件包: CentOS中查看是否安装了某个软件的命令:rpm -qa | grep 软件名.which命令可 ...

  7. CentOS下安装postgresql

    一.说明 postgresql版本:9.4.1 安装包: postgresql94-server-9.4.1-1PGDG.rhel6.x86_64.rpm postgresql94-libs-9.4. ...

  8. CentOS安装postgresql 9.4

    第一步:在CentOS6.5下安装Postgresql 1. 安装PostgreSQL源 # yum install http://yum.postgresql.org/9.4/redhat/rhel ...

  9. CentOS 6.9下安装PostgreSQL

    操作系统:CentOS6.9_x64 PostgreSQL官方网址: https://www.postgresql.org/ 安装数据库 使用如下命令: yum install postgresql- ...

随机推荐

  1. vue-router各个属性的作用及用法

    vue-router是vue单页面开发的路由,就是决定页面跳转的! <router-link> 组件支持用户在具体有路由功能的应用中(点击)导航.通过to属性指定目标地址. Props 属 ...

  2. c语言中pthread的理解和使用

    在头文件中看到#typedef unsigned long int pthread_t这句话怎么理解,pthread_t是一个什么类型呢? 相当于pthread_t实际是个unsigned long  ...

  3. 一直出现 Enter passphrase for key '/root/.ssh/gitkey12.pub'

    案例: 我一下没有设置密码的pub key, 一使用就要求: Enter passphrase for key '/root/.ssh/gitkey12.pub',   原因:本该设置私钥的地方,设置 ...

  4. matlab中,怎样把矩阵中所有的0改为2

    一句话搞定:>> a(find(a==0))=[2]:把矩阵中所有的0改为2

  5. android中的数据库操作(SQLite)

    android中的数据库操作 android中的应用开发很难避免不去使用数据库,这次就和大家聊聊android中的数据库操作. 一.android内的数据库的基础知识介绍 1.用了什么数据库   an ...

  6. JavaScript 之 parseInt

    首先还是从很热门的实例parseInt("09")==0说起. parseInt(numString, [radix])这个函数后面如果不跟第2个参数来表示进制的话,默认是10进制 ...

  7. 调整UIPickerView高度

    Advantages: Makes setFrame of UIPickerView behave like it should No transform code within your UIVie ...

  8. [SQL]查询某一个字段在某一段时期数据库中使用到的记录

    有些时候我们常常须要哪里用到了一些表,又或者什么时候运行了某一个存储过程.整理出了在某段时期内数据库运行的sql查询.也能够查询到数据库中某些字段的存放处.非常好非常强大.希望能帮到大家~ SELEC ...

  9. 算法笔记_168:历届试题 矩阵翻硬币(Java)

    目录 1 问题描述 2 解决方案   1 问题描述 问题描述 小明先把硬币摆成了一个 n 行 m 列的矩阵. 随后,小明对每一个硬币分别进行一次 Q 操作. 对第x行第y列的硬币进行 Q 操作的定义: ...

  10. sql server 2008分页

    SELECT id, name, staffopenid, imageurl, content, ordernum, praisenum, createdate, lable, label2, man ...