Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm building a raid 5 array with 3 1.5TB drives on CentOS 5.5 using mdadm. Everything seems to be working fine, except it's taking forever and I'm not sure if that's normal. It's going on 6 hours now and /proc/mdstat says it's only at 6% (@ ~37MBps). At this rate it's going to take the better half of a week to finish.

I've never setup a raid before so I'm not sure if I did something wrong. It seems like the initial setup should be a lot faster since there is no data on any of the drives.

Also, after I have the raid set up I've got data to transfer over from a drive then I'll be adding it to the array. Is it going to take a similar amount of time to grow the array after? I know they're huge hard drives but this seems ridiculous.

share|improve this question
add comment

1 Answer

There have been many other questions asking this (others will surely post comments with them), but I happen to have this sitting open:

HowTo: Speed Up Linux Software Raid Building And Re-syncing

In summary: change your /proc/sys/dev/raid/{speed_limit_max,speed_limit_min} to something larger.

From the article:

To see current limits, enter:

sysctl dev.raid.speed_limit_min

sysctl dev.raid.speed_limit_max

To increase speed, enter:

echo value > /proc/sys/dev/raid/speed_limit_min

OR

sysctl -w dev.raid.speed_limit_min=value

Bitmaps optimize rebuild time after a crash, or after removing and re-adding a device. Turn it on by typing the following command:

mdadm --grow --bitmap=internal /dev/md0

Once array rebuild or fully synced, disable bitmaps:

mdadm --grow --bitmap=none /dev/md0

share|improve this answer
    
Thanks for the help, I really didn't see this when searching. I went ahead and implemented the changes but didn't any increase in speed. I asked this on reddit.com too and someone mentioned that the array is still usable while the initial creation is running, and lo and behold, it is, so it's formatting now. –  jlorich Jul 24 '10 at 9:06
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.