[Eisfair] Defekte RAID Platte durch größere Neue ersetzen - wie stelle ich es am "dümmsten" an?

Jürgen Witt j-witt at web.de
Do Feb 5 18:44:46 CET 2015


Hallo Thomas,

Am 27.01.2015 um 12:03 schrieb Thomas Zweifel:

> Eine neue Platte als sdb anschliessen, starten und partitionieren.
> Bei der Gelegenheit auch gleich root, /boot und swap nach Bedarf
> vergrössern.

OK

> Danach sdb zum raid hinzufügen und den resync abwarten, und lilo aufrufen.

OK

> Herunterfahren und die heilgebliebene 500er abklemmen, und die zweite TB
> Platte als sdb anschliessen und wieder starten.

OK

> sdb gleich wie die Erste partitionieren, zum raid hinzufügen und den
> resync abwarten, und lilo aufrufen.

OK

> Nun die md auf die neuen Partitionsgrössen anpassen, und die
> Dateisysteme vergrössern. Nochmals lilo aufrufen (sicherheitshalber),
> wenn Du /boot auch vergrössert hast.

bis hier war es für mich nachvollziehbar und einfach :-)
Wie passe/vergrößere ich die mds an? Und die Dateisystem? Ich habe da 
wohl generell noch ein Verständnisproblem :-(

> Zum Schluss noch den swap stoppen, neuanlegen und wieder starten (falls
> ebenfalls vergrössert).

so weit bin ich noch nicht :-)

Hier erst einmal der Stand meines Testsystems. Ursprung war ein heiles 
Raid-1 aus 2 80GB Platten, bei dem ich eine Platte als defekt deklariert 
und entfernt habe. Die neuen Platten sind 1TB groß.

eis # sgdisk -p /dev/sda
Disk /dev/sda: 1953525168 sectors, 931.5 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): B34946C6-684D-4E94-90F0-21654B0312B6
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 1953525134
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)

Number  Start (sector)    End (sector)  Size       Code  Name
    1            2048          112639   54.0 MiB    8300
    2          112640         8501247   4.0 GiB     8300
    3         8501248        71415807   30.0 GiB    8300
    4        71415808      1953525134   897.5 GiB   8300

eis # sgdisk -p /dev/sdb
Disk /dev/sdb: 1953525168 sectors, 931.5 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): 6BD617CB-1DC2-4E9C-B19A-9F424E80F7BC
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 1953525134
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)

Number  Start (sector)    End (sector)  Size       Code  Name
    1            2048          112639   54.0 MiB    8300
    2          112640         8501247   4.0 GiB     8300
    3         8501248        71415807   30.0 GiB    8300
    4        71415808      1953525134   897.5 GiB   8300

eis # df -h
Filesystem                        Size  Used Avail Use% Mounted on
/dev/md3                          9.9G  1.7G  7.7G  18% /
/dev/md1                           53M   13M   38M  25% /boot
/dev/md4                           60G  9.2G   48G  17% /data
tmpfs                             4.0G   28K  4.0G   1% /dev/shm
tmpfs                             2.0M  280K  1.8M  14% 
/brute_force_blocking

  cat /proc/mdstat
Personalities : [linear] [raid0] [raid1] [raid10] [raid6] [raid5] 
[raid4] [multipath]
md4 : active raid1 sdb4[3] sda4[2]
       63415948 blocks super 1.2 [2/2] [UU]

md3 : active raid1 sda3[2] sdb3[3]
       10482251 blocks super 1.2 [2/2] [UU]

md2 : active raid1 sda2[2] sdb2[3]
       4150720 blocks super 1.2 [2/2] [UU]
       bitmap: 0/1 pages [0KB], 65536KB chunk

md1 : active raid1 sda1[0] sdb1[1]
       55104 blocks [2/2] [UU]
       bitmap: 0/1 pages [0KB], 65536KB chunk

unused devices: <none>

Gruß
Jürgen





Mehr Informationen über die Mailingliste Eisfair