Find wal file details and its size
-- List down all the wal files present in pg_wal
postgresql configurationintermediate
by PostgreSQL
13 views
-- List down all the wal files present in pg_wal
1234567891011121314151617181920212223
postgres=#
select * from pg_ls_waldir();
name           | size   | modification
------------------------------------------+----------+---------------------------
0000000100000079000000D5 | 16777216 | 22-APR-22 20:51:26 +03:00
0000000100000079000000D8 | 16777216 | 22-APR-22 20:39:33 +03:00
0000000100000079000000D6 | 16777216 | 22-APR-22 20:07:40 +03:00
0000000100000079000000D9 | 16777216 | 22-APR-22 20:47:21 +03:00
0000000100000079000000D7 | 16777216 | 22-APR-22 20:21:45 +03:00
00000001000000790000005C.00005BC8.backup | 323 | 21-APR-22 10:14:40 +03:00
(6 rows)
postgres=#
select sum(size) from pg_ls_waldir();
sum
----------
83886403
(1 row)
postgres=#
select pg_current_wal_insert_lsn(),pg_current_wal_lsn();
pg_current_wal_insert_lsn | pg_current_wal_lsn
---------------------------+--------------------
79/D5980480Â Â Â Â Â Â Â Â | 79/D5980480
(1 row)Please to add comments
No comments yet. Be the first to comment!