From: Jan Kara <jack@suse.cz>
To: Bert De Jonghe <Bert.DeJonghe@amplidata.com>
Cc: linux-ext4@vger.kernel.org, Bastiaan Stougie <bstougie@amplidata.com>
Subject: Re: delayed allocation blocks not flushed?
Date: Mon, 27 May 2013 22:35:01 +0200 [thread overview]
Message-ID: <20130527203501.GA21682@quack.suse.cz> (raw)
In-Reply-To: <51A31125.1070100@amplidata.com>
Hello,
On Mon 27-05-13 09:54:13, Bert De Jonghe wrote:
> On an otherwise idle system, create an ext4 filesystem on /dev/sdi,
> mount it and wait more than dirty_writeback_centisecs.
What kernel version are you using?
> Then create a small file (echo something > file); wait
> (dirty_expire_centisecs x 2), expect delayed_allocation_blocks to
> fall to zero but it remains at 2 over here.
>
> Create another small file (echo something_else > file2); again wait
> (dirty_expire_centisecs x 2); check delayed_allocation_blocks which
> is now at 4.
>
> Wait a weekend more:
>
> # date; cat /sys/fs/ext4/sdi/delayed_allocation_blocks
> Fri May 24 15:33:21 UTC 2013
> 4
>
> # date; cat /sys/fs/ext4/sdi/delayed_allocation_blocks
> Mon May 27 07:14:30 UTC 2013
> 4
>
> Doing a manual sync flushes out all blocks, also adding a sync after
> mounting solves the not flushing behaviour (possible patch
> attached).
>
> Has anyone noticed this before and is this expected behaviour? It
> looks like these blocks are not flushed out to disk thus remain in
> memory and will be lost upon power failure?
This would be a bug. I have tried to recreate this with my 3.7.10 kernel
but I failed. File gets flushed to disk after 30s or so. What kernel
version are you using?
Also I don't see why syncing after mount would help to resolve the problem
that files are not flushed to disk in a timely manner...
Honza
--
Jan Kara <jack@suse.cz>
SUSE Labs, CR
prev parent reply other threads:[~2013-05-27 20:35 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <51A31052.4030507@amplidata.com>
2013-05-27 7:54 ` delayed allocation blocks not flushed? Bert De Jonghe
2013-05-27 20:35 ` Jan Kara [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130527203501.GA21682@quack.suse.cz \
--to=jack@suse.cz \
--cc=Bert.DeJonghe@amplidata.com \
--cc=bstougie@amplidata.com \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).