From: Andreas Dilger <adilger@clusterfs.com>
To: Takashi Sato <sho@bsd.tnes.nec.co.jp>
Cc: ext2-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org
Subject: Re: [Ext2-devel] OOM problems still left in 2.6.13-rc3
Date: Fri, 29 Jul 2005 11:06:41 -0600 [thread overview]
Message-ID: <20050729170641.GH6126@schatzie.adilger.int> (raw)
In-Reply-To: <018101c5943a$1a07a5d0$4168010a@bsd.tnes.nec.co.jp>
On Jul 29, 2005 21:36 +0900, Takashi Sato wrote:
> The buffers connected to t_sync_datalist can't simply be removed like
> the buffers connected to t_locked_list, since we don't know if the
> I/O against the buffers are complete.
>
> So we should wait until the committing transaction becomes complete
> if there are any buffers connected to the transaction's
> t_sync_datalist.
>
> b) If journal_unmap_buffer() returns -1 on journal_invalidatepages(),
> call log_wait_commit() to wait for the completion of the
> transaction, and retry to call journal_unmap_buffer() again.
>
> @@ -1899,8 +1896,19 @@ int journal_invalidatepage(journal_t *jo
>
> if (offset <= curr_off) {
> /* This block is wholly outside the truncation point */
> +retry:
> lock_buffer(bh);
> - may_free &= journal_unmap_buffer(journal, bh);
> + ret = journal_unmap_buffer(journal, bh, &wait_tid);
> + /* When this buffer is in transaction of
> + * t_sync_datalist, truncate must wait for
> + * that transaction.
> + */
> + if (ret < 0) {
> + unlock_buffer(bh);
> + log_wait_commit(journal, wait_tid);
> + goto retry;
> + }
> + may_free &= ret;
What kind of effect does this have on filesystem performance?
This would apparently make truncate be synchronous with journal commit due to
truncate_{partial,complete}_page->do_invalidatepage->journal_invalidatepage().
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
next prev parent reply other threads:[~2005-07-29 17:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-29 12:36 Takashi Sato
2005-07-29 17:06 ` Andreas Dilger [this message]
2005-07-29 23:48 ` Andrew Morton
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=20050729170641.GH6126@schatzie.adilger.int \
--to=adilger@clusterfs.com \
--cc=ext2-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=sho@bsd.tnes.nec.co.jp \
/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
all inboxes | Powered by JetHome®