Bug 207541 - --useexisting can't find the existing RAID devices
--useexisting can't find the existing RAID devices
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: anaconda (Show other bugs)
4.0
All Linux
high Severity high
: ---
: ---
Assigned To: Chris Lumens
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-09-21 11:15 EDT by Bastien Nocera
Modified: 2010-10-22 02:07 EDT (History)
2 users (show)

See Also:
Fixed In Version: RHBA-2007-0816
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-11-15 11:35:14 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
raidsb-test.c (4.20 KB, text/plain)
2006-09-21 11:16 EDT, Bastien Nocera
no flags Details

  None (edit)
Description Bastien Nocera 2006-09-21 11:15:53 EDT
anaconda-10.1.1.46-1

1. Setup a machine using RAID
2. Get the anaconda kickstart file, replace the raid lines with --useexisting.
For example, replace:
raid /boot --fstype ext3 --device=md0 --level=RAID1 raid.01 raid.11
with:
raid /boot --device=md0 --useexisting
3. anaconda won't find the RAID devices, and print the error:
* couldn't get chunksize of md0: bad md magic on device

The attached test case (a stand-alone version of what anaconda's isys does, both
in RHEL4 and HEAD) shows the same problem:
$ ./raidsb-test /dev/md0
not md magic

And in python:

import sys
>>> sys.path.append("/usr/lib/anaconda")
>>> import isys
>>> (major, minor, raidSet, level, nrDisks, totalDisks, mdMinor) =
isys.raidsb("md0")
Traceback (most recent call last):
 File "<stdin>", line 1, in ?
 File "/usr/lib/anaconda/isys.py", line 97, in raidsb
   return raidsbFromDevice("/tmp/md")
 File "/usr/lib/anaconda/isys.py", line 103, in raidsbFromDevice
   rc = _isys.getraidsb(fd)
ValueError: bad md magic on device

mdadm works though, but doesn't find a superblock either:
mdadm -Q /dev/md0
/dev/md0: 101.88MiB raid1 2 devices, 0 spares. Use mdadm --detail for more detail.
/dev/md0: No md super block found, not an md component.

It looks like anaconda never sets the magic on those devices.
Comment 1 Bastien Nocera 2006-09-21 11:16:03 EDT
Created attachment 136866 [details]
raidsb-test.c
Comment 2 Bastien Nocera 2006-09-21 11:26:12 EDT
Check whether it's actually writing the magic and superblocks on the devices.
mdadm --create (which anaconda uses) is supposed to write those superblocks.
Comment 3 Bastien Nocera 2006-12-04 05:25:39 EST
From Brent:

"
RHEL4 U4 also fails to set the superblock md data:

[root@wudan ~]# cat /etc/redhat-release
Red Hat Enterprise Linux AS release 4 (Nahant Update 4)

[root@wudan ~]# mdadm -Q /dev/md0
/dev/md0: 101.88MiB raid1 2 devices, 0 spares. Use mdadm --detail for more detail.
/dev/md0: No md super block found, not an md component.

[root@wudan ~]# mdadm -Q /dev/md1
/dev/md1: 15.11GiB raid0 2 devices, 0 spares. Use mdadm --detail for more detail.
/dev/md1: No md super block found, not an md component.

[root@wudan ~]# mdadm -Q /dev/md2
/dev/md2: 1678.50MiB raid0 2 devices, 0 spares. Use mdadm --detail for more detail.
/dev/md2: No md super block found, not an md component.
"
Comment 5 RHEL Product and Program Management 2007-05-09 05:34:59 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.
Comment 7 Chris Lumens 2007-08-22 11:47:22 EDT
There's no more time for working on this in 4.6, so we'll have to bump it to 4.7.
Comment 11 Chris Lumens 2007-09-06 16:35:51 EDT
I've committed a potential fix that should be in tomorrow's nightly tree.  I'd
like to get some testing done there before it goes into the next snapshot for
customer testing.
Comment 13 Alexander Todorov 2007-09-20 05:39:46 EDT
Test fails with the attached reproducer from comment #1 and mdadm says:

[root@bohr ~]# mdadm -Q /dev/md0
/dev/md0: 33.28GiB raid1 4 devices, 0 spares. Use mdadm --detail for more detail.
/dev/md0: No md super block found, not an md component.

Using anaconda-ks.cfg seems to work. The relevant part of the file is:

#clearpart --all
part /boot/efi --fstype vfat --onpart sda1
part raid.2 --noformat --onpart sda2
part raid.5 --noformat --onpart sdb2
part raid.4 --noformat --onpart sdb1
part swap --onpart sdb3
part raid.3 --noformat --onpart sda3
raid / --device=md0 --useexisting

Please give more details how to reproduce using kickstart file.
Comment 15 Alexander Todorov 2007-09-20 08:09:22 EDT
My apologies, tested with an older version of anaconda that the one in errata.
Will retest soon.
Comment 18 errata-xmlrpc 2007-11-15 11:35:14 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2007-0816.html
Comment 20 andreas 2008-06-19 05:37:13 EDT
i'm Cann't install Redhat Enterprise linux 4 on my laptop, specification my 
computer : 
 Presario V3000
 Intel Core 2 Duo 1.88 Ghz
 Ram 1 Gb
 Hdd Samsung HM160HI

 I'm cann't find for driver instalation on sata driver.
 Please  send me driver sata driver for my laptop on my email.

 Tahnk's
 Andre

Note You need to log in before you can comment on or make changes to this bug.