From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?UTF-8?B?QW5kcsOpIFdlaWRlbWFubg==?= Subject: Re: Windows7 crashes inside the VM when starting a certain program Date: Sat, 30 Jul 2011 14:29:11 +0200 Message-ID: <4E33F917.4000305@web.de> References: <4E154370.5090101@web.de> <4E2E50A0.3040706@web.de> <20110726100809.GK4404@redhat.com> <4E2E9DA8.7040503@web.de> <20110727085627.GO4404@redhat.com> <4E325F43.4050701@web.de> <20110729113713.GA15968@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: kvm@vger.kernel.org To: Gleb Natapov Return-path: Received: from fmmailgate03.web.de ([217.72.192.234]:46513 "EHLO fmmailgate03.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751488Ab1G3M3W (ORCPT ); Sat, 30 Jul 2011 08:29:22 -0400 In-Reply-To: <20110729113713.GA15968@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 29.07.2011 13:37, Gleb Natapov wrote: > On Fri, Jul 29, 2011 at 09:20:35AM +0200, Andr=C3=A9 Weidemann wrote: >> On 27.07.2011 10:56, Gleb Natapov wrote: >>> On Tue, Jul 26, 2011 at 12:57:44PM +0200, Andr=C3=A9 Weidemann wrot= e: >>>> Hi, >>>> >>>> On 26.07.2011 12:08, Gleb Natapov wrote: >>>>> On Tue, Jul 26, 2011 at 07:29:04AM +0200, Andr=C3=A9 Weidemann wr= ote: >>>>>> On 07.07.2011 07:26, Andr=C3=A9 Weidemann wrote: >>>>>>> Hi, >>>>>>> I am running Windows7 x64 in a VM which crashes after starting = a certain >>>>>>> game. Actually there are two games both from the same company, = that make >>>>>>> the VM crash after starting them. >>>>>>> Windows crashes right after starting the game. With the 1st gam= e the >>>>>>> screen goes black as usual and the cursor keeps spinning for 3-= 5 seconds >>>>>>> until Windows crashes. With the second game I get to 3D the log= in >>>>>>> screen. The game then crashes after logging in. >>>>>>> Windows displays this error message on the first crash: >>>>>>> http://pastebin.com/kMzk9Jif >>>>>>> Windows then finishes writing the crash dump and restarts. >>>>>>> I can reproduce Windows crashing every time I start the game wh= ile the >>>>>>> VM keeps running without any problems. >>>>>>> When Windows reboots after the first crash and the game is star= ted >>>>>>> again, the message on the following blue screen changes slightl= y and >>>>>>> stays the same(except for the addresses) for every following cr= ash: >>>>>>> http://pastebin.com/jVtBc4ZH >>>>>>> >>>>>>> I first thought that this might be related to a certain feature= in 3D >>>>>>> acceleration being used, but Futuremark 3DMark Vantage or 3DMar= k 11 run >>>>>>> without any problems. They run a bit choppy on some occasions, = but do >>>>>>> that without crashing Windows7 or the VM. >>>>>>> >>>>>>> How can I proceed to investigate what is going wrong? >>>>>> >>>>>> I did some testing and found out that Windows7 does not crash >>>>>> anymore when changing "-cpu host" to "-cpu Nehalem". After doing= so, >>>>> What is your host cpu (cat /proc/cpuinfo)? >>>> >>>> The server is currently running on 2 out of 8 cores with kernel bo= ot >>>> parameter "maxcpus=3D2". >>>> >>>> flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr >>>> pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm >>>> pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts rep_go= od >>>> xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est >>>> tm2 ssse3 cx16 xtpr pdcm sse4_1 sse4_2 popcnt lahf_lm ida tpr_shad= ow >>>> vnmi flexpriority ept vpid >>> Flags that are present on -cpu host but not -cpu Nehalem (excluding= vmx >>> related flags): >>> >>> vme dts acpi ss ht tm pbe rdtscp constant_tsc arch_perfmon pebs bts= rep_good >>> xtopology nonstop_tsc aperfmperf dtes64 monitor ds_cpl est tm2 xtpr= pdcm ida >>> >>> Some of them may be synthetic and some of them may be filtered by K= VM. >>> >>> Can you try to run "-cpu host,-vme,-dts..." (specifying all of thos= e >>> flags with -). Drop those that qemu does not recognize. See if resu= lt >>> will be the same as with -cpu Nehalem. If yes, then try to find out= with >>> flag make the difference. >> >> I started the VM with all flags that differ between the two CPUs. >> After removing the ones qemu-kvm did not recognize, I started the VM >> again with the following line: >> -cpu host,-vme,-acpi,-ss,-ht,-tm,-pbe,-rdtscp,-dtes64,-monitor,-ds_c= pl,-est,-tm2,-xtpr,-pdcm >> \ >> >> Running the program under Windows7 inside the VM, caused Windows to >> crash again with a BSoD. >> The disassembly of the address fffff8000288320c shows the following: >> http://pastebin.com/7yzTYJSG >> > Looks like it tries to read MSR_LASTBRANCH_TOS MSR which kvm does not > support. Do you see something interesting in dmesg? I wonder how > availability of the MSR should be checked. You are right about the MSR. The log file from the time of occurrence=20 shows the following: Jul 4 18:55:12 server kernel: [ 1528.618647] kvm: 3123: cpu1=20 kvm_set_msr_common: MSR_IA32_DEBUGCTLMSR 0x1, nop Jul 4 18:55:12 server kernel: [ 1528.619444] kvm: 3123: cpu1 unhandled= =20 rdmsr: 0x1c9 Andr=C3=A9