Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 7 Aug 2016 13:10:35 -0700 (PDT)
From:      Don Lewis <truckman@FreeBSD.org>
To:        freebsd-emulation@FreeBSD.org
Subject:   Re: kernel panic caused by virtualbox
Message-ID:  <201608072010.u77KAZFQ026110@gw.catspoiler.org>

next in thread | raw e-mail | index | archive | help
On  5 Aug, Don Lewis wrote:
> On  4 Aug, Don Lewis wrote:
>> I just got a kernel panic when I started up a CentOS 7 VM in virtualbox.
>> The host is:
>> 	FreeBSD 12.0-CURRENT #17 r302500 GENERIC amd64
>> The virtualbox version is:
>> 	virtualbox-ose-5.0.26
>> 	virtualbox-ose-kmod-5.0.26_1
>> 
>> The panic message is:
>> 
>> panic: Unregistered use of FPU in kernel
>> cpuid = 1
>> KDB: stack backtrace:
>> db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe085a55d030
>> vpanic() at vpanic+0x182/frame 0xfffffe085a55d0b0
>> kassert_panic() at kassert_panic+0x126/frame 0xfffffe085a55d120
>> trap() at trap+0x7ae/frame 0xfffffe085a55d330
>> calltrap() at calltrap+0x8/frame 0xfffffe085a55d330
>> --- trap 0x16, rip = 0xffffffff827dd3a9, rsp = 0xfffffe085a55d408, rbp = 0xfffffe085a55d430 ---
>> g_pLogger() at 0xffffffff827dd3a9/frame 0xfffffe085a55d430
>> g_pLogger() at 0xffffffff8274e5c7/frame 0x3
>> KDB: enter: panic
>> 
>> Since g_pLogger is a symbol in vboxdrv.ko, it looks like virtualbox is
>> the trigger.
>> 
>> There are no symbols for the virtualbox kmods, possibly because I
>> installed them as an upgrade using packages (built with the same source
>> tree version) instead of by using PORTS_MODULES in make.conf, so ports
>> kgdb didn't have anything useful to say about what happened before the
>> trap.
>> 
>> This panic is very repeatable.  I just got another one when starting the
>> same VM., but this time the two calls before the trap were
>> null_bug_bypass().
>> 
>> I don't see this with a Windows 7 VM.
> 
> I upgraded to a more recent version of 12.0-CURRENT last night, r303762,
> and rebuilt the kmod, but the host still panics.
> 
> I also get a panic with a Ubuntu 12.  The panic happens very early
> during the guest kernel boot when it prints a message about doing TSC
> calibration.
> 
> A FreeBSD guest does not panic the host.
> 
> I did not have this problem with Virtualbox 4.x.

A Windows guest also works fine.

I found that if I set the number of processors to 1, then I can boot
both of my Linux guest VMs.  I can reproduce the panic if I create a new
VM, set the number of processors to 5, and attempt to boot the
CentOS 7 installation CD.  In earlier testing, I set the number of
processors to 2, which was what I'm using for Windows, but my existing
CentOS VM still crashed.

Something else that might be important is the host CPU is an AMD
FX-8320E.  I don't have any Intel hardware that is nearly recent enough
to test this.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608072010.u77KAZFQ026110>