From: Anand Jain <anand.jain@oracle.com>
To: linux-btrfs@vger.kernel.org
Cc: bo.li.liu@oracle.com
Subject: [PATCH v8 0/2] [RFC] Introduce device state 'failed'
Date: Tue, 3 Oct 2017 23:59:18 +0800 [thread overview]
Message-ID: <20171003155920.24925-1-anand.jain@oracle.com> (raw)
When one device fails it has to be closed and marked as failed.
Further it needs sysfs (or some) interface to provide complete
information about the device and the volume status to the user
land from the kernel. Next when the disappeared device reappears
we need to resilver/insync depending on the RAID profile which
should be handled per RAID profile specific.
The efforts here are to fix above three missing items.
To begin with this patch brings a Write/Flush failed device to
a failed state.
Next about bringing the device back to the alloc list and verifying
its consistency and kicking off the re-silvering part that still WIP,
& feedback helps. For RAID1 a convert of single raid profile back to
all raid1 will help. For RAID56 I am backing on Luibo's recent RAID56
write hole work I am yet to look deeper on that. Next for RAID1 there
can be split brain scenario where each of the devices were mounted
independently, so to fix this I planning to set an (new) incompatible
flag if any of the device is written without the other. Now when they
are brought together then incompatible flag should be their on only
one of the device, however if incompatible flag is on both the devices
then its a split brain scenario where user intervention will be required.
On the sysfs part there are patches in the ML which was sent before,
I shall be reviving them as well.
Thanks, Anand
Anand Jain (2):
btrfs: introduce device dynamic state transition to failed
btrfs: check device for critical errors and mark failed
fs/btrfs/ctree.h | 2 +
fs/btrfs/disk-io.c | 78 ++++++++++++++++++++++++++++++++++++++-
fs/btrfs/volumes.c | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++
fs/btrfs/volumes.h | 19 +++++++++-
4 files changed, 202 insertions(+), 2 deletions(-)
--
2.7.0
next reply other threads:[~2017-10-03 15:59 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-03 15:59 Anand Jain [this message]
2017-10-03 15:59 ` [PATCH v8 1/2] btrfs: introduce device dynamic state transition to failed Anand Jain
2017-10-13 18:47 ` Liu Bo
2017-10-16 6:09 ` Anand Jain
2017-10-03 15:59 ` [PATCH v8 2/2] btrfs: check device for critical errors and mark failed Anand Jain
2017-10-04 20:11 ` Liu Bo
2017-10-05 11:07 ` Austin S. Hemmelgarn
2017-10-06 23:33 ` Liu Bo
2017-10-09 11:58 ` Austin S. Hemmelgarn
2017-10-05 13:56 ` Anand Jain
2017-10-06 23:56 ` Liu Bo
2017-10-08 14:23 ` Anand Jain
2017-10-13 18:46 ` Liu Bo
2017-10-16 6:09 ` Anand Jain
2017-10-05 13:54 ` [PATCH v8.1 2/2] btrfs: mark device failed for write and flush errors Anand Jain
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=20171003155920.24925-1-anand.jain@oracle.com \
--to=anand.jain@oracle.com \
--cc=bo.li.liu@oracle.com \
--cc=linux-btrfs@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).