Re: Cannot start the postgres service - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: Cannot start the postgres service
Date
Msg-id 20091014165603.GC4902@alvh.no-ip.org
Whole thread Raw
In response to Re: Cannot start the postgres service  (Mitesh51 <mit_bca1@yahoo.com>)
Responses Re: Cannot start the postgres service
List pgsql-general
Mitesh51 wrote:

> I had 2 approach in my mind...to sync up transaction log files with specific
> full backup
>
> 1) to keep only time relavent files in pg_xlog dir and move other files to
> archive dir with code which is not a good idea as u suggest

Postgres is prepared to (and assumes it can) reuse and delete files in
pg_xlog.  If you need a copy you can use for your own purposes, you MUST
get it through an archive_command.  You MUST NOT fiddle with the files
in pg_xlog directly.

Also note that your archive_command needs to create a separate copy of
the file.  Hardlinks are not allowed, because the file might get
rewritten by Postgres later.  Moving (mv) the original files is not
allowed either for the same reason.  Postgres will leave the file alone
until it has been archived, and assumes it can do whatever it pleases
with it as soon as the archiver has returned success (exit code 0).

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

pgsql-general by date:

Previous
From: "Chris Spotts"
Date:
Subject: Re: How ad an increasing index to a query result?
Next
From: Reid Thompson
Date:
Subject: Re: Partitioned table question