From: Bob Peterson <rpeterso@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [PATCH 12/19] gfs2: If the journal isn't live ignore log flushes
Date: Wed, 27 Mar 2019 06:35:25 -0600 [thread overview]
Message-ID: <20190327123532.27131-13-rpeterso@redhat.com> (raw)
In-Reply-To: <20190327123532.27131-1-rpeterso@redhat.com>
This patch adds a check to function gfs2_log_flush: if the journal
is no longer live, the flush is ignored.
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
---
fs/gfs2/log.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/gfs2/log.c b/fs/gfs2/log.c
index 896165811063..cd2f54db7f8a 100644
--- a/fs/gfs2/log.c
+++ b/fs/gfs2/log.c
@@ -782,6 +782,9 @@ void gfs2_log_flush(struct gfs2_sbd *sdp, struct gfs2_glock *gl, u32 flags)
struct gfs2_trans *tr;
enum gfs2_freeze_state state = atomic_read(&sdp->sd_freeze_state);
+ if (!test_bit(SDF_JOURNAL_LIVE, &sdp->sd_flags))
+ return;
+
down_write(&sdp->sd_log_flush_lock);
/* Log might have been flushed while we waited for the flush lock */
--
2.20.1
next prev parent reply other threads:[~2019-03-27 12:35 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-27 12:35 [Cluster-devel] [PATCH 00/19] gfs2: misc recovery patch collection Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 01/19] gfs2: log error reform Bob Peterson
2019-04-09 13:46 ` Andreas Gruenbacher
2019-03-27 12:35 ` [Cluster-devel] [PATCH 02/19] gfs2: Introduce concept of a pending withdraw Bob Peterson
2019-04-09 14:00 ` Andreas Gruenbacher
2019-03-27 12:35 ` [Cluster-devel] [PATCH 03/19] gfs2: Ignore recovery attempts if gfs2 has io error or is withdrawn Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 04/19] gfs2: move check_journal_clean to util.c for future use Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 05/19] gfs2: Allow some glocks to be used during withdraw Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 06/19] gfs2: Make secondary withdrawers wait for first withdrawer Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 07/19] gfs2: Don't write log headers after file system withdraw Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 08/19] gfs2: Force withdraw to replay journals and wait for it to finish Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 09/19] gfs2: Add verbose option to check_journal_clean Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 10/19] gfs2: Check for log write errors before telling dlm to unlock Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 11/19] gfs2: Do log_flush in gfs2_ail_empty_gl even if ail list is empty Bob Peterson
2019-03-27 12:35 ` Bob Peterson [this message]
2019-03-27 12:35 ` [Cluster-devel] [PATCH 13/19] gfs2: Issue revokes more intelligently Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 14/19] gfs2: Warn when a journal replay overwrites a rgrp with buffers Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 15/19] gfs2: log which portion of the journal is replayed Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 16/19] gfs2: Only remove revokes that we've submitted Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 17/19] gfs2: eliminate tr_num_revoke_rm Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 18/19] gfs2: don't call go_unlock unless demote is close at hand Bob Peterson
2019-03-27 12:35 ` [Cluster-devel] [PATCH 19/19] gfs2: clean_journal was setting sd_log_flush_head replaying other journals Bob Peterson
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=20190327123532.27131-13-rpeterso@redhat.com \
--to=rpeterso@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).