Resizing Software RAID Arrays with mdadm
117
no
vd
ocx
(e
n)
7 Ja
nua
ry 201
0
Replace the disk on which the partition resides with a different device.
This option is possible only if no other file systems on the original disk are accessed by the
system. When the replacement device is added back into the RAID, it takes much longer
to synchronize the data.
5
Re-add the partition to the RAID array. For example, to add
/dev/sda1
, enter
mdadm -a /dev/md0 /dev/sda1
Wait until the RAID is synchronized and consistent before continuing with the next partition.
6
Repeat
Step 2
through
Step 5
for each of the remaining component devices in the array. Make
sure to modify the commands for the correct component partition.
7
If you get a message that tells you that the kernel could not re-read the partition table for the
RAID, you must reboot the computer after resizing all of its component partitions.
8
Continue with
Section 8.3.3, “Decreasing the Size of the RAID Array,” on page 117
.
8.3.3 Decreasing the Size of the RAID Array
After you have resized each of the component partitions in the RAID, the RAID array configuration
continues to use the original array size until you force it to be aware of the newly available space.
You can specify a size for the RAID or use the maximum available space.
The procedure in this section uses the device name
/dev/md0
for the RAID device. Make sure to
modify commands to use the name of your own device.
1
Open a terminal console, then log in as the
root
user or equivalent.
2
Check the size of the array and the device size known to the array by entering
mdadm -D /dev/md0 | grep -e "Array Size" -e "Device
Size"
3
Do one of the following:
Increase the size of the array to the maximum available size by entering
mdadm --grow /dev/md0 -z max
Increase the size of the array to a specified value by entering
mdadm --grow /dev/md0 -z
size
Replace
size
with an integer value in kilobytes for the desired size. (A kilobyte is 1024
bytes.)
4
Recheck the size of your array and the device size known to the array by entering
mdadm -D /dev/md0 | grep -e "Array Size" -e "Device
Size"
5
Do one of the following:
If your array was successfully resized, you are done.
If your array was not resized as you expected, you must reboot, then try this procedure
again.
Содержание LINUX ENTERPRISE SERVER 10 SP3 - ARCHITECTURE-SPECIFIC
Страница 4: ...4 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 30: ...30 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 42: ...42 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 76: ...76 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 108: ...108 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 118: ...118 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 124: ...124 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...
Страница 132: ...132 SLES 10 SP3 Storage Administration Guide novdocx en 7 January 2010...