Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   ArchLinux General Discussion (http://www.linux-archive.org/archlinux-general-discussion/)
-   -   Installing to RAID .. cannot reboot (http://www.linux-archive.org/archlinux-general-discussion/675084-installing-raid-cannot-reboot.html)

"D. R. Evans" 06-20-2012 05:27 PM

Installing to RAID .. cannot reboot
 
I have carefully followed the RAID instructions at:
https://wiki.archlinux.org/index.php/Software_RAID_and_LVM#RAID_installation

I have not used LVM, just RAID. I have double-checked what I actually did, and
believe that I did exactly what the page tells me to do.

I have two identical drives, which I configured as RAID1.

At the conclusion of the installation, the instructions say:

----

Once it is complete you can safely reboot your machine:

# reboot

----

When I try to reboot, I receive the error message:
ERROR: device /dev/md0 not found
ERROR: unable to find root device /dev/md0

What do I have to do to get past this error?

Doc

PS I tried to go back to the very beginning and walk through the instructions
again, but when I do that, when I reach this step:
mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sd[cd]3
I am now informed that /dev/sdc3 is busy or unavailable.

--
Web: http://www.sff.net/people/N7DR

"D. R. Evans" 06-20-2012 10:10 PM

Installing to RAID .. cannot reboot
 
D. R. Evans said the following at 06/20/2012 11:27 AM :
> I have carefully followed the RAID instructions at:
> https://wiki.archlinux.org/index.php/Software_RAID_and_LVM#RAID_installation
>
> I have not used LVM, just RAID. I have double-checked what I actually did, and
> believe that I did exactly what the page tells me to do.
>
> I have two identical drives, which I configured as RAID1.
>
> At the conclusion of the installation, the instructions say:
>
> ----
>
> Once it is complete you can safely reboot your machine:
>
> # reboot
>
> ----
>
> When I try to reboot, I receive the error message:
> ERROR: device /dev/md0 not found
> ERROR: unable to find root device /dev/md0
>
> What do I have to do to get past this error?
>
> Doc
>
> PS I tried to go back to the very beginning and walk through the instructions
> again, but when I do that, when I reach this step:
> mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sd[cd]3
> I am now informed that /dev/sdc3 is busy or unavailable.
>

Having spent a chunk of the day on this:

1. I figured out how to avoid the "busy or unavailable" message: one issues
the "mdadm --stop" command. One can then go back to the beginning and
re-create the RAID array(s).

2. So I meticulously started from scratch and, checking every command
carefully, followed the instructions until I reached the point where they tell
me to reboot.

3. On reboot, I am in exactly the same situation as before: the system can't
boot because it cannot find /dev/md0.

I therefore provisionally conclude that of the two possibilities:
α) I am making a mistake in following the instructions
β) The instructions contain a fatal error
possibility β seems much the more likely. Most likely something is omitted, I
think.

I (obviously) have no way of knowing where the mistake lies, though, so I'm
completely stuck until someone who understand how all this is supposed to work
can look carefully at the instructions and perhaps spot the error.

