共计 2381 个字符,预计需要花费 6 分钟才能阅读完成。
运行的命令是 sudo systemctl restart postgresql-14 关键是好像说配置文件错误?但是我把文件从另一台正常的上面复制,也是错误。奇怪。另外问一下,主从好配置么。
Jul 08 00:54:48 ion-2 sudo[16228]: pam_unix(sudo:session): session opened for user root by root(uid=0) Jul 08 00:54:48 ion-2 polkitd[505]: Registered Authentication Agent for unix-process:16229:316737474 (system bus name :1.1915 [/usr/bin/pkttyagent –notify-fd 5 –fallback], object path /org/ Jul 08 00:54:48 ion-2 systemd[1]: Starting PostgreSQL 14 database server… — Subject: Unit postgresql-14.service has begun start-up — Defined-By: systemd — Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel — — Unit postgresql-14.service has begun starting up. Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: cat: /var/lib/pgsql/14/data//PG_VERSION: Permission denied Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: cat: /var/lib/pgsql/14/data//PG_VERSION: Permission denied Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: An old version of the database format was found. Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: You need to dump and reload before using PostgreSQL 14. Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: See /usr/share/doc/postgresql14-14.4/README.rpm-dist for more information. Jul 08 00:54:48 ion-2 systemd[1]: postgresql-14.service: control process exited, code=exited status=1 Jul 08 00:54:48 ion-2 systemd[1]: Failed to start PostgreSQL 14 database server. — Subject: Unit postgresql-14.service has failed — Defined-By: systemd — Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel — — Unit postgresql-14.service has failed. — — The result is failed. Jul 08 00:54:48 ion-2 systemd[1]: Unit postgresql-14.service entered failed state. Jul 08 00:54:48 ion-2 systemd[1]: postgresql-14.service failed. Jul 08 00:54:48 ion-2 polkitd[505]: Unregistered Authentication Agent for unix-process:16229:316737474 (system bus name :1.1915, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, l Jul 08 00:54:48 ion-2 sudo[16228]: pam_unix(sudo:session): session closed for user root |
网友回复:
注册 : 没用过 从一般的经验来说,先解决掉这个问题再看吧 Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: cat: /var/lib/pgsql/14/data//PG_VERSION: Permission denied Jul 08 00:54:48 ion-2 postgresql-14-check-db-dir[16235]: cat: /var/lib/pgsql/14/data//PG_VERSION: Permission denied
斌斌 : 只能看到权限问题几个字
sdqu: 奇怪的是,我 root 运行的,修改文件以前没问题,就很奇怪
清蒸三文鱼 : http://www.manongjc.com/detail/28-gyyapmgrlzwngdc.html [[email protected] pgsql]# chown -R postgres:postgres /data/pgsql/12/data [[email protected] pgsql]# chmod 0700 /data/pgsql/12/data 这样好像就行了。多谢。
斌斌 : 它在运行的时候会切换到低权限的用户
斌斌 : 主从还没研究明白,是有好几种模式么,同步异步?