Step-by-step guide
Check devices installed using
'fdisk -l'
You can also use'df -h'
to view list of devices in MB/GB's#Example:
[
]#root@admin
Device Boot Start End Blocks Id System:~$ fdisk -l
/dev/sda1 * 1 20 153600 83 Linux
/dev/sda2 20 36990 296960000 83 Linux
/dev/sda3 36990 52287 122880000 83 Linux
/dev/sda4 52287 91202 312579072 5 Extended
/dev/sda5 52288 65036 102400000 83 Linux
/dev/sda6 65036 66311 10240000 82 Linux swap / Solaris
/dev/sda7 66311 91202 199936000 83 LinuxCheck to make sure the device you use is properly partitioned for the RAID array you plan on adding it to
Check your current RAID configuration using
Example:'/proc/mdstat'
to ensure you know which RAID array you are targeting
[root@admin]#
Personalitiesroot@admin:~$ cat /proc/mdstat
Personalities :
[raid1]
[raid6]
[raid5]
md1[raid4]
md1 :
active
raid1
sdb2[1]
136448 blockssda2[0]
136448 blocks [2/2]
md2[UU]
md2 :
active
raid1
sda3sdb3[1]
129596288 blocksada3[0]
129596288 blocks [2/2]
md3[UU]
md3 :
active
sdl1raid5
adl1[9]
sdk1[8]
[7] sdi1sdj1
[6]
sdh1[5]
sdg1[4]
sdf1[3]
sdd1sde1[2]
sdc1sdd[1]
1318680576 blocks level 5, 1024k chunk, algorithm 2sdc[0]
1318680576 blocks level 5, 1024k chunk, algorithm 2 [10/10]
md0[UUUUUUUUUU]
md0 :
active
sdb1raid1
sda1sdb[1]
16787776 blockssda[0]
167877736 blocks [2/2]
[UU]
unused
devices:
<none>
Add device to RAID array using 'sudo mdadm --manage /dev/md# --add /dev/sdx#'
Example
[#Example:
]#root@admin
:~$ sudo mdadm --manage /dev/md1 --add /dev/sda3
Check status in '/proc/mdstat'
Example
Personalities#Example:
Personalities :
[raid1]
[raid6]
[raid5]
md127[raid4]
md127 :
active
raid5
sdh1[6]
sdg1[4]
sde1sdf1[3]
sdeq[2]
sdd1[1]
1464725760 blocks level 5, 64k chunk, algorithm 2sdc1[0]
1464725760 blocks level 5, 64k chunk, algorithm 2 [6/5]
[UUUUU_]
recovery
[===>.................]
recovery =
14.2%
(41598211/292945152)
finish=125.5min
speed=33440K/sec
Filter by label (Content by label) | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
...