Host CPU in Windows via KVM

mcit

Renowned Member
May 16, 2010
35
1
73
I have a peice of software that I need to run in my Windows KVM guests under proxmox 1.5. The software has a CPU check and fails due to the processor being QEMU Virtual CPU.

I am aware of the -cpu host parameter for KVM. Is it possible to use this in proxmox to solve my problem?

If so, where would I enter this?

Matthew
 
Thanks.

Is there any negative impact to the guest by doing this?

Is there anything to be aware of after this change?
 
Thanks.

Is there any negative impact to the guest by doing this?

Is there anything to be aware of after this change?

you will get issues if you live migrate to a host with another CPU, but this is anyways never a good idea.
 
When I do this on a Windows Server 2008 guest, the Container will no longer start. I cick Start, the status says Starting, then returns to Stopped. If I remove the line from the config, then the container starts normally.

Is there a way to find what is happening to stop the container starting, or is there another change I need to make for this to work properly?
 
proxmox3:/etc/qemu-server# qm start 104
/usr/bin/kvm: invalid option -- '-host'
start failed: command '/usr/bin/kvm -monitor unix:/var/run/qemu-server/104.mon,server,nowait -vnc unix:/var/run/qemu-server/104.vnc,password -pidfile /var/run/qemu-server/104.pid -daemonize -usbdevice tablet -name test-serv2008 -smp 1 -vga cirrus -tdf -localtime -rtc-td-hack -k en-us -drive file=/var/lib/vz/images/104/vm-104-disk-1.raw,if=ide,index=0 -drive file=/var/lib/vz/template/iso/WindowsServer2008R2OEM.iso,if=ide,index=2,media=cdrom -m 4096 -net tap,vlan=0,ifname=vmtab104i0,script=/var/lib/qemu-server/bridge-vlan -net nic,vlan=0,model=rtl8139,macaddr=26:0F:33:CB:9A:4C -id 104 -cpuunits 1000 cpu -host' failed with exit code 1
proxmox3:/etc/qemu-server#
 
proxmox3:/etc/qemu-server# qm start 104
Unable to find x86 CPU definition
start failed: command '/usr/bin/kvm -monitor unix:/var/run/qemu-server/104.mon,server,nowait -vnc unix:/var/run/qemu-server/104.vnc,password -pidfile /var/run/qemu-server/104.pid -daemonize -usbdevice tablet -name test-serv2008 -smp 1 -vga cirrus -tdf -localtime -rtc-td-hack -k en-us -drive file=/var/lib/vz/images/104/vm-104-disk-1.raw,if=ide,index=0 -drive file=/var/lib/vz/template/iso/WindowsServer2008R2OEM.iso,if=ide,index=2,media=cdrom -m 4096 -net tap,vlan=0,ifname=vmtab104i0,script=/var/lib/qemu-server/bridge-vlan -net nic,vlan=0,model=rtl8139,macaddr=26:0F:33:CB:9A:4C -id 104 -cpuunits 1000 -cpu host' failed with exit code 1
proxmox3:/etc/qemu-server#

*Sorry, had the - in the wrong place. Problem still exisits.
 
Hi,
i had an typo in my post (edited) - it must be "args: -cpu host" - if this is right it must apear in the kvm-process:
Code:
root      5624 32.5 12.4 760244 240260 ?       Sl   09:14   0:41 /usr/bin/kvm -monitor unix:/var/run/qemu-server/101.mon,server,nowait -vnc unix:/var/run/qemu-server/101.vnc,password -pidfile /var/run/qemu-server/101.pid -daemonize -usbdevice tablet -name lubuntu -smp sockets=1,cores=1 -nodefaults -boot menu=on,order=cad -vga cirrus -tdf -k de -drive file=/dev/cdrom,if=ide,index=2,media=cdrom -drive file=/var/lib/vz/images/101/vm-101-disk-1.qcow2,if=virtio,index=0,boot=on -m 600 -net tap,vlan=0,ifname=vmtab101i0,script=/var/lib/qemu-server/bridge-vlan -net nic,vlan=0,model=e1000,macaddr=9E:2F:04:0E:76:8E [B]-cpu host[/B]

Udo
 
proxmox3:/etc/qemu-server# pveversion -v
pve-manager: 1.5-5 (pve-manager/1.5/4627)
running kernel: 2.6.18-2-pve
proxmox-ve-2.6.18: 1.5-5
pve-kernel-2.6.18-2-pve: 2.6.18-5
qemu-server: 1.1-11
pve-firmware: 1.0-3
libpve-storage-perl: 1.0-8
vncterm: 0.9-2
vzctl: 3.0.23-1pve8
vzdump: 1.2-5
vzprocps: 2.0.11-1dso2
vzquota: 3.0.11-1
pve-qemu-kvm-2.6.18: 0.9.1-5
proxmox3:/etc/qemu-server#
 
apt-get update

apt-get upgrade


aptitude install proxmox-ve-2.6.32


pveversion -v
pve-manager: 1.6-5 (pve-manager/1.6/5261)
running kernel: 2.6.32-4-pve
proxmox-ve-2.6.32: 1.6-24
pve-kernel-2.6.32-4-pve: 2.6.32-24
pve-kernel-2.6.18-2-pve: 2.6.18-5
qemu-server: 1.1-22
pve-firmware: 1.0-9
libpve-storage-perl: 1.0-14
vncterm: 0.9-2
vzctl: 3.0.24-1pve4
vzdump: 1.2-8
vzprocps: 2.0.11-1dso2
vzquota: 3.0.11-1
pve-qemu-kvm: 0.12.5-2
ksm-control-daemon: 1.0-4


Problem now solved. Guest CPU is listed as host physical CPU. My software works again. Thanks so much for your help and for great software.