Skip to main content
added list of folders I had to create to get pg start properly
Source Link
bachr
  • 101
  • 1

I had similar issue, sometimes the pg directories somehow don't get created correctly so I've end up creating them manually by doing:

$ pg_ctl -D /usr/local/share/c3/postgres/data$PGDATA start

This will fail with some random logs like

2019-08-05 14:18:50.120 PDT [12307] LOG:  could not open directory "pg_snapshots": No such file or directory

So you need to manually create this pg_snapshots folder under $PGDATA (e.g. /usr/local/share/c3/postgres/data).

Doing this iteratively until all needed files are created solved the problem for me. Those are the files I've endup creating:

  • pg_tblspc
  • pg_replslot
  • pg_twophase
  • pg_stat
  • pg_commit_ts
  • pg_logical/snapshots
  • pg_logical/mappings

I had similar issue, sometimes the pg directories somehow don't get created correctly so I've end up creating them manually by doing:

$ pg_ctl -D /usr/local/share/c3/postgres/data start

This will fail with some random logs like

2019-08-05 14:18:50.120 PDT [12307] LOG:  could not open directory "pg_snapshots": No such file or directory

So you need to manually create this pg_snapshots folder under /usr/local/share/c3/postgres/data.

Doing this iteratively until all needed files are created solved the problem for me.

I had similar issue, sometimes the pg directories somehow don't get created correctly so I've end up creating them manually by doing:

$ pg_ctl -D $PGDATA start

This will fail with some random logs like

2019-08-05 14:18:50.120 PDT [12307] LOG:  could not open directory "pg_snapshots": No such file or directory

So you need to manually create this pg_snapshots folder under $PGDATA (e.g. /usr/local/share/postgres/data).

Doing this iteratively until all needed files are created solved the problem for me. Those are the files I've endup creating:

  • pg_tblspc
  • pg_replslot
  • pg_twophase
  • pg_stat
  • pg_commit_ts
  • pg_logical/snapshots
  • pg_logical/mappings
Source Link
bachr
  • 101
  • 1

I had similar issue, sometimes the pg directories somehow don't get created correctly so I've end up creating them manually by doing:

$ pg_ctl -D /usr/local/share/c3/postgres/data start

This will fail with some random logs like

2019-08-05 14:18:50.120 PDT [12307] LOG:  could not open directory "pg_snapshots": No such file or directory

So you need to manually create this pg_snapshots folder under /usr/local/share/c3/postgres/data.

Doing this iteratively until all needed files are created solved the problem for me.