Guru Meditation error

Discussions related to using VirtualBox on Windows hosts.

Guru Meditation error

Postby sakeebhoss » 26. Sep 2021, 02:16

Running into this crash consistently, happened 3 times in a row. Not really sure how to proceed so I would really appreciate some advice!

Version of VirtualBox: 6.1.26 r145957 (Qt5.6.2)
Using Guest Additions: No
Host OS: Windows Server 2019, 64-bit, 1.5 TB RAM
Guest OS: Red Hat Enterprise Linux 8.4, 64-bit, 300 GB RAM

Description of what I was doing: I was running a web application server on the VM while running a Postman-like tool on the host machine, simply sending requests to the server in the VM.
Attachments
VBox.zip
(166.1 KiB) Downloaded 6 times
VBoxHardening.zip
(23.4 KiB) Downloaded 5 times
sakeebhoss
 
Posts: 1
Joined: 26. Sep 2021, 01:30

Re: Guru Meditation error

Postby scottgus1 » 26. Sep 2021, 03:23

Have to say, looks like an awesome server! 96 cores 'hyperthtreaded' (dual AMDs), 1.5TB RAM! Must have hit the war chest a little bit! :D

Despite having "only" :shock: 300 GB out of that 1.5TB RAM set aside for the RedHat VM, the guru meditated over insufficient RAM:
01:34:44.800442 PGMR3PhysAllocateLargePage: allocating large pages takes too long (last attempt 103 ms; nr of timeouts 11); DISABLE
02:27:05.319955
02:27:05.319957 !!R0-Assertion Failed!!
02:27:05.319963 Expression: cRefs == PGMPOOL_TD_CREFS_PHYSEXT
02:27:05.319964 Location : F:\tinderbox\win-6.1\src\VBox\VMM\VMMAll\PGMAllPool.cpp(4132) void __cdecl pgmPoolTrackPhysExtDerefGCPhys(struct PGMPOOL *,struct PGMPOOLPAGE *,union PGMPAGE *,unsigned short)
02:27:05.320021 cRefs=0 pPhysPage=A-:RAM:01bd88200000:001d000:-0000 pPage=ffffa76d9f21d9c0:{.idx=495}
02:27:05.320038 Changing the VM state from 'RUNNING' to 'GURU_MEDITATION'
02:27:05.320069 Console: Machine state changed to 'GuruMeditation'
02:27:05.320399 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
02:27:05.320401 !!
02:27:05.320402 !! VCPU0: Guru Meditation -2701 (VERR_VMM_RING0_ASSERTION)


I surmise this is because Virtualbox has "lazy" RAM allocation for its VMs: it pulls RAM from the host as the VM calls for it. However, if the VM eventually calls for all of it, RAM has to be available for the VM. Since Virtualbox does not by default allocate all of the RAM at once, it is possible for other processes or VMs to take up RAM and leave the VM asking for RAM it expects but that the host cannot now allocate.

Adding to this possibility is that Linux does not touch all RAM at boot, so Linux VMs allow lazy allocation to work. Windows VMs touch all RAM at boot so all VM RAM gets allocated at boot or a RAM error occurs at boot, before you can get into usage of the VM.

A command can be used to turn off lazy allocation for a VM:

cd "C:\Program Files\Oracle\Virtualbox"
VBoxManage setextradata "VM name" "VBoxInternal/RamPreAlloc" 1


Run it for each VM that you want to avoid lazy allocation.
scottgus1
Site Moderator
 
Posts: 13799
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Guru Meditation error

Postby fth0 » 26. Sep 2021, 10:47

The following advice may seem counterintuitive at first, but please try if disabling large pages helps, by executing the following command while the VM is not running:

Code: Select all   Expand viewCollapse view
cd C:\Program Files\Oracle\VirtualBox
VBoxManage modifyvm "tm1" --largepages off

PS: If following scottgus1's suggestion to disable the lazy RAM allocation made the crash appear faster, you can combine that with my suggestion above for a faster initial test.
fth0
Volunteer
 
Posts: 2625
Joined: 14. Feb 2019, 03:06
Location: Germany
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...


Return to VirtualBox on Windows Hosts

Who is online

Users browsing this forum: Google [Bot], ShimaOnari and 37 guests