postgresql

yum install -y https://download.postgresql.org/pub/repos/yum/10/redhat/rhel-7-x86_64/pgdg-centos10-10-2.noarch.rpm

yum install -y postgresql10-server postgresql10-contrib
/usr/pgsql-10/bin/postgresql-10-setup initdb
systemctl enable postgresql-10
systemctl start postgresql-10
# vim /var/lib/pgsql/10/data/postgresql.conf
# listen_addresses
# vim /var/lib/pgsql/10/data/pg_hba.conf
# IPv4 local connections:

# su
- postgres # psql -U postgres # ALTER USER postgres with encrypted password 'abc123'; # \q # exit

 

posted @ 2020-02-03 08:52  慕沁  阅读(112)  评论(0)    收藏  举报