Note: It is recommended to add a virtual disk file to increase disk space by adding LVM logical volumes to the virtual machine. The creation process is as follows.
1. DD Creates a disk file
# dd If=/dev/zero bs=1024m count=4 >/data/test_01new.img
2. Turn off the test01 virtual machine
3. Modify the new virtual machine configuration file
# vi/etc/xen/test01
# Modification Instructions:
# (1) name
# (2) UUID changes the last few data
# (3) change to the actual path, note the disk number when you add a new disk.
# (4) Vif modify the MAC address of the NIC to change the last few data
See more highlights of this column: http://www.bianceng.cnhttp://www.bianceng.cn/Servers/virtualization/
Name = "Test01"
UUID = "Cc49eaea-fb0c-5239-c055-bdafcf209cab"
MAXMEM = 512
Memory = 512
Vcpus = 1
bootloader = "/usr/bin/pygrub"
On_poweroff = "Destroy"
On_reboot = "Restart"
On_crash = "Restart"
disk = ["Tap:aio:/data/test01.img,xvda,w", "Tap:aio:/data/test_01new.img,xvdb,w"]
Vif = ["Mac=00:16:3e:44:ee:07,bridge=xenbr1,script=vif-bridge"]
Note: If you use LVM logical volume, use the following parameters, using logical volumes in the Xen virtualization environment in a large number of uses, so that the maximum utilization of disk performance.
disk = ["Tap:aio:/data/test01.img,xvda,w", "Phy:/dev/lvmdata/var01,xvdb,w"]
4. Start the virtual machine