After some experimentation with Arch on other (non-RAID) computers, I had
settled on Arch for my main desktop. But that's a RAID system and unless I can
get Arch to install correctly I'm going to have go looking for a different
distro -- which I really, really don't want to have to do, because there's a
lot about Arch that I like :-(

Doc

--
Web: http://www.sff.net/people/N7DR

Damjan 06-20-2012 10:21 PM

Installing to RAID .. cannot reboot
 
# reboot

----

When I try to reboot, I receive the error message:
ERROR: device /dev/md0 not found
ERROR: unable to find root device /dev/md0

What do I have to do to get past this error?

Doc

PS I tried to go back to the very beginning and walk through the instructions
again, but when I do that, when I reach this step:
mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sd[cd]3
I am now informed that /dev/sdc3 is busy or unavailable.


why are the sata devices sdc and sdd ?

did you setup the mkinitcpio.conf as it says here:
https://wiki.archlinux.org/index.php/Software_RAID_and_LVM#Configure_system

--
дамјан

Jason Ryan 06-20-2012 10:54 PM

Installing to RAID .. cannot reboot
 
On 20/06/12 at 04:10pm, D. R. Evans wrote:
> D. R. Evans said the following at 06/20/2012 11:27 AM :
> > I have carefully followed the RAID instructions at:
> > https://wiki.archlinux.org/index.php/Software_RAID_and_LVM#RAID_installation
> >
> > I have not used LVM, just RAID. I have double-checked what I actually did, and
> > believe that I did exactly what the page tells me to do.
> >
> > I have two identical drives, which I configured as RAID1.
> >
> > At the conclusion of the installation, the instructions say:
> >
> > ----
> >
> > Once it is complete you can safely reboot your machine:
> >
> > # reboot
> >
> > ----
> >
> > When I try to reboot, I receive the error message:
> > ERROR: device /dev/md0 not found
> > ERROR: unable to find root device /dev/md0
> >
> > What do I have to do to get past this error?
> >
> > Doc
> >
> > PS I tried to go back to the very beginning and walk through the instructions
> > again, but when I do that, when I reach this step:
> > mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sd[cd]3
> > I am now informed that /dev/sdc3 is busy or unavailable.
> >
>
> Having spent a chunk of the day on this:
>
> 1. I figured out how to avoid the "busy or unavailable" message: one issues
> the "mdadm --stop" command. One can then go back to the beginning and
> re-create the RAID array(s).
>
> 2. So I meticulously started from scratch and, checking every command
> carefully, followed the instructions until I reached the point where they tell
> me to reboot.
>
> 3. On reboot, I am in exactly the same situation as before: the system can't
> boot because it cannot find /dev/md0.
>
> I therefore provisionally conclude that of the two possibilities:
> α) I am making a mistake in following the instructions
> β) The instructions contain a fatal error
> possibility β seems much the more likely. Most likely something is omitted, I
> think.
>
I encountered this same issue at the start of the year: it is simply a matter of
completing the installation and chrooting in to install grub to both your
devices: http://jasonwryan.com/blog/2012/02/11/lvm/

I had thought I added a note to the wiki to that effect…

HTH

/J

"D. R. Evans" 06-21-2012 12:06 AM

Installing to RAID .. cannot reboot
 
Damjan said the following at 06/20/2012 04:21 PM :
>> # reboot
>>
>> ----
>>
>> When I try to reboot, I receive the error message:
>> ERROR: device /dev/md0 not found
>> ERROR: unable to find root device /dev/md0
>>
>> What do I have to do to get past this error?
>>
>> Doc
>>
>> PS I tried to go back to the very beginning and walk through the instructions
>> again, but when I do that, when I reach this step:
>> mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sd[cd]3
>> I am now informed that /dev/sdc3 is busy or unavailable.
>
> why are the sata devices sdc and sdd ?
>

I have a different OS on sda and sdb (which are also a RAID1 pair).

> did you setup the mkinitcpio.conf as it says here:
> https://wiki.archlinux.org/index.php/Software_RAID_and_LVM#Configure_system
>

Yes.

Doc

--
Web: http://www.sff.net/people/N7DR

"D. R. Evans" 06-21-2012 12:49 AM

Installing to RAID .. cannot reboot
 
Jason Ryan said the following at 06/20/2012 04:54 PM :

> I encountered this same issue at the start of the year: it is simply a matter of
> completing the installation and chrooting in to install grub to both your
> devices: http://jasonwryan.com/blog/2012/02/11/lvm/
>

The wiki seems strongly to urge one NOT to use grub, and the example given
is for syslinux, so that's what I've been doing. Indeed. it says that the
2011.08.19 Arch Linux installer does not not support GRUB2. (I'm a bit
confused about whether when "grub" is mentioned it means "grub2"; the wiki
could be a lot clearer about that -- to be on the safe side, I avoided grub
entirely and went with syslinux instead). 2011.08.19 is the what one gets if
one downloads the current installer.

According to the wiki, the step of copying the bootloader is supposed to
occur after the reboot, and your page says that that should be possible. I did
not realise it could be done before the reboot (since the wiki doesn't mention
that possibility) so I have not tried that.

I was planning to follow the new instruction placed into the wiki by Paul Dann
and mentioned in his e-mail <2457829.5nCasJRlDv@leto> once I got past the
reboot stage. So perhaps, having now discovered that the bootloader can be
copied before the reboot, what I need to do is to go through the entire
procedure again and this time copy the bootloader with
/usr/sbin/syslinux-install_update -iam
BEFORE the reboot.

