Speed Up Rebuilding Linux Software RAID Arrarys

# cat /proc/mdstat

md0 : active raid5 sdf1[7] sdb1[0] sde1[5] sdg1[4] sdh1[3] sdd1[2] sdc1[1]
1465175424 blocks level 5, 64k chunk, algorithm 2 [7/6] [UUUUUU_]
[>………………..] recovery = 1.3% (3331200/244195904) finish=2357.0min speed=1700K/sec

Ouch. Two files are used to control the speed of rebuilding RAID arrays in Linux.

/proc/sys/dev/raid/speed_limit_min
/proc/sys/dev/raid/speed_limit_max

Even though my _max file is set to 200,000K/sec and my system is not doing anything, my RAID 5 rebuild process is hovering around the _min rebuild speed, of 1,000K/sec. With my setup this will take approximately 40 hours to complete, which is too long for me to wait. So, I pushed the _min speed up to 10,000K/sec, which will now take 6 hours to finish, and use slightly more of my system’s idle resources.

root# echo “10000” > /proc/sys/dev/raid/speed_limit_min

Later I set _min to 50,000K/sec, and the rebuild speed topped out at 25,000K/sec.

#cat /proc/mdstat

Personalities : [raid5]
md0 : active raid5 sdf1[7] sdb1[0] sde1[5] sdg1[4] sdh1[3] sdd1[2] sdc1[1]
1465175424 blocks level 5, 64k chunk, algorithm 2 [7/6] [UUUUUU_]
[=>……………….] recovery = 5.1% (12661840/244195904) finish=149.9min speed=25726K/sec

The rebuild took less than 3 hours, down from the original 40.

Find the Model Number of Your DVD Burner in Linux

$ cdrdao drive-info /dev/scd0

Cdrdao version 1.2.2 – (C) Andreas Mueller <[email protected]>
SCSI interface library – (C) Joerg Schilling
Paranoia DAE library – (C) Monty

Check http://cdrdao.sourceforge.net/drives.html#dt for current driver tables.

Using libscg version ‘ubuntu-0.8ubuntu1’

/dev/cdrw: LITE-ON DVDRW LH-20A1S Rev: 9L02
Using driver: Generic SCSI-3/MMC – Version 2.0 (options 0x0000)

Maximum reading speed: 8467 kB/s
Current reading speed: 8467 kB/s
Maximum writing speed: 8467 kB/s
Current writing speed: 8467 kB/s
BurnProof supported: yes
JustLink supported: no
JustSpeed supported: yes