Creating the KVM Virtual Machine from the terminal


To Create a KVM guest VM from command line.

I have an existing ISO directory at:

And I am storing the KVM at:

The command that creates the virtual machine is this:

$ sudo virt-install --name server01debian10-server3 \
--os-type linux \
--os-variant Debian10 \
--ram 2048\
--disk /myzpool/kvm/debian10-server3.qcow2,device=disk,bus=virtio,size=10,format=qcow2 \
--graphics none \
--noautoconsole \
--hvm \
--cdrom /iso/debian-10.9.0-amd64-netinst.iso \
--boot cdrom,hd


virt-install --name=centos \
--memory=2048 --vcpus=1 \
--location=/myzpool/iso/debian-10.9.0-amd64-netinst.iso \
--disk /myzpool/kvm/debian10-server3.qcow2,device=disk,bus=virtio,size=8 \
--network bridge:br0 \
--os-type=linux  \
--nographics \
--extra-args='console=tty0 console=ttyS0,115200n8 serial'