HOWTO+-+Efficient+Installation+of+a+KVM+VM+using+Virsh+and+Libvirt

In your local system type the following command:

code format="bash" virt-install --connect qemu+ssh://root@10.0.0.12/system \ --check-cpu --os-type=linux \ --name UbuntuTrusty --ram 2048 --vcpus=4\ --location http://ftp.uninett.no/ubuntu/dists/trusty/main/installer-amd64/ \ --disk pool=default,bus=virtio,format=qcow2,size=8 \ --network bridge=br0,model=virtio --nographics \ --extra-args='console=tty0 console=ttyS0,115200' code

Change "root" to your own user

Change "10.0.0.12" to the IP of the hypervisor

Change virtual machine details to match your needs.

The cool thing with this command, is that it will not create a VGA device, but a serial console instead. There is no VNC window to access the VM, and consequently, the installation can be completed from the command line. If you are also using virt-manager, the VM console of you VM will not be affected by this bug: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/582145, and you will also be able to copy/paste text, something you cannot achieve when the VNC console is in place.