Re: Data loss, vacuum, transaction wrap-around

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql(at)mohawksoft(dot)com
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Data loss, vacuum, transaction wrap-around
Date: 2005-02-18 18:43:40
Message-ID: 19990.1108752220@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

pgsql(at)mohawksoft(dot)com writes:
> More suggestions:
> (1) At startup, postmaster checks for an XID, if it is close to a problem,
> force a vacuum.

Useless to a system that's run 24x7; also presumes the existence of a
complete solution anyway (since getting the postmaster to find that out
is the hard part).

> (2) At "sig term" shutdown, can the postmaster start a vacuum?

Certainly not. We have to assume that SIGTERM means we are under a
short-term sentence of death from init. And if it's a manual stop
it doesn't sound much better: the sort of DBA that needs this "feature"
is likely to decide he should kill -9 the postmaster because it's taking
too long to shut down.

> (3) When the XID count goes past the "trip wire" can it spontaneously
> issue a vacuum?

Only in the database you're connected to, which very likely isn't where
the problem is. Moreover, having N backends all decide they need to do
this at once doesn't sound like a winner. Furthermore, this still
presumes the existence of the hard part of the solution, which is
knowing where the trip point is.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Joshua D. Drake 2005-02-18 19:11:20 Re: Data loss, vacuum, transaction wrap-around
Previous Message Tom Lane 2005-02-18 18:37:14 Re: Data loss, vacuum, transaction wrap-around