12.1. Multiple partitions on the same disk
LVM allows you to create PVs (physical volumes) out of almost any
block device so, for example, the following are all valid commands
and will work quite happily in an LVM environment:
# pvcreate /dev/sda1
# pvcreate /dev/sdf
# pvcreate /dev/hda8
# pvcreate /dev/hda6
# pvcreate /dev/md1
In a "normal" production system it is recommended that
only one PV exists on a single real disk, for the following
It's easier to keep track of the hardware in a system if
each real disk only appears once. This becomes
particularly true if a disk fails.
To avoid striping performance problems
LVM can't tell that two PVs are on the same physical disk,
so if you create a striped LV then the stripes could be on
different partitions on the same disk resulting in a
decrease in performance
rather than an increase.
However it may be desirable to do this for some reasons:
Migration of existing system to LVM
On a system with few disks it may be necessary to move
data around partitions to do the conversion (see
Splitting one big disk between Volume Groups
If you have a very large disk and want to have more than
one volume group for administrative purposes then it is
necessary to partition the drive into more than one area.
If you do have a disk with more than one partition and both of
those partitions are in the same volume group, take care to specify
which partitions are to be included in a logical volume when
creating striped volumes.
The recommended method of partitioning a disk is to create a single
partition that covers the whole disk. This avoids any nasty
accidents with whole disk drive device nodes and prevents the
kernel warning about unknown partition types at boot-up.