Incidentally, I have tried to boot off both the disks in the RAID1 array; they
both fail with the same error (unable to find /dev/md0).

Doc

--
Web: http://www.sff.net/people/N7DR

Paul Gideon Dann 06-21-2012 09:41 AM

Installing to RAID .. cannot reboot
 
On Wednesday 20 Jun 2012 11:27:54 D. R. Evans wrote:
> When I try to reboot, I receive the error message:
> ERROR: device /dev/md0 not found
> ERROR: unable to find root device /dev/md0

To me, this sounds like the RAID array is being given the wrong name, or the
mdadm hook isn't being added to /etc/mkinitcpio.conf.

When you get the above error message, are you dropped to a busybox shell? If
so, can you do:

# ls /dev/md*

...to see if the array is being started at all?

This should be fixable without going through a full install each time. Just
boot the install disk, insert md_mod, and cat /proc/mdstat to see if your RAID
array is working. If it is, you can chroot into it in the normal way and fix
whatever configuration issue this turns out to be.

Paul

"D. R. Evans" 06-21-2012 03:44 PM

Installing to RAID .. cannot reboot
 
Paul Gideon Dann said the following at 06/21/2012 03:41 AM :
> On Wednesday 20 Jun 2012 11:27:54 D. R. Evans wrote:
>> When I try to reboot, I receive the error message:
>> ERROR: device /dev/md0 not found
>> ERROR: unable to find root device /dev/md0
>
> To me, this sounds like the RAID array is being given the wrong name, or the
> mdadm hook isn't being added to /etc/mkinitcpio.conf.
>

Extract from /etc/mkinitcpio.conf (sorry about any possible wrapping issue):

MODULES="dm_mod"
...
HOOKS="base udev mdadm_udev lvm2 autodetect pata scsi sata filesystems
usbinput fsck"

> When you get the above error message, are you dropped to a busybox shell? If
> so, can you do:
>
> # ls /dev/md*
>
> ...to see if the array is being started at all?
>

I am dropped to some sort of primitive shell (the prompt says "rootfs"). As
you suspect,
ls /dev/md*
reports no such file or device.

So I think we have a clue and it looks like you are right that the RAID is not
being started, although I don't know why.

A couple more facts that may provide useful information:

1. I also did an
ls /etc
And I see that there are only three entries: fstab, mtab and udev. I don't
know if that's reasonable. I navely expected to see a populated /etc (since
presumably /etc/mkinicpio.conf has been read at this point), but perhaps that
expectation was incorrect.

2. I checked that the RAID will start correctly if I assemble the array from
within a different OS, and it does so.

Doc

--
Web: http://www.sff.net/people/N7DR

Paul Gideon Dann 06-21-2012 05:13 PM

Installing to RAID .. cannot reboot
 
On Thursday 21 Jun 2012 09:44:03 D. R. Evans wrote:
> Extract from /etc/mkinitcpio.conf (sorry about any possible wrapping issue):
>
> MODULES="dm_mod"
> ...
> HOOKS="base udev mdadm_udev lvm2 autodetect pata scsi sata filesystems
> usbinput fsck"

I have two RAID setups that work well for me. On both, I don't have anything
in the MODULES line, and the following hooks:

HOOKS="base udev autodetect pata scsi sata mdadm lvm2 filesystems"

I hope this helps. I don't know anything about the mdadm_udev hook.

Paul

"Jrme M. Berger" 06-21-2012 05:13 PM

Installing to RAID .. cannot reboot
 
D. R. Evans wrote:
> Paul Gideon Dann said the following at 06/21/2012 03:41 AM :
>> On Wednesday 20 Jun 2012 11:27:54 D. R. Evans wrote:
>>> When I try to reboot, I receive the error message:
>>> ERROR: device /dev/md0 not found
>>> ERROR: unable to find root device /dev/md0
>> To me, this sounds like the RAID array is being given the wrong name, or the
>> mdadm hook isn't being added to /etc/mkinitcpio.conf.
>>
>
> Extract from /etc/mkinitcpio.conf (sorry about any possible wrapping issue):
>
> MODULES="dm_mod"
> ...
Try adding "raid1" there...

Jerome
--
mailto:jeberger@free.fr
http://jeberger.free.fr
Jabber: jeberger@jabber.fr


All times are GMT. The time now is 09:18 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.