https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm yum install postgresql13-contrib postgresql13-server -y /usr/pgsql-13/bin/postgresql-13-setup initdb vi /var/lib/pgsql/13/data/postgresql.conf vi /var/lib/pgsql/13/data/pg_hba.conf sudo systemctl start postgresql-13 sudo systemctl enable postgresql-13.service sudo su - postgres alter user postgres with password ‘password‘; SHOW config_file; vi /var/lib/pgsql/13/data/postgresql.conf; log_min_duration_statement = 100 service postgresql-13 reload
原文:https://www.cnblogs.com/yubs/p/14771369.html