— sprawdzamy co chcemy rozszerzyć
[root@dm01dbadm01 ~]# df -h /
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VGExaDb-LVDbSys1 30G 25G 3.7G 87% /
[root@dm01dbadm01 ~]# lvs | grep LVDbSys
LVDbSys1 VGExaDb -wi-ao—- 30.00g
LVDbSys2 VGExaDb -wi-a—– 30.00g
— ile mamy miejsca dostępnego
[root@dm01dbadm01 ~]# vgdisplay VGExaDb -s
„VGExaDb” 1.63 TiB [285.00 GiB used / <1.36 TiB free]
— dorzucamy 20G
lvextend -L +20G /dev/VGExaDb/LVDbSys1
lvextend -L +20G /dev/VGExaDb/LVDbSys2
— sprawdzamy:
[root@dm01dbadm01 ~]# lvs | grep LVDbSys
LVDbSys1 VGExaDb -wi-ao—- 50.00g
LVDbSys2 VGExaDb -wi-a—– 50.00g
— resize:
[root@dm01dbadm01 ~]# resize2fs /dev/VGExaDb/LVDbSys1
[root@dm01dbadm01 ~]# resize2fs /dev/VGExaDb/LVDbSys2
— moze byc wymagany e2fsck do resize-a:
[root@dm01dbadm02 ~]# resize2fs /dev/VGExaDb/LVDbSys2
resize2fs 1.42.9 (28-Dec-2013)
Please run 'e2fsck -f /dev/VGExaDb/LVDbSys2′ first.
[root@dm01dbadm01 ~]# e2fsck -f /dev/VGExaDb/LVDbSys2
…
[root@dm01dbadm01 ~]# resize2fs /dev/VGExaDb/LVDbSys2
— sprawdzamy:
[root@dm01dbadm01 ~]# df -h /
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VGExaDb-LVDbSys1 50G 25G 23G 52% /