9

pgsql10启动失败,这是什么原因

 2 years ago
source link: https://www.oschina.net/question/4584830_2324060
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

pgsql10启动失败,这是什么原因

pgsql10重启后,就一直启动不了 报错代码如下:
postgresql-10.service - PostgreSQL 10 database server
Loaded: loaded (/usr/lib/systemd/system/postgresql-10.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Tue 2021-09-28 10:08:50 CST; 11s ago
Docs: https://www.postgresql.org/docs/10/static/
Process: 12890 ExecStart=/usr/pgsql-10/bin/postmaster -D PGDATA(code=exited,status=1/FAILURE)Process:12885ExecStartPre=/usr/pgsql−10/bin/postgresql−10−check−db−dirPGDATA(code=exited,status=1/FAILURE)Process:12885ExecStartPre=/usr/pgsql−10/bin/postgresql−10−check−db−dir{PGDATA} (code=exited, status=0/SUCCESS)
Main PID: 12890 (code=exited, status=1/FAILURE)

Sep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.270 CST [12890] LOG: listening on IPv4 address “0.0.0.0”, port 5432Sep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.270 CST [12890] LOG: listening on IPv6 address “::”, port 5432
Sep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.272 CST [12890] LOG: listening on Unix socket “/var/run/po….5432”Sep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.276 CST [12890] LOG: listening on Unix socket “/tmp/.s.PGSQL.5432”
Sep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.288 CST [12890] LOG: redirecting log output to logging col…rocessSep 28 10:08:50 instance-v8llngb0 postmaster[12890]: 2021-09-28 10:08:50.288 CST [12890] HINT: Future log output will appear in dir…”log”.Sep 28 10:08:50 instance-v8llngb0 systemd[1]: postgresql-10.service: main process exited, code=exited, status=1/FAILURE
Sep 28 10:08:50 instance-v8llngb0 systemd[1]: Failed to start PostgreSQL 10 database server.
Sep 28 10:08:50 instance-v8llngb0 systemd[1]: Unit postgresql-10.service entered failed state.
Sep 28 10:08:50 instance-v8llngb0 systemd[1]: postgresql-10.service failed.

报错原因看了下日志:
2021-09-28 13:51:30.457 CST [29540] LOG: could not stat file “pg_tblspc/16871”: No such file or directory
2021-09-28 13:51:30.457 CST [29540] LOG: could not stat file “pg_tblspc/18927”: No such file or directory
2021-09-28 13:51:30.457 CST [29540] LOG: could not stat file “pg_tblspc/16870”: No such file or directory
2021-09-28 13:51:30.457 CST [29540] LOG: could not open tablespace directory “pg_tblspc/16871/PG_10_201707211”: No such file or directory
2021-09-28 13:51:30.457 CST [29540] LOG: could not open tablespace directory “pg_tblspc/18927/PG_10_201707211”: No such file or directory
2021-09-28 13:51:30.457 CST [29540] LOG: could not open tablespace directory “pg_tblspc/16870/PG_10_201707211”: No such file or directory


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK