Configure local storage Flashcards
Display disk partition table for disk /dev/vdb
parted /dev/vdb print
Write an MBR disk label to disk /dev/vdb
parted /dev/vdb mklabel msdos
Write a GPT disk label to disk /dev/vdb
parted /dev/vdb mklabel gpt
Create an MBR partition on disk /dev/vdb
parted /dev/vdb mkpart primary xfs 2048s 1000MB
udevadm settle
Create a GPT partition on disk /dev/vdb
parted /dev/vdb mkpart usersdata xfs 2048s 1000MB
udevadm settle
Delete a partition 1 on disk /dev/vdb
parted /dev/vdb rm 1
Create 3 physical volumes on /dev/vdb
pvcreate /dev/vdb1 /dev/vdb2 /dev/vdb3
Remove physical volumes /dev/vdb2 and /dev/vdb1
pvremove /dev/vdb2 /dev/vdb1
Display physical volume /dev/vdb1
pvdisplay /dev/vdb1
Display volume group vg01
vgdisplay vg01
Create volume group vg01 and assign physical volumes /dev/vdb2 and /dev/vdb1 to it
vgcreate vg01 /dev/vdb2 /dev/vdb1
Add physical volume /dev/vdb3 to volume group vg01
vgextend vg01 /dev/vdb3
Remove physical volume /dev/vdb3 from volume group vg01
pvmove /dev/vdb3
vgreduce vg01 /dev/vdb3
Volume group vg01 is no longer needed. Delete it.
vgremove vg01
Create a 700 MB logical volume called lv01 in volume group vg01
lvcreate -n lv01 -L 700M vg01