linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <shane-kernel@csy.ca>
To: <linux-btrfs@vger.kernel.org>
Subject: RAID1 failure and recovery
Date: Fri, 12 Sep 2014 01:57:37 -0700	[thread overview]
Message-ID: <000f01cfce67$9e9015f0$dbb041d0$@csy.ca> (raw)

Hi,

I am testing BTRFS in a simple RAID1 environment. Default mount options and data and metadata are mirrored between sda2 and sdb2. I have a few questions and a potential bug report. I don't normally have console access to the server so when the server boots with 1 of 2 disks, the mount will fail without -o degraded. Can I use -o degraded by default to force mounting with any number of disks? This is the default behaviour for linux-raid so I was rather surprised when the server didn't boot after a simulated disk failure.

So I pulled sdb to simulate a disk failure. The kernel oops'd but did continue running. I then rebooted encountering the above mount problem. I re-inserted the disk and rebooted again and BTRFS mounted successfully. However, I am now getting warnings like:
BTRFS: read error corrected: ino 1615 off 86016 (dev /dev/sda2 sector 4580382824)
I take it there were writes to SDA and sdb is out of sync. Btrfs is correcting sdb as it goes but I won't have redundancy until sdb resyncs completely. Is there a way to tell btrfs that I just re-added a failed disk and to go through and resync the array as mdraid would do? I know I can do a btrfs fi resync manually but can that be automated if the array goes out of sync for whatever reason (power failure)...

Finally for those using this sort of setup in production, is running btrfs on top of mdraid the way to go at this point?

Cheers,
Shane



             reply	other threads:[~2014-09-12  9:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-12  8:57 shane-kernel [this message]
2014-09-12 10:47 ` RAID1 failure and recovery Hugo Mills
2014-09-14  3:15   ` Piotr Pawłow
2014-09-14  4:44     ` Hugo Mills
2014-09-14 14:53       ` Piotr Pawłow
2014-09-12 11:11 ` Duncan

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='000f01cfce67$9e9015f0$dbb041d0$@csy.ca' \
    --to=shane-kernel@csy.ca \
    --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).