Re: please explain vacuum with WAL

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Dmitry Melekhov <dm(at)belkam(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: please explain vacuum with WAL
Date: 2008-07-08 09:21:01
Message-ID: 1215508861.4051.757.camel@ebony.site
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-novice


On Tue, 2008-07-08 at 13:54 +0500, Dmitry Melekhov wrote:

> > What do you mean "WAL is enabled"? That's not a term I recognize
> since
> > WAL is always enabled.
> >
> >
> AFAIK, it can be disabled. May be I'm wrong...

Maybe you mean archiving? That *can* be disabled.

> > Best read this
> >
> http://developer.postgresql.org/pgdocs/postgres/routine-vacuuming.html
> >
> > VACUUM needs to perform writes to clear up, which generates WAL.
> >
> >
> This is what I don't understand.
> I think WAL can be used for point-in-time recovery.
> So, if I have database backup and WAL generated after this backup, I
> can
> do recovery, this mean WAL already contains all changes to database,
> without vacuum. Could you tell me what is wrong in my sentence?

Vacuum performs an essential function and its changes are WAL-logged.
Those changes are an essential part of the structure of the database and
must be included as part of recovery also.

If you think PostgreSQL is somehow different to Oracle, read up on
Deferred Block Cleanout and how SELECT statements can cause additional
redo writes.

--
Simon Riggs www.2ndQuadrant.com
PostgreSQL Training, Services and Support

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dmitry Melekhov 2008-07-08 09:22:35 Re: please explain vacuum with WAL
Previous Message Dmitry Melekhov 2008-07-08 09:17:03 Re: please explain vacuum with WAL

Browse pgsql-novice by date

  From Date Subject
Next Message Dmitry Melekhov 2008-07-08 09:22:35 Re: please explain vacuum with WAL
Previous Message Dmitry Melekhov 2008-07-08 08:54:57 Re: please explain vacuum with WAL