[hackers-jp: 43] Re: [HACKERS] Background writer process

TANIDA Yutaka tanida @ sra.co.jp
2003年 11月 17日 (月) 13:47:42 JST


谷田です。

7.4リリース直前になって次から次へと出てきている細かい性能改善案ですが、
今度はdirtyなバッファを別プロセスに書き込ませる、というものです。

これも紹介だけで解説する暇がないので誰か・・・

On Thu, 13 Nov 2003 16:35:31 -0500
Jan Wieck <JanWieck @ Yahoo.com> wrote:

> The attached diff is another attempt for distributing the write IO.
> 
> It is a separate background process much like the checkpointer. It's 
> purpose is to keep the number of dirty blocks in the buffer cache at a 
> reasonable level and try that the buffers returned by the strategy for 
> replacement are allways clean. This current shot does it this way:
> 
>      - get a list of all dirty blocks in strategy replacement order
>      - flush n percent of that list or a maximum of m buffers
>        (whatever is smaller)
>      - issue a sync()
>      - sleep for x milliseconds
> 
> If there is nothing to do, it will sleep for 10 seconds before checking 
> again at all. It acquires a checkpoint lock during the flush, so it will 
> yield for a real checkpoint.
> 
> For sure the sync() needs to be replaced by the discussed fsync() of 
> recently written files. And I think the algorithm how much and how often 
> to flush can be significantly improved. But after all, this does not 
> change the real checkpointing at all, and the general framework having a 
> separate process is what we probably want.
> 
> 
> Jan
> 
> -- 
> #======================================================================#
> # It's easier to get forgiveness for being wrong than for being right. #
> # Let's break this rule - forgive me.                                  #
> #================================================== JanWieck @ Yahoo.com #

-- 
TANIDA Yutaka <tanida @ sra.co.jp>




hackers-jp メーリングリストの案内