February 2020
Intermediate to advanced
734 pages
38h 13m
English
Assuming our logs are located at /db/pgdata/pg_log, follow these steps to examine the checkpoint activity:
ls -lt /db/pgdata/pg_log/postgres*.log | head -n 1
grep checkpoint /db/pgdata/pg_log/postgresql-2019-10-16.log
grep 'checkpoint complete:' \
/db/pgdata/pg_log/postgresql-2019-10-16.log \
| sed 's/.* sync=/sync=/;' \
| sed 's/total=[0-9.]* s; //; s/; dist.*//;' \
| sort -n | tail -n 5
Read now
Unlock full access