Обсуждение: ERROR: subxact logged without previous toplevel record

Поиск
Список
Период
Сортировка

ERROR: subxact logged without previous toplevel record

От
Euler Taveira
Дата:
Hi,

I got the $SUBJECT error in a logical replication setup. Both versions
are 10.3. I remembered that some bugs in the piece of code around this
error were fixed in 9.6 but it seems not all of them. Unfortunately I
don't have a test case. All DEBUG3 messages from an unsuccessful
replication attempt are attached. The last few messages from the
logical replication role are:

2018-05-15 15:24:05 -03 [31783]: [474-1]  DEBUG:  purged committed
transactions from 63 to 63, xmin: 124517330, xmax: 124615171
2018-05-15 15:24:05 -03 [31783]: [475-1]  DEBUG:  xmin: 124517330,
xmax: 124615171, oldestrunning: 124517330
2018-05-15 15:24:05 -03 [31783]: [476-1]  DEBUG:  failed to increase
restart lsn: proposed 4C9/C9CC0938, after 4CA/8592A90, current
candidate 4C9/C9CC0938, current after 4C9/D0FF05A8, flushed up to
4CA/9A8D138
2018-05-15 15:24:05 -03 [31783]: [477-1]  DEBUG:  spill 4096 changes
in XID 124557507 to disk
2018-05-15 15:24:05 -03 [31783]: [478-1]  ERROR:  subxact logged
without previous toplevel record


-- 
   Euler Taveira                                   Timbira -
http://www.timbira.com.br/
   PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento

Вложения

Re: ERROR: subxact logged without previous toplevel record

От
Alvaro Herrera
Дата:
On 2018-May-15, Euler Taveira wrote:

> I got the $SUBJECT error in a logical replication setup. Both versions
> are 10.3. I remembered that some bugs in the piece of code around this
> error were fixed in 9.6 but it seems not all of them. Unfortunately I
> don't have a test case. All DEBUG3 messages from an unsuccessful
> replication attempt are attached. The last few messages from the
> logical replication role are:
> 
> 2018-05-15 15:24:05 -03 [31783]: [474-1]  DEBUG:  purged committed
> transactions from 63 to 63, xmin: 124517330, xmax: 124615171
> 2018-05-15 15:24:05 -03 [31783]: [475-1]  DEBUG:  xmin: 124517330,
> xmax: 124615171, oldestrunning: 124517330
> 2018-05-15 15:24:05 -03 [31783]: [476-1]  DEBUG:  failed to increase
> restart lsn: proposed 4C9/C9CC0938, after 4CA/8592A90, current
> candidate 4C9/C9CC0938, current after 4C9/D0FF05A8, flushed up to
> 4CA/9A8D138
> 2018-05-15 15:24:05 -03 [31783]: [477-1]  DEBUG:  spill 4096 changes
> in XID 124557507 to disk
> 2018-05-15 15:24:05 -03 [31783]: [478-1]  ERROR:  subxact logged
> without previous toplevel record

Hello

Can you find in pg_waldump all the records for this transaction,
xid=124557507?

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


Re: ERROR: subxact logged without previous toplevel record

От
Euler Taveira
Дата:
2018-05-15 16:08 GMT-03:00 Alvaro Herrera <alvherre@2ndquadrant.com>:
> Can you find in pg_waldump all the records for this transaction,
> xid=124557507?
>
I don't know this ML size limit but it seems huge to attach at this
email (~900 kb gzipped). Grab it at [1].


[1] http://apinaye.timbira.com.br/~euler/tmp/txid-124557507.txt.gz


-- 
   Euler Taveira                                   Timbira -
http://www.timbira.com.br/
   PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento


Re: ERROR: subxact logged without previous toplevel record

От
Euler Taveira
Дата:
2018-05-15 16:43 GMT-03:00 Euler Taveira <euler@timbira.com.br>:
> 2018-05-15 16:08 GMT-03:00 Alvaro Herrera <alvherre@2ndquadrant.com>:
>> Can you find in pg_waldump all the records for this transaction,
>> xid=124557507?
>>
> I don't know this ML size limit but it seems huge to attach at this
> email (~900 kb gzipped). Grab it at [1].
>
I forgot to mention that I have 16 replicas subscribed at the same
publication. This problematic replica was setup only 10 minutes after
the error. All of the other replicas are working fine since they were
setup a few days ago. I am thinking if it is somewhat related to the
replication start point.


-- 
   Euler Taveira                                   Timbira -
http://www.timbira.com.br/
   PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento