From: Steven Whitehouse <swhiteho@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [GFS2 PATCH] GFS2: Allow caching of rindex glock
Date: Tue, 10 Apr 2012 14:15:29 +0100 [thread overview]
Message-ID: <1334063729.2701.20.camel@menhir> (raw)
In-Reply-To: <df658f49-6285-47c1-a932-884033d5f07f@zmail12.collab.prod.int.phx2.redhat.com>
Hi,
Now in both the -fixes and -nmw git trees. Thanks,
Steve.
On Tue, 2012-04-10 at 08:56 -0400, Bob Peterson wrote:
> Hi,
>
> This patch allows caching of the rindex glock. We were previously
> setting the GL_NOCACHE bit when the glock was released. That forced
> the rindex inode to be invalidated, which caused us to re-read
> rindex at the next access. However, it caused the glock to be
> unnecessarily bounced around the cluster. This patch allows
> the glock to remain cached, but it still causes the rindex to be
> re-read once it has been written to by gfs2_grow.
>
> Ben and I have tested single-node gfs2_grow cases and I've tested
> clustered gfs2_grow cases on my four-node cluster.
>
> Regards,
>
> Bob Peterson
> Red Hat File Systems
>
> Signed-off-by: Bob Peterson <rpeterso@redhat.com>
> ---
> Author: Bob Peterson <rpeterso@redhat.com>
> Date: Thu Apr 5 13:59:00 2012 -0500
>
> GFS2: Allow caching of rindex glock
>
> This patch allows the caching of the rindex file. This keeps the
> lock from being bounced around.
>
> diff --git a/fs/gfs2/aops.c b/fs/gfs2/aops.c
> index 38b7a74..9b2ff0e 100644
> --- a/fs/gfs2/aops.c
> +++ b/fs/gfs2/aops.c
> @@ -807,7 +807,7 @@ static int gfs2_stuffed_write_end(struct inode *inode, struct buffer_head *dibh,
>
> if (inode == sdp->sd_rindex) {
> adjust_fs_space(inode);
> - ip->i_gh.gh_flags |= GL_NOCACHE;
> + sdp->sd_rindex_uptodate = 0;
> }
>
> brelse(dibh);
> @@ -873,7 +873,7 @@ static int gfs2_write_end(struct file *file, struct address_space *mapping,
>
> if (inode == sdp->sd_rindex) {
> adjust_fs_space(inode);
> - ip->i_gh.gh_flags |= GL_NOCACHE;
> + sdp->sd_rindex_uptodate = 0;
> }
>
> brelse(dibh);
>
prev parent reply other threads:[~2012-04-10 13:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <077f07f5-9942-47dd-9709-6d4457b601e4@zmail12.collab.prod.int.phx2.redhat.com>
2012-04-10 12:56 ` [Cluster-devel] [GFS2 PATCH] GFS2: Allow caching of rindex glock Bob Peterson
2012-04-10 13:15 ` Steven Whitehouse [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=1334063729.2701.20.camel@menhir \
--to=swhiteho@redhat.com \
/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).