[Eisfair] Volle root-Partition E1 mit Software-Raid 5

Jürgen Witt j-witt at web.de
Sa Jan 3 06:54:29 CET 2015


Hallo Thomas (und die, die mitlesen),

Am 15.12.2014 um 14:55 schrieb Thomas Zweifel:
> Am 15.12.2014 um 14:31 schrieb Jürgen Witt:
>
>> Ich werde auf jeden Fall berichten, (vom Testsystem und danach vom
>> Produktivsystem) wie es gelaufen ist und ob und welche Probleme es gab.
>
> Da bin ich gespannt was kommt....

es hat nun etwas gedauert, aber jetzt ich habe gerade angefangen auf 
meinem RAID1-Testsystem (bestehend aus 2 80GB-Festplatten) Deine 
Anleitung abzuarbeiten. Der erste Teil ist ja einfach und ich 
dokumentiere ihn hier einfach 'mal.

Ursprungszustand:

eis # mount
/dev/md3 on / type ext4 (rw,errors=remount-ro,acl,user_xattr)
/dev/md1 on /boot type ext4 (rw,errors=remount-ro)
/dev/md4 on /data type ext4 (rw,acl,user_xattr)
devpts on /dev/pts type devpts (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/sys on /sys type sysfs (rw)
/dev/sdc4 on /mountpoint type ext4 (rw,acl,user_xattr)
nfsd on /proc/fs/nfsd type nfsd (rw)
rpc_pipefs on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
tmpfs on /brute_force_blocking type tmpfs (rw,size=2m)
192.168.170.200:/mountpoint/data on /backup type nfs 
(ro,user=root,noexec,nosuid,nodev,addr=192.168.170.200)

"Freimachen" von /data bzw. /dev/md4

eis # umount /backup
eis # /etc/init.d/nfsserver stop
Stopping NFSserver ...
- rpc.mountd ...
- rpc.idmapd ...
- nfsd ...
- rpc.statd ...
- rpcbind ...
eis # umount /mountpoint
eis # umount /data

Ergebnis:

eis # mount
/dev/md3 on / type ext4 (rw,errors=remount-ro,acl,user_xattr)
/dev/md1 on /boot type ext4 (rw,errors=remount-ro)
devpts on /dev/pts type devpts (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/sys on /sys type sysfs (rw)
tmpfs on /brute_force_blocking type tmpfs (rw,size=2m)

Überprüfen des Dateisystems:

eis # e2fsck -f -C0 /dev/md4
e2fsck 1.42.12 (29-Aug-2014)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/md4: 1340/3964928 files (5.2% non-contiguous), 2869326/15853968 blocks

Verkleinern des Dateisystems:

eis # resize2fs -p /dev/md4 3000000
resize2fs 1.42.12 (29-Aug-2014)
resize2fs: New size smaller than minimum (3153173)

OK, 2. Versuch :-)

eis # resize2fs -p /dev/md4 3200000
resize2fs 1.42.12 (29-Aug-2014)
Resizing the filesystem on /dev/md4 to 3200000 (4k) blocks.
Begin pass 2 (max = 267937)
Relocating blocks             XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Begin pass 3 (max = 484)
Scanning inode table          XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Begin pass 4 (max = 82)
Updating inode references     XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
The filesystem on /dev/md4 is now 3200000 (4k) blocks long.

Überprüfen des Dateisystems:

eis # e2fsck -f -C0 /dev/md4
e2fsck 1.42.12 (29-Aug-2014)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/md4: 1340/802816 files (8.0% non-contiguous), 2667859/3200000 blocks

Versuch das Raid-Device zu verkleinern:

eis # mdadm -G -z6656000 /dev/md4
mdadm: Cannot set device size for /dev/md4: Device or resource busy
        Bitmap must be removed before size can be changed

An der Stelle hänge ich jetzt fest. Auch ein Reboot (vorsichtshalber mit 
auskommentierten Zeilen, die /dev/md4 bzw. /data betreffen) bringt mich 
da nicht weiter. Was ist jetzt zu tun?

Danke und Gruß
Jürgen


Mehr Informationen über die Mailingliste Eisfair