I'd like to host a linux VM on a laptop with a linux host running kvm and spice. I've found lots of info on the internet from 2011 & 2012, but not as much from more recently. I've also seen plenty of articles discussing Windows guests, remote servers, Centos OS/Fedora/Arch, but very little on the specific scenario I'm most interested in (single machine and Ubuntu family) -- and even then, most of what I've found has been written at a level a bit beyond my comprehension.
So I'm hoping I can get some help here.
Thus far I've managed to successfully set up a VM with virt-manager, with qxl, virtio, and spice options selected, and I've even managed to make a few edits to the dumpxml file and re-define the VM settings.
I can run the VM and connect to the internet with it, viewing the VM desktop in virt-manager's console window.
What do I now need to do to take full advantage of spice? (Or is there no real advantage to spice in this scenario in which the host and guest are on the same physical machine?)
The dumpxml is:
I've installed spice-vdagent on the guest (using Synaptic), in an attempt to follow instructions here:
http://www.linux-kvm.org/page/SPICE
which says to do
but I don't know what the current equivalent of chkconfig is, and I'm not quite sure how to log out of X and log back in and verify the agent is running (in Linux Mint 17 Mate).
I also don't know the steps for using SSH for the connection (or would that not even be appropriate, since the host and guest are on the same machine?).
So I'm hoping I can get some help here.
Thus far I've managed to successfully set up a VM with virt-manager, with qxl, virtio, and spice options selected, and I've even managed to make a few edits to the dumpxml file and re-define the VM settings.
I can run the VM and connect to the internet with it, viewing the VM desktop in virt-manager's console window.
What do I now need to do to take full advantage of spice? (Or is there no real advantage to spice in this scenario in which the host and guest are on the same physical machine?)
The dumpxml is:
Code:
<domain type='kvm'>
<name>AlphaOS</name>
<uuid>cfaafa3c-cc21-89bf-3f49-4685e9933672</uuid>
<memory unit='KiB'>1048576</memory>
<currentMemory unit='KiB'>1048576</currentMemory>
<vcpu placement='static'>1</vcpu>
<os>
<type arch='x86_64' machine='pc-i440fx-trusty'>hvm</type>
<boot dev='hd'/>
</os>
<features>
<acpi/>
<apic/>
<pae/>
</features>
<clock offset='utc'/>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<devices>
<emulator>/usr/bin/kvm-spice</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/AlphaOS.img'/>
<target dev='vda' bus='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
</disk>
<disk type='block' device='cdrom'>
<driver name='qemu' type='raw'/>
<target dev='hdc' bus='ide'/>
<readonly/>
<address type='drive' controller='0' bus='1' target='0' unit='0'/>
</disk>
<controller type='usb' index='0'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
</controller>
<controller type='pci' index='0' model='pci-root'/>
<controller type='ide' index='0'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
</controller>
<controller type='virtio-serial' index='0'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
</controller>
<interface type='network'>
<mac address='35:54:00:77:be:d2'/>
<source network='default'/>
<model type='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
</interface>
<serial type='pty'>
<target port='0'/>
</serial>
<console type='pty'>
<target type='serial' port='0'/>
</console>
<channel type='spicevmc'>
<target type='virtio' name='com.redhat.spice.0'/>
<address type='virtio-serial' controller='0' bus='0' port='2'/>
</channel>
<input type='mouse' bus='ps2'/>
<input type='keyboard' bus='ps2'/>
<graphics type='spice' autoport='yes'/>
<sound model='ac97'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
</sound>
<video>
<model type='qxl' ram='65536' vram='65536' heads='1'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</video>
<memballoon model='virtio'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0'/>
</memballoon>
</devices>
</domain>
http://www.linux-kvm.org/page/SPICE
which says to do
Code:
# yum install spice-vdagent
# chkconfig --add spice-vdagent
# service start spice-vdagentd
(. . . log out of X, and log back in, verify agent is running . . . And you're done)
I also don't know the steps for using SSH for the connection (or would that not even be appropriate, since the host and guest are on the same machine?).