Which command initialises /dev/sdb1 as a physical volume for LVM?

Prepare for the Red Hat Certified Systems Admin Exam EX200. Enhance your skills with interactive quizzes, flashcards, and detailed explanations. Ace your certification exam today!

Multiple Choice

Which command initialises /dev/sdb1 as a physical volume for LVM?

Explanation:
Initialising a device as a physical volume is the first step in setting up LVM. pvcreate writes the LVM metadata to a partition or disk, marking it as a physical volume that can participate in a volume group. Without this metadata, LVM won’t recognize the device as part of any VG, so you can’t create logical volumes on it. Once the device is a PV, you can then build a volume group with vgcreate, and finally create logical volumes with lvcreate. pvdisplay would only show existing PV metadata; it won’t initialise the device. So the command that correctly initialises /dev/sdb1 as a physical volume is pvcreate /dev/sdb1.

Initialising a device as a physical volume is the first step in setting up LVM. pvcreate writes the LVM metadata to a partition or disk, marking it as a physical volume that can participate in a volume group. Without this metadata, LVM won’t recognize the device as part of any VG, so you can’t create logical volumes on it.

Once the device is a PV, you can then build a volume group with vgcreate, and finally create logical volumes with lvcreate. pvdisplay would only show existing PV metadata; it won’t initialise the device.

So the command that correctly initialises /dev/sdb1 as a physical volume is pvcreate /dev/sdb1.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy