Re: Checkpoint gets stuck in mdsync

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Heikki Linnakangas <heikki(at)enterprisedb(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Checkpoint gets stuck in mdsync
Date: 2007-04-05 14:39:38
Message-ID: 27041.1175783978@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Heikki Linnakangas <heikki(at)enterprisedb(dot)com> writes:
> My proposed fix is to make a copy of pendingOpsTable before entering the
> loop. AbsorbFsyncRequest will put new requests to a fresh new
> pendingOpsTable, while the mdsync loop will drain the copy. I'll write a
> patch along those lines if there's no better ideas.

That sounds pretty ugly. Perhaps better is a "cycle ID" field added to
the table entries, assigned from a counter that's bumped before entering
the fsync loop. Then you could distinguish entries made before starting
the loop from those made after. One fine point is to not let
AbsorbFsyncRequest change the cycle ID on a pre-existing entry ...

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-04-05 14:47:18 Re: Bug in UTF8-Validation Code?
Previous Message Bruce Momjian 2007-04-05 14:25:25 Re: Interaction of PITR backups andBulkoperationsavoiding WAL