Using LVM in linux:
- pvcreate /dev/sdb
Creates a Physical Volume of the whole device. Not advisable if you use other OS's that
might view the device as unused.
- vgcreate DataVG /dev/sdb
Create a Volume Group called DataVG
- lvcreate -l 90%VG -n DataLV1 DataVG
Create a Logical Volume called DataLV1 in volume group DataVG and
allocate 90% of the space in the VG to it
- mkfs.ext3 /dev/DataVG/DataLV
Format the LV
- pvcreate /dev/sdc
Create another PV
- vgextend DataVG /dev/sdc
Extend the VG with the PV
- lvextend -l +50%FREE /dev/DataVG/DataLV1
Add 50% of the free space in the VG to the LV
- resize2fs /dev/DataVG/DataLV1
Resize the filesystem