Re: pg_xlog becomes extremely large during CREATE INDEX - Mailing list pgsql-general

From Tom Lane
Subject Re: pg_xlog becomes extremely large during CREATE INDEX
Date
Msg-id 2971.1084418321@sss.pgh.pa.us
Whole thread Raw
In response to pg_xlog becomes extremely large during CREATE INDEX  ("Jeffrey W. Baker" <jwbaker@acm.org>)
Responses Re: pg_xlog becomes extremely large during CREATE INDEX
List pgsql-general
"Jeffrey W. Baker" <jwbaker@acm.org> writes:
> I have configured 24 checkpoint segments,
> which I expect gives me a worst-case usage in pg_xlog of 384MB.
> Unfortunately, during the CREATE INDEX, pg_xlog becomes full!

Postgres version?  AFAIR 7.1.2 or thereabouts would act that way,
because it wouldn't discard log segments containing work of open
transactions.

The only reason I can think of for such behavior in a current version
is if the checkpoint isn't completing for some reason.  Have you looked
in the postmaster log to see if checkpoint is bleating about anything?

Note that your calculation is off anyway: per documentation, recent
versions will allow up to 2*checkpoint_segments+1 WAL files to exist.
This is because we save the last two checkpoints worth of data.

            regards, tom lane

pgsql-general by date:

Previous
From: "Jeffrey W. Baker"
Date:
Subject: pg_xlog becomes extremely large during CREATE INDEX
Next
From: Dennis Gearon
Date:
Subject: Functionality in database or external langauge