[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20101008135704.GB25439@localhost>
Date: Fri, 8 Oct 2010 21:57:04 +0800
From: Wu Fengguang <fengguang.wu@...el.com>
To: Yong Wang <yong.y.wang@...ux.intel.com>
Cc: Artem Bityutskiy <Artem.Bityutskiy@...ia.com>,
"Wu, Xia" <xia.wu@...el.com>, Christoph Hellwig <hch@....de>,
Jens Axboe <jaxboe@...ionio.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-mm@...ck.org" <linux-mm@...ck.org>
Subject: Re: [PATCH] bdi: use deferable timer for sync_supers task
On Fri, Oct 08, 2010 at 06:27:09PM +0800, Yong Wang wrote:
> On Fri, Oct 08, 2010 at 01:28:07PM +0300, Artem Bityutskiy wrote:
> > On Fri, 2010-10-08 at 18:27 +0800, Wu, Xia wrote:
> > > > However, when the next wake-up interrupt happens is not defined. It can
> > > > happen 1ms after, or 1 minute after, or 1 hour after. What Christoph
> > > > says is that there should be some guarantee that sb writeout starts,
> > > > say, within 5 to 10 seconds interval. Deferrable timers do not guarantee
> > > > this. But take a look at the range hrtimers - they do exactly this.
> > >
> > > If the system is in sleep state, is there any data which should be written?
> >
> > May be yes, may be no.
> >
>
> Thanks for the quick response, Artem. May I know what might need to be
> written out when system is really idle?
system idle != no dirty inodes
Imagine an application dirties 100MB data and quits. The system then
goes quiet for very long time. In this case we still want the flusher
thread to wake up within 30 seconds to flush the 100MB dirty data.
It's a contract that dirty data will be synced to disk after 30s
(which is the default value of /proc/sys/vm/dirty_expire_centisecs).
Note that 30s is not an exact value. A dirty page may be synced to
disk when it's been dirtied for 35s. The 5s error comes from the
flusher wakeup interval (/proc/sys/vm/dirty_writeback_centisecs).
Thanks,
Fengguang
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists