Now I'm trying to do this:
Initializing a single partition
If you have already a partition, before you can initialize it, the partition type must be changed. You can do it with fdisk, parted, cfdisk, etc. Cfdisk is really simple and is included in the most distributions.
The partition type must be set to
8E
This creates a LVM partition type.
You can now initialize the single partition executing
pvcreate /dev/PARTITION
This creates a volume group descriptor at the start of the partition.
I have on my Bubba Two following partitions:
Device Boot Start End Blocks Id System
/dev/sda1 1 1217 9775521 83 Linux
/dev/sda2 1218 60669 477548190 8e Linux LVM
/dev/sda3 60670 60801 1060290 82 Linux swap
So I did:
File descriptor 5 left open
File descriptor 7 left open
Can't initialize physical volume "/dev/sda2" of volume group "bubba" without -ff
When I run the same command but with -vvv option, I get:
File descriptor 5 left open
File descriptor 7 left open
Processing: pvcreate -vvv /dev/sda2
O_DIRECT will be used
global/locking_type not found in config: defaulting to 1
File-based locking selected.
global/locking_dir not found in config: defaulting to /var/lock/lvm
Locking /var/lock/lvm/P_orphans WB
Opened /dev/sda2 RW O_DIRECT
/dev/sda2: block size is 2048 bytes
/dev/sda2: lvm2 label detected
lvmcache: /dev/sda2: now in VG #orphans_lvm2 (#orphans_lvm2)
/dev/sda2: Found metadata at 5632 size 874 (in area at 4096 size 192512) for bubba (GOrWkw-ZuqG-shPr-7ntg-Z0Jl-UPx5-qNC6r5)
lvmcache: /dev/sda2: now in VG bubba with 1 mdas
lvmcache: /dev/sda2: setting bubba VGID to GOrWkwZuqGshPr7ntgZ0JlUPx5qNC6r5
lvmcache: /dev/sda2: VG bubba: Set creation host to bubbatwo.
Closed /dev/sda2
Using cached label for /dev/sda2
Using cached label for /dev/sda2
Opened /dev/ram0 RW O_DIRECT
/dev/ram0: block size is 1024 bytes
/dev/ram0: No label detected
Closed /dev/ram0
Opened /dev/ram1 RW O_DIRECT
/dev/ram1: block size is 4096 bytes
/dev/ram1: No label detected
Closed /dev/ram1
Opened /dev/sda1 RW O_DIRECT
/dev/sda1: block size is 4096 bytes
/dev/sda1: No label detected
Closed /dev/sda1
Opened /dev/ram2 RW O_DIRECT
/dev/ram2: block size is 4096 bytes
/dev/ram2: No label detected
Closed /dev/ram2
Using cached label for /dev/sda2
Opened /dev/ram3 RW O_DIRECT
/dev/ram3: block size is 4096 bytes
/dev/ram3: No label detected
Closed /dev/ram3
Opened /dev/sda3 RW O_DIRECT
/dev/sda3: block size is 2048 bytes
What can I do to solve this problem?