Skip to contentSkip to conversation

raid5 grow reshaping speed is unchangeable

DISCUSSION Cody Yellan 2 participants 2 messages Dec 28, 2007 – Dec 29, 2007 MD RAID

lore
Share & tools
lore
#0 lore raw
Quoted 17 lines
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines · Cody Yellan

I had a 4x500GB SATA2 array, md0. I added one 500GB drive and reshaping began at ~2500K/sec. Changing /proc/sys/dev/raid/speed_limit_m{in,ax} or /sys/block/md0/md/sync_speed_m{in,ax} had no effect. I shut down

all

Quoted 1 line
Quoted 1 line
Quoted 1 line

unnecessary services and the array is offline (not mounted). I

have

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

read that the throttling code is "fragile" (esp. with regard to raid5) but does this make sense? I will wait (in)patiently for

it to

Quoted 6 lines
Quoted 3 lines
Quoted 3 lines

finish, but I do wonder why the configuration parameters have no effect. This is a dual quad 2GHz Xeon machine with 8GB of memory running RHEL5. Is this the maximum speed?

Are you running a non-standard /sys/block/md5/md/stripe_cache_size?

Quoted 12 lines
Quoted 6 lines

I found when running a kernel of about that vintage on FC6 (which I guess became RHEL5), that with a stripe_cache_size of 16384, resyncs

dropped down to about the speed you are seeing.

This changed back to more normal speeds with a later kernel, but I

do

Quoted 5 lines

not recall which.

Regards,

Richard

You are right, Richard. RHEL5 had a stripe_cache_size of 256 when the reshape began. I increased it to 1024 and the reshape speed doubled to 4500K/s. I did not see any increase in memory usage. I tried 2048 and then 4096 but saw no difference in speed.

The reshape finished and the array is back online. mdadm works very well, but I would like to better understand how it works. For instance, the mdadm man page says a backup-file is necessary to grow a RAID5, but this does not appear necessary now. Anyway, it's a wonderful tool.

#1 lore raw
Quoted 4 lines · Cody Yellan

You are right, Richard. RHEL5 had a stripe_cache_size of 256 when the reshape began. I increased it to 1024 and the reshape speed doubled to 4500K/s. I did not see any increase in memory usage. I tried 2048 and then 4096 but saw no difference in speed.

Sorry, I did not make myself clear.

Back when I was seeing the slow resync speeds, it was due to larger than default stripe_cache_size - I had increased to 16384.

When this was reduced back to the default, which I suspect is 256, speeds were back up to more normal levels - much faster than the 4.5MB/s you are seeing.

At some point, this issue was fixed and currently on 2.6.22, with a stripe_cache_size of 16384 and a 4 x 500GB SATA II md RAID 5, resync speed is 162MB/s.

Perhaps somthing different occurs on a reshape, (which I have only now realised you were doing).

Regards,

Richard