One nice feature in MythDora is that it places the partition that stores video on a LVM volume.
LVM permits a single disk partition to "span" across more than one physical disk. When adding additional disks to grow your media library, you can expand your existing media partition right onto and across the new drives instead of having to figure out how to split things up.
If you know your way around things, the Quick Summary may be all you need. If you want to see everything I went through to add a disk to my volume, the Detailed Steps shows every screen, prompt, and all user input.
Quick Summary:
- fdisk /dev/hdb - Create a new partition of type "8e" to expand into. In this example "/dev/hdb1".
- pvcreate /dev/hdb1 - Create the new physical volume on the new partition.
- vgscan - Scan the volume groups.
- vgdisplay videovg - Display current volume group information. Note "Cur PV" value.
- vgextend videovg /dev/hdb1 - Add the new physical volume to the "videovg" volume group.
- vgdisplay videovg - Confirm "Cur PV" count has increased by 1. Note the "VG Size" to use for lvextend later.
- lvscan - Scan the logical volumes. Make note of the path of the videovg path for use in lvextend.
- lvextend -L 291.09G /dev/videovg/videolv01 - Extend the logical volume using the "VG Size" and videovg path noted earlier.
- ext2online /video - expand the ext3 partition to fill the newly expanded disk.
Detailed Steps:
Disk /dev/hda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 19 152586 83 Linux
/dev/hda2 20 911 7164990 8e Linux LVM
/dev/hda3 912 19457 148970745 8e Linux LVM
[root@mythserver ~]# fdisk /dev/hdb
The number of cylinders for this disk is set to 19457. There is nothing wrong with that, but this is larger than 1024, and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO) 2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK) Command (m for help): p Disk /dev/hdb: 160.0 GB, 160041885696 bytes 255 heads, 63 sectors/track, 19457 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-19457, default 1): 1 Last cylinder or +size or +sizeM or +sizeK (1-19457, default 19457): 19457 Command (m for help): t Selected partition 1 Hex code (type L to list codes): 8e Changed system type of partition 1 to 8e (Linux LVM) Command (m for help): p Disk /dev/hdb: 160.0 GB, 160041885696 bytes 255 heads, 63 sectors/track, 19457 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/hdb1 1 19457 156288321 8e Linux LVM Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. Syncing disks.
[root@mythserver ~]# pvcreate /dev/hdb1
Physical volume "/dev/hdb1" successfully created
[root@mythserver ~]# vgscan
Reading all physical volumes. This may take a while...
Found volume group "videovg" using metadata type lvm2
Found volume group "rootvg" using metadata type lvm2
[root@mythserver ~]# vgdisplay videovg
--- Volume group ---
VG Name videovg
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 2
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 1
Max PV 0
Cur PV 1
Act PV 1
VG Size 142.06 GB
PE Size 32.00 MB
Total PE 4546
Alloc PE / Size 4545 / 142.03 GB
Free PE / Size 1 / 32.00 MB
VG UUID TmE0AD-HORo-biHu-1N40-1rEq-gWSM-K0iDmG
[root@mythserver ~]# vgextend videovg /dev/hdb1
Volume group "videovg" successfully extended
[root@mythserver ~]# vgdisplay videovg
--- Volume group --- VG Name videovg System ID Format lvm2 Metadata Areas 2 Metadata Sequence No 3 VG Access read/write VG Status resizable MAX LV 0 Cur LV 1 Open LV 1 Max PV 0 Cur PV 2 Act PV 2 VG Size 291.09 GB PE Size 32.00 MB Total PE 9315 Alloc PE / Size 4545 / 142.03 GB Free PE / Size 4770 / 149.06 GB VG UUID TmE0AD-HORo-biHu-1N40-1rEq-gWSM-K0iDmG
[root@mythserver ~]# lvscan
ACTIVE '/dev/videovg/videolv01' [142.03 GB] inherit
ACTIVE '/dev/rootvg/rootlv01' [5.88 GB] inherit
ACTIVE '/dev/rootvg/rootlv02' [928.00 MB] inherit
[root@mythserver ~]# lvextend -L 291.09G /dev/videovg/videolv01
Rounding up size to full physical extent 291.09 GB Extending logical volume videolv01 to 291.09 GB Logical volume videolv01 successfully resized
[root@mythserver ~]# ext2online /video
ext2online v1.1.18 - 2001/03/18 for EXT2FS 0.5b
[root@mythserver ~]#
References:
LVM HOWTO

The ext2online program has