pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@2ndquadrant.com>
To: KONDO Mitsumasa <kondo.mitsumasa@lab.ntt.co.jp>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Heikki Linnakangas <hlinnakangas@vmware.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: Improvement of checkpoint IO scheduler for stable transaction responses
Date: Wed, 3 Jul 2013 15:39:43 +0200
Message-ID: <20130703133943.GA5667@awork2.anarazel.de> (raw)
In-Reply-To: <51D3DE55.6030901@lab.ntt.co.jp>
References: <51B5AFB1.5030404@lab.ntt.co.jp>
	<51BDCB6C.1090507@vmware.com>
	<51BEB6F5.7070907@lab.ntt.co.jp>
	<51C40EF4.1080201@lab.ntt.co.jp>
	<51C9D03B.10107@vmware.com>
	<CA+TgmoZ+ofyg4e+hRBTnnfrC7M2ATX-Pg0k4AtyHx60A+_DFhQ@mail.gmail.com>
	<51C9FD5C.5050706@vmware.com>
	<CA+TgmoZj-0CFLbjceMtgi1t_=hpfe9z8uSa+D0g77sNYcFy04w@mail.gmail.com>
	<51CD873A.5070705@lab.ntt.co.jp>
	<51D3DE55.6030901@lab.ntt.co.jp>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

On 2013-07-03 17:18:29 +0900, KONDO Mitsumasa wrote:
> Hi,
> 
> I tested and changed segsize=0.25GB which is max partitioned table file size and
> default setting is 1GB in configure option (./configure --with-segsize=0.25).
> Because I thought that small segsize is good for fsync phase and background disk
> write in OS in checkpoint. I got significant improvements in DBT-2 result!
> 
> * Performance result in DBT-2 (WH340)
>                               | NOTPM    90%tile    Average  Maximum
>  -----------------------------+---------------------------------------
>  original_0.7 (baseline)      | 3474.62  18.348328  5.739    36.977713
>  fsync + write                | 3586.85  14.459486  4.960    27.266958
>  fsync + write + segsize=0.25 | 3661.17  8.28816    4.117    17.23191
> 
> Changing segsize with my checkpoint patches improved original over 50% at 90%tile
> and maximum response time.

Hm. I wonder how much of this could be gained by doing a
sync_file_range(SYNC_FILE_RANGE_WRITE) (or similar) either while doing
the original checkpoint-pass through the buffers or when fsyncing the
files. Presumably the smaller segsize is better because we don't
completely stall the system by submitting up to 1GB of io at once. So,
if we were to do it in 32MB chunks and then do a final fsync()
afterwards we might get most of the benefits.

Greetings,

Andres Freund

-- 
 Andres Freund	                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (63+ messages)  latest in thread

Message-ID: <20130703133943.GA5667@awork2.anarazel.de>
Permalink:  ../20130703133943.GA5667@awork2.anarazel.de/
Also on:    postgresql.org/message-id/20130703133943.GA5667@awork2.anarazel.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: andres@2ndquadrant.com, kondo.mitsumasa@lab.ntt.co.jp, robertmhaas@gmail.com, hlinnakangas@vmware.com
  Subject: Re: Improvement of checkpoint IO scheduler for stable transaction responses
  In-Reply-To: <20130703133943.GA5667@awork2.anarazel.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox