Re: posix_fadvise() and pg_receivexlog

From: Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: posix_fadvise() and pg_receivexlog
Date: 2014-08-06 18:59:31
Message-ID: 53E27B13.50506@vmware.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2014-08-06 19:13:52 Re: A worst case for qsort
Previous Message Robert Haas 2014-08-06 18:56:57 Re: posix_fadvise() and pg_receivexlog