Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 230207 - Incorrect metadata version returned by "mdadm --examine --scan"
Summary: Incorrect metadata version returned by "mdadm --examine --scan"
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: mdadm
Version: 6
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Doug Ledford
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-02-27 14:46 UTC by josip
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version: 2.6.2-4.fc7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-07-20 19:35:49 UTC


Attachments (Terms of Use)

Description josip 2007-02-27 14:46:32 UTC
Description of problem:
"mdadm --examine --scan" incorrectly returns metadata=1 for raid arrays created
with "--metadata=1.2", breaking assembly based on this incorrect information.


Version-Release number of selected component (if applicable):
mdadm-2.5.4-2.fc6

How reproducible:
Always

Steps to Reproduce:
1. mdadm --create ... --metadata=1.2 ... [note 1.2 style superblock]
2. mdadm --examine --scan
3. observe results
  
Actual results:
ARRAY /dev/md/home level=raid10 metadata=1 num-devices=6 UUID=... name=home

Expected results:
ARRAY /dev/md/home level=raid10 metadata=1.2 num-devices=6 UUID=... name=home

Additional info:
Note that metadata=1 (if entered into /etc/mdadm.conf) breaks array assembly
since it indicates incorrect position of the superblock.  "mdadm --examine
--scan" should return the correct "metadata=1.2" information because most people
use this command to populate /etc/mdadm.conf.

Comment 1 Doug Ledford 2007-07-02 21:06:49 UTC
There are actually two issues here.  First, when using mdadm -E, mdadm never
specified the exact superblock type.  If superblock type is anything other than
1.0, it's not listed correctly.  The second issue is that when you specify a
superblock version in the config file, it takes that as a strict requirement. 
So, the fact that it didn't output strictly correct output, but required strict
input in the config file was the total problem.  I've created a patch that
solves the issue.  It outputs strict output when examining devices, but also
modifies the input side of things so that an input of metadata=1 or
metadata=default/large will scan for different locations.  It is only strict on
input now if the input specifies the exact superblock location by using one of
1.0/1.1/1.2.  These changes will appear in the mdadm-2.6.2-2 package.

Comment 2 Fedora Update System 2007-07-05 19:11:59 UTC
mdadm-2.6.2-2.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.

Comment 3 Fedora Update System 2007-07-09 15:47:40 UTC
mdadm-2.6.2-3.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.

Comment 4 Fedora Update System 2007-07-10 06:42:13 UTC
mdadm-2.6.2-4.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.

Comment 5 Fedora Update System 2007-07-20 19:35:13 UTC
mdadm-2.6.2-4.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.


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