From: Doug Herr <gmane@wombatz.com>
To: linux-raid@vger.kernel.org
Subject: Re: Replacing a RAID1 drive that has not failed.
Date: Wed, 28 Oct 2015 15:54:00 +0000 (UTC) [thread overview]
Message-ID: <n0qr2n$9t7$1@ger.gmane.org> (raw)
In-Reply-To: 20151028102817.4ec30b5c@natsu
On Wed, 28 Oct 2015 10:28:17 +0500, Roman Mamedov wrote:
> On Tue, 27 Oct 2015 21:31:01 +0000
> Wols Lists <antlists@youngman.org.uk> wrote:
>
>> On 27/10/15 16:45, Doug Herr wrote:
>> > 1. Partition new drive (plugged in via external SATA dock)
>> > #fdisk /dev/sdc
>> > (make it an exact match of sda/sdb unless it turns out to be smaller,
>> > in which case I can shrink /boot to make room.)
>>
>> man gdisk.
>>
>> Look at the "u" option in the "expert" menu - it'll probably save you
>> some work :-)
>
> Unfamiliar with 'gdisk', but when I need the exact same set of
partitions on
> another drive, I use sfdisk:
>
> # sfdisk -d /dev/sda > sda.sf
> # sfdisk /dev/sdb < sda.sf
>
> You could even do it in one step:
>
> # sfdisk -d /dev/sda | sfdisk /dev/sdb
Thanks much to all who have replied and all who post here.
Yup, the sfdisk copy is one that I am ready to use if needed but your
replies have triggered better googling and I am now planning to use fdisk
(I am in Fedora 22) to manually partition the new disk. I don't think I
have any need for GPT yet but what I realized is that my current set of
disks was created when fdisk was still starting at sector 63 where now it
uses 2048. I don't think it matters much for my current set of Hitachi
HDT721010SLA360 drives. It might not even matter for the slightly newer
"E7K1000" that is on the way to me, but I do want to stick with the
current standards as best I can. I have room to tweak it since I have a
non-RAID /boot partition that is easily large enough to lend space as
needed.
I do plan to play with GPT to learn about it and to be more ready for the
next computer if it is the default at that point.
Oh, I also added a step in my plan. Adding my new partitions as spares
first will alert me of size errors (if smaller) *before* any of the
replacement jobs kick off:
For each:
# mdadm /dev/md4 --add-spare /dev/sdc2
If the above does not complain then move forward for each:
# mdadm /dev/md3 --replace /dev/sda2 --with /dev/sdc2
And fear not, I will be updating my backups before moving forward with
this.
--
Doug Herr
prev parent reply other threads:[~2015-10-28 15:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-26 23:00 Replacing a RAID1 drive that has not failed Doug Herr
[not found] ` <CACsGCyTM_J2+_oJm0rUsZvuF0AXXu6xX572F4HP+OGsjP_AvfQ@mail.gmail.com>
2015-10-27 0:41 ` Fwd: " Edward Kuns
2015-10-27 16:45 ` Doug Herr
2015-10-27 21:31 ` Wols Lists
2015-10-28 5:28 ` Roman Mamedov
2015-10-28 15:54 ` Doug Herr [this message]
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='n0qr2n$9t7$1@ger.gmane.org' \
--to=gmane@wombatz.com \
--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 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.