CentOs7 安装 PostgreSQL 12
2020-09-01 本文已影响0人
啊深是阿深啊
#安装存储库RPM:
yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
# 安装PostgreSQL:
yum install -y postgresql12-server
#(可选)初始化数据库
/usr/pgsql-12/bin/postgresql-12-setup initdb
# 设置开机启动项
systemctl enable postgresql-12
systemctl start postgresql-12