[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[linux-lvm] pvcreate not overwriting partition table

from what i can remember, pvcreate should be unable (without "force") to
create a physical volume on an entire disk if there was a partition
table on that disk. something must have changed because now it seems it
doesnt even check, and worse, it doesnt remove the partition table. what
happens is you end up with a pv on the entire disk as well as a
partition table on the disk.

here are some details:
[root linuxclone root]# lvm version
  LVM version:     2.00.15 (2004-04-19)
  Library version: 1.00.14-ioctl (2004-04-06)
  Driver version:  4.1.0
distribution: fedora core 2

pvscan shows 2 pv's, one on the entire disk the other on a partition on
the same disk. how can that happen?
[root linuxclone root]# pvscan
  PV /dev/hda    VG vault_vg   lvm2 [37.27 GB / 36.27 GB free]
  PV /dev/hda2                 lvm2 [37.01 GB]
  Total: 2 [74.28 GB] / in use: 1 [37.27 GB] / in no VG: 1 [37.01 GB]

[root linuxclone root]# sfdisk -l /dev/hda
Disk /dev/hda: 77545 cylinders, 16 heads, 63 sectors/track
Warning: The partition table looks like it was made
  for C/H/S=*/255/63 (instead of 77545/16/63).
For this listing I'll assume that geometry.
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from
   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/hda1   *      0+     32      33-    265041   82  Linux swap
/dev/hda2         33    4864    4832   38813040   8e  Linux LVM
/dev/hda3          0       -       0          0    0  Empty
/dev/hda4          0       -       0          0    0  Empty

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]