Resizing Software RAID Arrays with mdadm
111
no
vd
ocx
(e
n)
7 Ja
nua
ry 201
0
Table 8-3
Scenario for Increasing the Size of Component Partitions
To increase the size of the component partitions for the RAID:
1
Open a terminal console, then log in as the
root
user or equivalent.
2
Make sure that the RAID array is consistent and synchronized by entering
cat /proc/mdstat
If your RAID array is still synchronizing according to the output of this command, you must
wait until synchronization is complete before continuing.
3
Remove one of the component partitions from the RAID array. For example, to remove
/dev/
sda1
, enter
mdadm /dev/md0 --fail /dev/sda1 --remove /dev/sda1
In order to succeed, both the fail and remove actions must be done.
4
Increase the size of the partition that you removed in
Step 3
by doing one of the following:
Increase the size of the partition, using a disk partitioner such as
fdisk(8)
,
cfdisk(8)
,
or
parted(8)
. This is the usual choice.
Replace the disk on which the partition resides with a higher-capacity 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 because all of the data that was on the original device must be
rebuilt.
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 all partitions have been resized to force an update of
the partition table.
8
Continue with
Section 8.2.2, “Increasing the Size of the RAID Array,” on page 111
.
8.2.2 Increasing the Size of the RAID Array
After you have resized each of the component partitions in the RAID (see
Section 8.2.1, “Increasing
the Size of Component Partitions,” on page 110
), 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.
RAID Device
Component Partitions
/dev/md0
/dev/sda1
/dev/sdb1
/dev/sdc1
Содержание 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...