Re: minor bug
Laurenz Albe <laurenz.albe@cybertec.at>
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Torsten Förtsch <tfoertsch123@gmail.com>, pgsql-hackers@postgresql.org
Date: 2023-01-17T09:42:03Z
Lists: pgsql-hackers, pgsql-general
Attachments
- 0001-Don-t-show-bogus-recovery-stop-time.patch (text/x-patch) patch 0001
On Mon, 2023-01-16 at 19:59 +0100, Torsten Förtsch wrote: > not sure if this is known behavior. > > Server version is 14.6 (Debian 14.6-1.pgdg110+1). > > In a PITR setup I have these settings: > > recovery_target_xid = '852381' > recovery_target_inclusive = 'false' > > In the log file I see this message: > > LOG: recovery stopping before commit of transaction 852381, time 2000-01-01 00:00:00+00 > > But: > > postgres=# select * from pg_last_committed_xact(); > xid | timestamp | roident > --------+-------------------------------+--------- > 852380 | 2023-01-16 18:00:35.054495+00 | 0 > > So, the timestamp displayed in the log message is certainly wrong. Redirected to -hackers. If recovery stops at a WAL record that has no timestamp, you get this bogus recovery stop time. I think we should show the recovery stop time only if time was the target, as in the attached patch. Yours, Laurenz Albe
Commits
-
Log the correct ending timestamp in recovery_target_xid mode.
- abe203304e15 15.2 landed
- 87591db1918a 12.14 landed
- 44e9e34266ef 16.0 landed
- 1b9a0b96a870 13.10 landed
- 103450724557 14.7 landed
- 0a269527f6a1 11.19 landed