yum安装postgresql

前端之家收集整理的这篇文章主要介绍了yum安装postgresql前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

1、Install the repository 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、Install the client packages:

yum install postgresql95

3、Optionally install the server packages:

yum install postgresql95-server

4、Optionally initialize the database and enable automatic start:

/usr/pgsql-9.5/bin/postgresql95-setup initdb@H_301_50@ systemctl enable postgresql-9.5@H_301_50@ systemctl start postgresql-9.5

5、Test:

su - postgres

$ psql

$\l

CREATE DATABASE myDb;

CREATE USER mytest CREATEDB LOGIN PASSWORD 'mytest';

GRANT ALL ON DATABASE myDb TO mytest;

原文链接:https://www.f2er.com/bash/389491.html

猜你在找的Bash相关文章