Re: posix_fadvise() and pg_receivexlog - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: posix_fadvise() and pg_receivexlog
Date
Msg-id 53E27B13.50506@vmware.com
Whole thread Raw
In response to posix_fadvise() and pg_receivexlog  (Fujii Masao <masao.fujii@gmail.com>)
Responses Re: posix_fadvise() and pg_receivexlog
List pgsql-hackers
On 08/06/2014 08:39 PM, Fujii Masao wrote:
> Hi,
>
> The WAL files that pg_receivexlog writes will not be re-read soon basically,
> so we can advise the OS to release any cached pages when WAL file is
> closed. I feel inclined to change pg_receivexlog that way. Thought?

-1. The OS should be smart enough to not thrash the cache by files that 
are written sequentially and never read. If we go down this path, we'd 
need to sprinkle posix_fadvises into many, many places.

Anyway, who are we to say that they won't be re-read soon? You might e.g 
have a secondary backup site where you copy the files received by 
pg_receivexlog, as soon as they're completed.

- Heikki




pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: posix_fadvise() and pg_receivexlog
Next
From: Fabien COELHO
Date:
Subject: Re: A worst case for qsort