Linux - Server This forum is for the discussion of Linux Software used in a server related context. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
02-20-2011, 03:21 AM
|
#1
|
LQ Newbie
Registered: Feb 2011
Posts: 5
Rep:
|
Weird problem with software raid-5 mdadm
My only goal is to have a raid-5 that auto-assembles and auto-mounts.
Hardware: 4*2TB sata (raid disks), 1*500GB IDE (OS disk), 1*DVD IDE
all plugged direct into the motherboard (nForce 750i SLI).
Starting partitions on the raid disks: gpt ext4
The problem occurs when I restart my comp after building it for the first time. I am able to see it assemble, I am able to partition it, I even mounted it... Once. This is the second time I've built it so I have watched everything that happened.
I don't know if this has anything to do with my problem, but when I created the raid my drive designations were: sda - 500GB(OS), sd[bcde] - 2TB(raid). When I restarted: sd[abcd] - 2TB(raid), sde - 500GB(OS).
Here is what I got when I tried to assemble the raid:
newageretrohippie@Hippie-Media:~$ sudo mdadm --assemble --scan
[sudo] password for newageretrohippie:
mdadm: /dev/md/0 assembled from 2 drives - not enough to start the array.
mdadm: No arrays found in config file or automatically
newageretrohippie@Hippie-Media:~$ sudo mdadm --assemble /dev/md0 --uuid=618e35ea-b9f8-0614-bf63-62629b301141
mdadm: /dev/md0 assembled from 2 drives - not enough to start the array.
Do I have to stop the raid when I restart? Do I have to change mdadm.conf?
I originally tried it through the Disk Utility UI to no avail. I would build it, it would reconstruct or whatever then if I reopened Disk Utility it would say 'Warning: The partition is misaligned by 1031168 bytes. This may result in very poor performance. Repartitioning is suggested.'. I repartitioned it and got the exact same error.
I would love to be able to have it working in Disk Utility (I prefer UI's to command line).
Help please - I've had these drives for months now, unable to use them.
|
|
|
02-20-2011, 08:27 PM
|
#2
|
Member
Registered: Oct 2003
Location: Texas (central)
Distribution: ubuntu,Slackware,knoppix
Posts: 323
Rep:
|
What distribution are you using? You shouldn't need mdadm.conf anymore. mdadm can pull it off the drives. Have you set the partitions of the RAID to "fd"
Should be something like:
mdadm -Cv /dev/md0 /dev/sdb /dev/sdc /dev/sdc /dev/sde --level=5 --raid-devices=4
plus whatever other arguments you prefer.
|
|
|
02-21-2011, 02:31 AM
|
#3
|
LQ Newbie
Registered: Feb 2011
Posts: 5
Original Poster
Rep:
|
I'm not sure what it means to set partitions to "fd"..
I would just do 'sudo mdadm -create /dev/md0 --level=5 --raid-devices=4 /dev/sd[bcde] -chunk=1024'
|
|
|
02-21-2011, 09:13 AM
|
#4
|
Member
Registered: Oct 2003
Location: Texas (central)
Distribution: ubuntu,Slackware,knoppix
Posts: 323
Rep:
|
When partitioning the drives with fdisk or gpartd, etc, instead of setting them to FAT, or EXT2, or whatever, set them to Linux Raid, which I believe is code "fd".
After you have the raid setup, you mkfs the type file system you want on it the /dev/md0.
You may find it helpful to
cat /proc/mdstat
to watch the rebuild happen after you initially create the drive.
You can, of course, start using the drives right away, but if you are loading an bootable os on them, confusing things can happen if you don't give it a good head start on building.
|
|
|
All times are GMT -5. The time now is 12:38 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|