Bug 113963

Summary: mdadm - unable to add additional devices.
Product: Red Hat Enterprise Linux 3 Reporter: Frank LeFevre <lefevre>
Component: mdadmAssignee: Emiliano Abramzon <abramzon>
Status: CLOSED NOTABUG QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: billgo, bjohnson, laroche, markwiz, mpeschke
Target Milestone: ---   
Target Release: ---   
Hardware: s390   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-01-21 13:58:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Frank LeFevre 2004-01-20 19:02:03 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 5.0; YComp 
5.0.0.0; H010818)

Description of problem:
Attempting to add a disk to an active array fails.



Version-Release number of selected component (if applicable):
mdadm-1.4.0-1

How reproducible:
Always

Steps to Reproduce:
1.mdadm -Cv /dev/md2 -l0 -n9 -c128 /dev/sd{a,b,c,d,e,f,g,h,i}1
2.mke2fs -b 4096 -j /dev/md2
3.mount /dev/md2 /mnt
4.mdadm /dev/md2 --add /dev/sdj1
  

Actual Results:  mdadm: hot add failed for /dev/sdj1: Invalid argument

Expected Results:  Device should be added to active array /dev/md2.

Additional info:

Comment 1 Bob Johnson 2004-01-20 20:25:14 UTC
From Doug Ledford.

No, this will never work.  They are creating a raid0 array. 
Raid0arrays have no redundancy and don't support spare drives.  If you
have araid5 array and add a disk, it doesn't make the array larger, it
justputs a spare disk in the array so that reconstruction can
startautomatically in the event one of the regular disks fails.  If
you want to add a disk to an array and have it actually increase the
size of thearray, then you have to use the raidresize (or something
like that,can't remember for sure off the top of my head, but it's on
the rescueCD) to recreate the array with the new disk and the utility
takes careof shuffling all the data into the right positions on the
disks so thatit ends up just being a larger array with your data still
intact (then you have to use resize2fs to increase the filesystem size
as well).