1, with Poweroff will be virtual machine.
2. Add 4 1G HDD to the Linux virtual machine. Lsblk can be viewed after booting. Fdisk-l can also.
3, open the Linux virtual machine, 4 1G of hard disk to do LVM logical volume management.
The steps are as follows:
A: Use all remaining space by dividing the SDB, SDC, SDD, and SDE into a primary partition.
View all hard disk block devices with LSBLK
B: Create a SDB1, SDC1, SDD1 partition as a volume group named Vg0.
C: Add Sde1 to the VG0 volume group, and then remove SDC1 from the VG0 volume group.
D: Create a logical volume with a capacity of 2G with a name of Lv_data in the VG0 volume group.
E: Extend the lv_data logical volume capacity to 2.5G.
F: Format the Lv_data and mount it manually to the/data directory.
G: Copy the/etc/host* file to the/data directory.
LVM Implementation Reference:
Lsblk
FDISK/DEV/SDB-->n--->p--->1---> return 2 under-->W//Create Primary partition
PVCREATE/DEV/SD[B-E]1//Create physical volume
PVs
Vgcreate vg0/dev/sd[b-d]1//Create Volume group
Vgextend vg0/dev/sde1//Extended VG0 Volume Group capacity
Vgreduce VG0/DEV/SDC1//delete a piece of partition from VG0, note: Vgremove is deleting the entire volume group
VGs
Lvcreate-l 2g-n lv_data vg0//Create Logical Volume-l specify Logical Volume Size-n Specify Logical volume name
Lvextend-l +0.5g/dev/vg0/lv_data//expansion
Mkfs.ext4/dev/vg0/lv_data//Format ha, that is, create file system
Mkdir/data
Mount/dev/vg0/lv_data/data//Manually mount to the specified directory
Cp-v/etc/host*/data//Copy data
Ls/data
This article from "DANIEPDD" blog, declined reprint!
Creating a logical volume in a Linux system in VMware