Verifying QEMU
Prerequisites
Download the openEuler image before running the virt-install command to create a VM.
Procedure
- Create a VM drive file in QCOW2 format.
qemu-img create -f qcow2 /home/test1 10G
- Create a VM.
virt-install --name test1 --ram 2048 --vcpu=4 --cdrom=/dev/cdrom --disk path=/home/test1,size=10
Parameter description:
- name test1: VM name
- ram 2048: size of the virtual memory
- vcpus=4: number of virtual CPUs
- cdrom=/dev/cdrom: path to which the OS image is mounted, for example, /home/iso/openEuler-20.03-LTS-SP1-everything-aarch64-dvd.iso
- path=/home/test1: VM file.
- size=10: file size, in GB.
After verifying the QEMU component, run the virsh undefine test1 command to delete the VM used for verification.
Parent topic: QEMU 5.0.0 Installation Guide (openEuler 20.03)