All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Siddall <news@siddall.name>
To: linux-btrfs@vger.kernel.org
Subject: Converting RAID1 to single fails if RAID1 is missing device
Date: Sun, 2 Feb 2025 17:43:56 -0500	[thread overview]
Message-ID: <2cb1d81e-12a8-4fb1-b3fc-e7e83d31e059@siddall.name> (raw)

After a device failed on RAID1 filesystem, an attempt to convert the 
online filesystem from RAID1 to single failed.  This isn't an uncommon 
use case if the failed device isn't readily replaceable.

The command ran was:

btrfs balance start -f -sconvert=single -mconvert=single 
-dconvert=single /mountpoint

and the kernel logs were:

kernel: BTRFS info (device nvme0n1p3): balance: start -dconvert=single 
-mconvert=dup -sconvert=dup
kernel: BTRFS info (device nvme0n1p3): relocating block group 
1222049267712 flags data|raid1
kernel: BTRFS warning (device nvme0n1p3): chunk 1223123009536 missing 1 
devices, max tolerance is 0 for writable mount
kernel: BTRFS: error (device nvme0n1p3) in write_all_supers:4370: 
errno=-5 IO failure (errors while submitting device barriers.)
kernel: BTRFS info (device nvme0n1p3: state E): forced readonly
kernel: BTRFS warning (device nvme0n1p3: state E): Skipping commit of 
aborted transaction.
kernel: BTRFS: error (device nvme0n1p3: state EA) in 
cleanup_transaction:1992: errno=-5 IO failure
kernel: BTRFS info (device nvme0n1p3: state EA): balance: ended with 
status: -5

Either it should be made possible to convert a RAID1 device with a 
missing device to a single device filesystem without errors, or the 
command should return a message stating that it is not supported to 
convert RAID1 array with missing devices to a single.  Having the 
process fail and then going forced readonly is a significant failure on 
an otherwise working system.



             reply	other threads:[~2025-02-02 22:43 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-02 22:43 Jeff Siddall [this message]
2025-02-03  0:44 ` Converting RAID1 to single fails if RAID1 is missing device Qu Wenruo
2025-02-03  1:11   ` Jeff Siddall
2025-02-03  2:19   ` Jussi Kansanen
2025-02-03  2:32     ` Qu Wenruo
2025-02-03  5:22       ` Colin S
2025-02-03  6:13         ` Qu Wenruo
2025-02-04  7:04           ` Colin S

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=2cb1d81e-12a8-4fb1-b3fc-e7e83d31e059@siddall.name \
    --to=news@siddall.name \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.