PVCREATE(8)

NAME
pvcreate - initialize a disk or partition for use by LVM

SYNOPSIS
pvcreate [-d|--debug] [-f[f]|--force [--force]] [-y|--yes] [-h|--help] [-v|--verbose] [-V|--version] PhysicalVolume [PhysicalVolume...]

DESCRIPTION
pvcreate initializes PhysicalVolume for later use by the Logical Volume Manager (LVM). Each PhysicalVolume can be a disk partition, whole disk, meta device, or loopback file. For DOS disk partitions, the partition id must be set to 0x8e using fdisk(8), cfdisk(8), or a equivalent. For whole disk devices only the partition table must be erased, which will effectively destroy all data on that disk. This can be done by zeroing the first sector with:

dd if=/dev/zero of=PhysicalVolume bs=512 count=1

Continue with vgcreate(8) to create a new volume group on PhysicalVolume, or vgextend(8) to add PhysicalVolume to an existing volume group.

OPTIONS
See lvm(8) for common options.

-f, --force
    Force the creation without any confirmation. You can not recreate (reinitialize) a physical volume belonging to an existing volume group. In an emergency you can override this behaviour with -ff.

-u, --uuid uuid
    Specify the uuid for the device. Without this option, pvcreate generates a random uuid. All of your physical volumes must have unique uuids. You need to use this option to restore a backup of LVM metadata onto a replacement device - see vgcfgrestore(8).

-y, --yes
    Answer yes to all questions.

Example
Initialize partition #4 on the third SCSI disk and the entire fifth SCSI disk for later use by LVM:

pvcreate /dev/sdc4 /dev/sde

SEE ALSO
lvm(8), vgcreate(8), vgextend(8), lvcreate(8), cfdisk(8), fdisk(8), losetup(8), mdadd(8), vgcfgrestore(8)