| From: | Andres Freund <andres(at)anarazel(dot)de> | 
|---|---|
| To: | Robert Haas <robertmhaas(at)gmail(dot)com> | 
| Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Greg Stark <gsstark(at)mit(dot)edu>, pgsql-hackers(at)postgresql(dot)org, pgsql-performance(at)postgresql(dot)org, Michael Clemmons <glassresistor(at)gmail(dot)com>, Hannu Krosing <hannu(at)2ndquadrant(dot)com>, Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com> | 
| Subject: | Re: [HACKERS] Re: Faster CREATE DATABASE by delaying fsync (was 8.4.1 ubuntu karmic slow createdb) | 
| Date: | 2010-02-02 18:34:07 | 
| Message-ID: | 201002021934.18444.andres@anarazel.de | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers pgsql-performance | 
On Tuesday 02 February 2010 19:14:40 Robert Haas wrote:
> On Tue, Feb 2, 2010 at 12:50 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> > Andres Freund <andres(at)anarazel(dot)de> writes:
> >> On Tuesday 02 February 2010 18:36:12 Robert Haas wrote:
> >>> I took a look at this patch today and I agree with Tom that
> >>> pg_fsync_start() is a very confusing name.  I don't know what the
> >>> right name is, but this doesn't fsync so I don't think it shuld have
> >>> fsync in the name.  Maybe something like pg_advise_abandon() or
> >>> pg_abandon_cache().  The current name is really wishful thinking:
> >>> you're hoping that it will make the kernel start the fsync, but it
> >>> might not.  I think pg_start_data_flush() is similarly optimistic.
> >> 
> >> What about: pg_fsync_prepare().
> > 
> > prepare_for_fsync()?
> 
> It still seems mis-descriptive to me.  Couldn't the same routine be
> used simply to abandon undirtied data that we no longer care about
> caching?
For now it could - but it very well might be converted to sync_file_range or 
similar, which would have different "sideeffects".
As the potential code duplication is rather small I would prefer to describe 
the prime effect not the sideeffects...
Andres
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Bruce Momjian | 2010-02-02 18:48:20 | Personal Copyright Notices | 
| Previous Message | Heikki Linnakangas | 2010-02-02 18:27:17 | Re: Hot Standby: Relation-specific deferred conflict resolution | 
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Matt White | 2010-02-02 19:03:42 | Re: Slow-ish Query Needs Some Love | 
| Previous Message | Mridula Mahadevan | 2010-02-02 18:17:15 | Queries within a function |