linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Wols Lists <antlists@youngman.org.uk>
To: Chris Dunlop <chris@onthe.net.au>, linux-raid@vger.kernel.org
Subject: Re: Is it possible to restart --add?
Date: Sun, 11 Dec 2022 13:55:54 +0000	[thread overview]
Message-ID: <d4e4611f-4764-c66a-0bc9-b8dbcbfae39e@youngman.org.uk> (raw)
In-Reply-To: <20221210195945.GA34756@onthe.net.au>

On 10/12/2022 19:59, Chris Dunlop wrote:
> Hi,
> 
> When replacing a failed disk with a new one using --add, is it possible 
> to restart a partially-complete --add, e.g. after a reboot?
> 
> I have a raid-6 with a failed disk, and used --add to add a new disk as 
> a replacement. From /proc/mdstat, "finish" told me it would take around 
> 24 hours to complete the add.
> 
> The machine was rebooted some hours into the add, and on restart the md 
> was missing the new disk (and the failed disk). I tried to --re-add the 
> new disk again, but mdadm told me it's "not possible":
> 
> mdadm: --re-add for /dev/sdh1 to /dev/md0 is not possible
> 
> I ended up --add'ing the disk again, so the 24 hours to complete started 
> again.
> 
> Is this expected, and/or is there a way to restart the --add rather than 
> starting from the beginning again?
> 
Raid is supposed to be robust, so this surprises me. When it rebooted it 
should have known it was part-way through a rebuild. Was it a controlled 
reboot, or a crash and restart?

What I would expect is that the array would be rebuilt including sdh1, 
and the rebuild would just carry on. So I suspect that whatever went 
wrong, it was a bit further back than that - somehow md forgot that sdh1 
was now part of the array.

Weird.

Cheers,
Wol

  reply	other threads:[~2022-12-11 13:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-10 19:59 Is it possible to restart --add? Chris Dunlop
2022-12-11 13:55 ` Wols Lists [this message]
2022-12-12  7:05   ` Chris Dunlop

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=d4e4611f-4764-c66a-0bc9-b8dbcbfae39e@youngman.org.uk \
    --to=antlists@youngman.org.uk \
    --cc=chris@onthe.net.au \
    --cc=linux-raid@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).