VirtualBox

Opened 2 years ago

Closed 21 months ago

Last modified 16 months ago

#20914 closed defect (fixed)

Issues related to Linux kernel 5.18

Reported by: Larry Finger Owned by:
Component: other Version: VirtualBox 6.1.32
Keywords: Cc:
Guest type: Windows Host type: Linux

Description

The problem applies to both VB 6.1.32 and 6.1.34.

My sources have been patched using [94502], [94501], and [94500] as well as the -ffreestanding changes to the link statements.

I have not been able to determine a pattern for the crashes. Sometimes they happen during boot, and other times after the VM is running. Sometimes it fails with a Bugcheck 3b as in the attached log file. Other time it is a Bugcheck 1e.

Attachments (7)

Windows 10 Clone-2022-04-24-20-55-56.log (158.0 KB ) - added by Larry Finger 2 years ago.
Log file for failing VM
vbox-linux-5.18.patch (9.0 KB ) - added by galitsyn 2 years ago.
VirtualBox-6.1.34 patch for Linux kernel 5.18 support (should be applied on top of https://download.virtualbox.org/virtualbox/6.1.34/VirtualBox-6.1.34.tar.bz2)
fc37v.tar.gz (2.6 KB ) - added by George R. Goffe 23 months ago.
tar.gz file with dmesg.txt and 2 screen shots of error
vbox-linux-5.19.patch (14.3 KB ) - added by galitsyn 23 months ago.
VirtualBox-6.1.34 patch for Linux kernels 5.18.x and 5.19-rc2 support (should be applied on top of https://download.virtualbox.org/virtualbox/6.1.34/VirtualBox-6.1.34.tar.bz2)
Logs1_2.zip (177.3 KB ) - added by Francesco Bucciantini 22 months ago.
VirtualBox VM 6.1.97 r150113 on Fedora 36
Logs3_4.zip (84.1 KB ) - added by Francesco Bucciantini 22 months ago.
VirtualBox VM 6.1.97 r150532 on Fedora 36
Guru_Meditation.zip (83.2 KB ) - added by Francesco Bucciantini 22 months ago.
VirtualBox VM 6.1.97 r150532 on Fedora 36 (Guru Meditation Windows 11 Guest)

Download all attachments as: .zip

Change History (33)

by Larry Finger, 2 years ago

Log file for failing VM

comment:1 by galitsyn, 2 years ago

Hi Larry Finger,

Kernel 5.18 is not yet supported.

comment:2 by Larry Finger, 2 years ago

Hi galitsyn,

When it is supported, I have more information that might help. I bisected the 5.18-rc1 kernel to find the change that caused this problem. Surprisingly, the bisection pointed to commit 6e8ec2552c7d ("random: use computational hash for entropy extraction"). I am very sure of the bisection as the kernel built from the commit that immediately precedes this one, cfb92440ee71 - a tag commit by Linus, runs correctly.

I do not think that the kernel changes are bad, just that they led to problems in the way the emulator access random numbers. If I learn more about this problem, I will report it here.

comment:3 by Larry Finger, 2 years ago

Vadim, as you are aware, this is a kernel regression.

For other people, see https://lore.kernel.org/lkml/Ym8uPcuQpq1xBS6d@zx2c4.com/T/#mea7aa731b5524a05ac3b3e8588c0c42235bb33d6 for more details.

This defect can be closed.

comment:4 by Hans-Peter Jansen, 2 years ago

Hi Larry,

nice to hear from you, but not so nice to find you in such a troublesome maze between the affected parties. You did the right thing and *way* more of what average maintainers usually do.

Jason claims, that this issue is a long standing security vulnerability of VB, when it comes to FPU/SIMD usage in hard IRQ contexts from within VB VMs. https://lore.kernel.org/lkml/YoTVIGiXUO2l8Czm@zx2c4.com/

While the result of his analysis is sound, the tone definitely isn't..

@Vadim: it would be nice, if this issue could be addressed rather soonish from the VB devs and this case better not be closed until than.

comment:5 by galitsyn, 2 years ago

Hi guys,

We have a fix for the issue. With the following test build VMs should not show the symptoms described above when host is running Linux 5.18.

If you would like to run kernel 5.18 inside guest, please consider to install the following Guest Additions separately:

Looking forward for your feedback. Thank you for reporting.

by galitsyn, 2 years ago

Attachment: vbox-linux-5.18.patch added

VirtualBox-6.1.34 patch for Linux kernel 5.18 support (should be applied on top of https://download.virtualbox.org/virtualbox/6.1.34/VirtualBox-6.1.34.tar.bz2)

comment:6 by Larry Finger, 23 months ago

Thanks for the effort. Larry

comment:7 by George R. Goffe, 23 months ago

Hi,

An attempt to run a VM on a 5.18 kernel on a Fedora Core 36 system (next kernel is a 5.19 with a bug that will not let the host boot). This configuration of host and guest has not changed in a long time.

Log and config file(s) attached as tar.gz file.

Regards,

George...

by George R. Goffe, 23 months ago

Attachment: fc37v.tar.gz added

tar.gz file with dmesg.txt and 2 screen shots of error

comment:8 by galitsyn, 23 months ago

Hi obiewan,

The issue you are observing does not look related to kernel 5.18. From the VM config and and VBox.log I can see that you are trying to start VM which has 4GB RAM assigned, however host only has 1.2 GB available.

00:00:02.363489 Host RAM: 7796MB (7.6GB) total, 1216MB available

This combination does not suppose to work. Try to make the host to get more free memory.

comment:9 by George R. Goffe, 23 months ago

Larry,

Thanks for responding.

The guest is also FC37 (Linux).

I guess I'm confused about how VB affects the host system. The host OS (FC37) is a demand paged system and so is the guest. As I understand it, the VM is not allowed to use over 4G. Does VB remove 4G from availability to any/all other processes? My understanding is that it does not.

In the demand paged systems, the free space changes from moment to moment.

What am I missing?

Best regards,

George...

comment:11 by Alexander G. M. Smith, 23 months ago

I don't know if it is relevant, but as mentioned in the forum (https://forums.virtualbox.org/viewtopic.php?f=7&t=106071), kernel 5.17.12 works on some CPUs and fails on others.

  • AMD X2 Athlon - works (circa 2008)
  • Intel i5-750 - fails (circa 2009)
  • Intel i7-4820K - fails (circa 2014)
  • Intel i5-10500H - works (circa 2020)

comment:12 by galitsyn, 23 months ago

Summary: Windows 10 VM crashes with Linux 5.18 kernelIssues related to Linux 5.18 kernel

I renamed the ticket in generic way. Hopefully new reports will end up here.

comment:13 by galitsyn, 23 months ago

Summary: Issues related to Linux 5.18 kernelIssues related to Linux kernel 5.18

comment:14 by fth0, 23 months ago

FWIW, I've collected backports of the random patches here (pun intended ;)):

Linux kernels 5.17.12+ (Fedora 35, 36), 5.15.44+ (Arch Linux 5.15.45-1-lts), 5.10.119+ (Debian Bullseye 5.10.0-15)

Last edited 23 months ago by fth0 (previous) (diff)

comment:15 by galitsyn, 23 months ago

Hi guys,

There is an updated version of the patch. It covers wider range of kernels and also includes initial support for 5.19 (up to rc2 for now) kernel. I am also posting a link to corresponding test build and Additions iso. Please note:

  • vbox-linux-5.19.patch provides only changes which are relevant to this ticket; if you build VBox from sources for a specific distribution, you will also need to apply this patch https://www.virtualbox.org/ticket/20904#comment:23.
  • Additions need to be installed separately from provided iso.

https://www.virtualbox.org/download/testcase/VirtualBox-6.1.35-151864-Linux_amd64.run https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151864.iso

r151864 and newer from Latest 6.1.x test builds on https://www.virtualbox.org/wiki/Testbuilds should have the fix.

Last edited 23 months ago by galitsyn (previous) (diff)

by galitsyn, 23 months ago

Attachment: vbox-linux-5.19.patch added

VirtualBox-6.1.34 patch for Linux kernels 5.18.x and 5.19-rc2 support (should be applied on top of https://download.virtualbox.org/virtualbox/6.1.34/VirtualBox-6.1.34.tar.bz2)

comment:16 by Francesco Bucciantini, 22 months ago

Hi, I noticed that you're working around the issue in 6.1.35, however the same should be done for VirtualBox 6.1.97 r150532 'cause it's also affecting 6.1.97 as you can see from here: https://forums.virtualbox.org/viewtopic.php?f=7&t=106194 Development Snapshots are supposed to be the latest versions available, so it would make sense to have 'em not fall behind 6.1.35 on this issue.

by Francesco Bucciantini, 22 months ago

Attachment: Logs1_2.zip added

VirtualBox VM 6.1.97 r150113 on Fedora 36

by Francesco Bucciantini, 22 months ago

Attachment: Logs3_4.zip added

VirtualBox VM 6.1.97 r150532 on Fedora 36

by Francesco Bucciantini, 22 months ago

Attachment: Guru_Meditation.zip added

VirtualBox VM 6.1.97 r150532 on Fedora 36 (Guru Meditation Windows 11 Guest)

comment:17 by sercallegar, 22 months ago

I have an issue that, in behavior, corresponds to the current description and that is extensively described in https://forum.manjaro.org/t/virtualbox-error-in-the-last-update/113744

The weird thing is that kernels in the 5.18 series appear to be the only ones *unaffected*, while all the previous kernels started being affected with the latest point releases.

With this premise, it realistic that what I am experiencing is indeed this bug and not a different one?

comment:18 by galitsyn, 22 months ago

Hi sercallegar,

I would suggest to try the last test build posted in this ticket. If the issue still persist, we can look at it closer. Initial patch was covering only kernels 5.18+. However, later we extended it to wider range of kernels.

comment:19 by k1kwp, 22 months ago

kernel-5.18.6-200.fc36.x86_64 does not work as well. seems like same issues to me. also https://www.virtualbox.org/download/testcase/VirtualBox-6.1.35-151864-Linux_amd64.run did not work at all on my system. could not start any vms.

in reply to:  19 comment:20 by galitsyn, 22 months ago

Replying to k1kwp:

kernel-5.18.6-200.fc36.x86_64 does not work as well. seems like same issues to me. also https://www.virtualbox.org/download/testcase/VirtualBox-6.1.35-151864-Linux_amd64.run did not work at all on my system. could not start any vms.

What was the issue with the test build exactly?

comment:21 by sblk, 22 months ago

Just to say that it worked for me with VirtualBox-6.1.35-152011-Linux_amd64.run on Fedora 36 with kernel 5.18.9-200.fc36.x86_64.

HTH

comment:22 by Francesco Bucciantini, 22 months ago

@sblk yep but virtual box 6.1.97 still doesn't as the development snapshots are stuck on version r150532 (not compatible with kernel 5.18.x) while 6.1.35 is at r152011 which is compatible with kernel 5.18.x

Kernel 5.18.x came out on the 22nd of May 2022. A fix for virtual box 6.1.35 came out on the 24th of May 2022 and has been improved 'till its final version released on the 14th of June 2022.

Today is the 5th of July 2022 and we still don't have a working 6.1.97 build with the fix applied. The development snapshots are supposed to be the cutting edge of builds and yet they've fallen behind the test builds. Dunno why, but it is what it is. I just hope they're gonna update the development snapshots too 'cause right now I'm booting with kernel 5.17 and I won't update till there's gonna be a working 6.1.97 version.

Last edited 22 months ago by Francesco Bucciantini (previous) (diff)

comment:23 by Matthew Jurgens, 22 months ago

I have been seeing this problem on vbox 6.1.32 and 6.1.34 on a Fedora host kernel 5.17.12+ (Windows 10 guest). I have now downgraded to kernel 5.17.5

Apart from crashing I was also seeing clock issues where the Windows host would gain in the order of 400 seconds over a 12 hour period. This was with the correct version of guest additions installed.

The other thing I was also seeing was that I would get duplicated VRDE ports. I generally specify the VRDE port as 9000-9100 to let vbox manage the port but I was getting multiple VMs come up and all claim port 9000. Sometimes restarting the VM would change the port number to an unused port but not always.

At this point I have only been running a few hours on kernel 5.17.5 but the port and time issues appear to have gone away already

in reply to:  23 comment:24 by Matthew Jurgens, 22 months ago

Replying to Matthew Jurgens:

At this point I have only been running a few hours on kernel 5.17.5 but the port and time issues appear to have gone away already

3 days and still all the problems (crashing, time sync, VRDE port collision) are gone

comment:25 by galitsyn, 21 months ago

Resolution: fixed
Status: newclosed

Issues related to 5.18 kernel (FPU API usage violation) should be fixed in VirtualBox 6.1.36. Please refer to https://www.virtualbox.org/wiki/Downloads page.

Please note that some comments in this ticket are not related to the original problem. If you still observing them with VBox 6.1.36, please submit a separate ticket.

Thank you all for the feedback.

comment:26 by oladke, 16 months ago

In VirtualBox 6.1.22 Where can I enable a Host-Only Network? the preferences only say NAT.

Last edited 16 months ago by gombara (previous) (diff)
Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use