ocfs2-devel.oss.oracle.com archive mirror
 help / color / mirror / Atom feed
* [Ocfs2-devel] ocfs2: o2hb: not fence self if storage down
@ 2016-01-20  3:13 Junxiao Bi
  2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 1/6] ocfs2: o2hb: add negotiate timer Junxiao Bi
                   ` (8 more replies)
  0 siblings, 9 replies; 32+ messages in thread
From: Junxiao Bi @ 2016-01-20  3:13 UTC (permalink / raw)
  To: ocfs2-devel

Hi,

This serial of patches is to fix the issue that when storage down,
all nodes will fence self due to write timeout.
With this patch set, all nodes will keep going until storage back
online, except if the following issue happens, then all nodes will
do as before to fence self.
1. io error got
2. network between nodes down
3. nodes panic

Junxiao Bi (6):
      ocfs2: o2hb: add negotiate timer
      ocfs2: o2hb: add NEGO_TIMEOUT message
      ocfs2: o2hb: add NEGOTIATE_APPROVE message
      ocfs2: o2hb: add some user/debug log
      ocfs2: o2hb: don't negotiate if last hb fail
      ocfs2: o2hb: fix hb hung time

 fs/ocfs2/cluster/heartbeat.c |  181 ++++++++++++++++++++++++++++++++++++++++--
 1 file changed, 175 insertions(+), 6 deletions(-)

 Thanks,
 Junxiao.

^ permalink raw reply	[flat|nested] 32+ messages in thread
* [Ocfs2-devel] [patch 6/6] ocfs2: o2hb: fix hb hung time
@ 2016-05-23 21:50 akpm at linux-foundation.org
  0 siblings, 0 replies; 32+ messages in thread
From: akpm at linux-foundation.org @ 2016-05-23 21:50 UTC (permalink / raw)
  To: ocfs2-devel

From: Junxiao Bi <junxiao.bi@oracle.com>
Subject: ocfs2: o2hb: fix hb hung time

hr_last_timeout_start should be set as the last time where hb is still OK.
When hb write timeout, hung time will be (jiffies -
hr_last_timeout_start).

Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com>
Reviewed-by: Ryan Ding <ryan.ding@oracle.com>
Cc: Gang He <ghe@suse.com>
Cc: rwxybh <rwxybh@126.com>
Cc: Mark Fasheh <mfasheh@suse.de>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Joseph Qi <joseph.qi@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 fs/ocfs2/cluster/heartbeat.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN fs/ocfs2/cluster/heartbeat.c~ocfs2-o2hb-fix-hb-hung-time fs/ocfs2/cluster/heartbeat.c
--- a/fs/ocfs2/cluster/heartbeat.c~ocfs2-o2hb-fix-hb-hung-time
+++ a/fs/ocfs2/cluster/heartbeat.c
@@ -356,7 +356,6 @@ static void o2hb_arm_timeout(struct o2hb
 		spin_unlock(&o2hb_live_lock);
 	}
 	cancel_delayed_work(&reg->hr_write_timeout_work);
-	reg->hr_last_timeout_start = jiffies;
 	schedule_delayed_work(&reg->hr_write_timeout_work,
 			      msecs_to_jiffies(O2HB_MAX_WRITE_TIMEOUT_MS));
 
@@ -1174,6 +1173,7 @@ static int o2hb_do_disk_heartbeat(struct
 	if (own_slot_ok) {
 		o2hb_set_quorum_device(reg);
 		o2hb_arm_timeout(reg);
+		reg->hr_last_timeout_start = jiffies;
 	}
 
 bail:
_

^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2016-05-23 21:50 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-20  3:13 [Ocfs2-devel] ocfs2: o2hb: not fence self if storage down Junxiao Bi
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 1/6] ocfs2: o2hb: add negotiate timer Junxiao Bi
2016-01-21 23:42   ` Andrew Morton
2016-01-22  3:23     ` Junxiao Bi
2016-01-22  0:56   ` Joseph Qi
2016-01-22  3:19     ` Junxiao Bi
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 2/6] ocfs2: o2hb: add NEGO_TIMEOUT message Junxiao Bi
2016-01-21 23:47   ` Andrew Morton
2016-01-22  5:12     ` Junxiao Bi
2016-01-22  5:45       ` Andrew Morton
2016-01-22  5:46         ` Junxiao Bi
2016-01-25  3:18   ` Eric Ren
2016-01-25  4:28     ` Junxiao Bi
2016-01-25  5:59       ` Eric Ren
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 3/6] ocfs2: o2hb: add NEGOTIATE_APPROVE message Junxiao Bi
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 4/6] ocfs2: o2hb: add some user/debug log Junxiao Bi
2016-01-25  3:28   ` Eric Ren
2016-01-25  4:29     ` Junxiao Bi
2016-01-25  6:00       ` Eric Ren
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 5/6] ocfs2: o2hb: don't negotiate if last hb fail Junxiao Bi
2016-01-20  3:13 ` [Ocfs2-devel] [PATCH 6/6] ocfs2: o2hb: fix hb hung time Junxiao Bi
2016-01-20  6:00 ` [Ocfs2-devel] ocfs2: o2hb: not fence self if storage down Gang He
2016-01-20  8:09   ` Junxiao Bi
2016-01-20  9:18 ` Joseph Qi
2016-01-20 13:27   ` Junxiao Bi
2016-01-21  0:46     ` Joseph Qi
2016-01-21  1:48       ` Junxiao Bi
2016-01-22  4:25         ` Joseph Qi
2016-01-22  5:08           ` Junxiao Bi
2016-01-21  8:34 ` rwxybh
2016-01-21  8:41   ` Junxiao Bi
  -- strict thread matches above, loose matches on Subject: below --
2016-05-23 21:50 [Ocfs2-devel] [patch 6/6] ocfs2: o2hb: fix hb hung time akpm at linux-foundation.org

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).