It appears that I am able to successfully do a pvcreate on top of a raw block device, without ever taking the step of creating a partition table. I am then able to create a volume group, logical volume, and finally a filesystem, mount it, and test via dd.
It appears to work, but I need a sanity check. Is this a bad idea?
How do I create a GPT or MBR partition table on top of a raw block device?
How do I use parted to show what sort of partition table is in use? I have tried doing:
parted, select /dev/sdb, print and I get:
Error: /dev/sdb: unrecognised disk label
Yet the drive is currently in use and I can read and write to it. Is that the expected output when doing LVM on top of a raw block device without a partition table? Any thoughts?
Thanks!
Best Answer
Even if LVM itself doesn't care about having a real partition, one reason to create it anyway is to inform partitioning programs that there's "something there." A nightmare scenario is a new sysadmin diagnosing a boot problem on a server, firing up a partitioning program, seeing unpartitioned disks, and concluding that the drive is corrupt.
I see no downside to creating an LVM partition. Do you?