Re: Error on vacuum: xmin before relfrozenxid

From: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
To: Paolo Crosato <paolo(dot)crosato(at)gmail(dot)com>
Cc: Andres Freund <andres(at)anarazel(dot)de>, pgsql-general(at)lists(dot)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Error on vacuum: xmin before relfrozenxid
Date: 2018-05-24 06:30:05
Message-ID: 7D158CD1-E6FC-4A49-9FC2-15F1AC2A7A05@yandex-team.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

Hi!

> 24 мая 2018 г., в 0:55, Paolo Crosato <paolo(dot)crosato(at)gmail(dot)com> написал(а):
>
> 1) VACUUM FULL was issued after the first time the error occurred, and a couple of times later. CLUSTER was never run.
> 2) Several failovers tests were perfomed before the cluster was moved to production. However, before the move, the whole cluster was wiped, including all the application and monitoring users. After the db was moved to production, a couple of users were added without any problem.
> 3) No, even if the replication level is set to logical in postgresql.conf, we only use streaming replication.

I've encountered seemingly similar ERROR:
[ 2018-05-22 15:04:03.270 MSK ,,,281756,XX001 ]:ERROR: found xmin 747375134 from before relfrozenxid 2467346321
[ 2018-05-22 15:04:03.270 MSK ,,,281756,XX001 ]:CONTEXT: automatic vacuum of table "postgres.pg_catalog.pg_database"

Table pg_database, probably, was not changed anyhow for a long period of database exploitation.
Unfortunately, I've found out this only there were million of xids left and had to vacuum freeze db in single user mode asap. But, probably, I will be able to restore database from backups and inspect it, if necessary. Though first occurrence of this error was beyond recovery window.

Best regards, Andrey Borodin.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Lele Gaifax 2018-05-24 07:28:15 Parameter placeholders, $n vs ?
Previous Message David G. Johnston 2018-05-24 04:39:12 Re: Insert data if it is not existing

Browse pgsql-hackers by date

  From Date Subject
Next Message Chapman Flack 2018-05-24 06:30:23 Re: SPI/backend equivalent of extended-query Describe(statement)?
Previous Message Justin Pryzby 2018-05-24 05:19:15 Re: documentation fixes for partition pruning, round two