Skip to contentSkip to conversation

Creating failed-mode RAID1 with mdadm

DISCUSSION Ross Vandegrift 3 participants 4 messages Apr 30, 2002 – May 3, 2002 MD RAID

lore
Share & tools
lore
#0 lore raw

Hey everyone,

Creating a new array today, I decided I should probably start
using mdadm instead of the old tools. I've been using it a bit at home to do minor things, and it seemed nice.
I've got a box with two 20G ide drives installed. One is
currently the root drive at /dev/hda1 and the other is one of the disks for the mirrored pair at /dev/hde1. I'm trying to create the array with /dev/hdg1 as a failed disk, and then move /dev/hda to /dev/hde after I start booting the machine off of /dev/md0.
When I do:

# mdadm --create /dev/md0 --level 1 --raid-disks=2 /dev/hde1 /dev/hdg1

I get:

mdadm: Cannot open /dev/hdg1: No such device or address
mdadm: create aborted

This makes sense, as /dev/hdg doesn't really exist yet. I've tried doing:

# mdadm --set-faulty /dev/md0 /dev/hdg1

but it doesn't seem to help. How can I build an array like this via mdadm?

Ross Vandegrift
[email protected]

#1 lore raw
Quoted 6 lines
# mdadm --create /dev/md0 --level 1 --raid-disks=2 /dev/hde1 /dev/hdg1

I get:

mdadm: Cannot open /dev/hdg1: No such device or address
mdadm: create aborted

Hmmm, funny - as it turns out, mdadm actually created the array and started it with /dev/hdg1 failed. It just said it didn't.

Ross Vandegrift
[email protected]

#2 lore raw
Quoted 9 lines · On Tuesday April 30, [email protected] wrote:
Quoted 6 lines
# mdadm --create /dev/md0 --level 1 --raid-disks=2 /dev/hde1 /dev/hdg1

I get:

mdadm: Cannot open /dev/hdg1: No such device or address
mdadm: create aborted

Hmmm, funny - as it turns out, mdadm actually created the array and started it with /dev/hdg1 failed. It just said it didn't.

That surprises me? Are you in a position to try it again and see?
If so, what version of mdadm?

NeilBrown

#3 lore raw
In reply to Ross Vandegrift

Try with

# mdadm --create /dev/md0 --level 1 --raid-disks=2 /dev/hde1 missing

It will work.

----- Original Message -----
From: "Ross Vandegrift" <[email protected]>
To: <[email protected]>
Sent: Tuesday, April 30, 2002 11:48 AM
Subject: Creating failed-mode RAID1 with mdadm

Quoted 35 lines

Hey everyone,

Creating a new array today, I decided I should probably start using mdadm instead of the old tools. I've been using it a bit at home to do minor things, and it seemed nice.
I've got a box with two 20G ide drives installed. One is currently the root drive at /dev/hda1 and the other is one of the disks for the mirrored pair at /dev/hde1. I'm trying to create the array with /dev/hdg1 as a failed disk, and then move /dev/hda to /dev/hde after I start booting the machine off of /dev/md0.
When I do:

# mdadm --create /dev/md0 --level 1 --raid-disks=2 /dev/hde1 /dev/hdg1

I get:

mdadm: Cannot open /dev/hdg1: No such device or address
mdadm: create aborted

This makes sense, as /dev/hdg doesn't really exist yet. I've tried doing:

# mdadm --set-faulty /dev/md0 /dev/hdg1

but it doesn't seem to help. How can I build an array like this via mdadm?

Ross Vandegrift
[email protected]

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html