Imported Red Hat boots to black screen (virtual display issues)

Discussions about using Linux guests in VirtualBox.
Post Reply
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

Hello,

- VM Version 6.1.22 r144080 6.1.16 r140961 (Qt5.6.2)
- logs attached (3D acceleration OFF/ON)
- GA is installed in guest (6.1.16 r140961)
- host: Windows 10 64bit
- guest: Red Hat 64bit
- pc: HP Probook 6570b

I've been unable to get a Linux guest OS to boot properly after importing an existing VM. The VM was shared by a co-worker who has shared this VM before and others have been able to boot without issue. Initially, the guest OS would boot to a black screen and simply hang with the log showing the guest resolution resetting numerous times before hanging.
From "No login - 3D acc OFF - Centos 8 Dev environment-2021-05-17-10-48-20.log":
00:04:51.697552 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=800 h=600 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:04:51.853978 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000d480000 w=800 h=600 bpp=32 cbLine=0xC80 flags=0x1 origin=0,0
00:04:51.854770 GUI: UIMachineLogic: Guest-screen count changed
above repeated 5 more times over 1min
I tried changing numerous settings with no luck until enabling 3D acceleration. After enabling 3D acceleration, the guest OS will boot to the login screen, however, logging in with the correct password will hang the guest OS on a black screen. The log seems to show the virtual display turns off after logging in:
From "Login screen - 3D acc ON- Centos 8 Dev environment-2021-05-17-11-01-10.log":
00:01:58.443145 Audio Mixer: Setting recording source of sink '[Recording] Line In' to '[Line-In] DirectSound'
00:03:38.828171 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=800 h=600 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
Any ideas on what may be causing the issue?

There are two similar posts from what I could find referencing an observation about the guest display made by fth0, but the solutions mentioned in each aren't working for my situation:
Black screen stuck at startup of Xubuntu posted by apotheosis27
Black Screen on boot up posted by BattleFrog36

I have Hyper-V disabled in Windows settings. Aside from 3D acceleration, here is a list of options I have tried at this point:
- Setting base memory to 4096 MB / 10240 MB
- Setting processors to 1 CPU / 2 CPUs
- Setting Paravirtualization interface to Default / None / KVM
- Setting video memory to 12 MB / 128 MB / 256 MB
- Setting the Graphics controller to VMSVGA / VBoxVGA
- Resizing the guest window when hanging
- Uninstall/reinstall Virtualbox
- Installing other versions of Virtualbox (5.2 / 6.0 / 6.1.22 r144080)
- Re-downloading the imported environment
Attachments
VBox_RedHat_logs.zip
Logs for 3D acceleration ON/OFF
(62.92 KiB) Downloaded 18 times
Last edited by streamlinestabilizer on 18. May 2021, 15:21, edited 2 times in total.
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by fth0 »

Well, I would have suggested reducing the base memory, but you already tried that. The video drivers in the host OS and the guest OS would be candidates for changes, too.

You could "disable" the VirtualBox Guest Additions (GA) by booting the guest OS from a Linux Live ISO and renaming all vbox*.ko* files in the /lib/modules tree, so that the VirtualBox kernel modules won't be found on the next regular boot of the guest OS. If this helps, you could then install the matching GA version 6.1.22.
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

Would changing my version of Virtualbox to match the GA produce the same effect? I changed my version of Virtualbox to 6.1.16 r140961 to match the currently installed GA (which is 6.1.16 r140961, for the sake of clarity) and imported the VM environment again, however, this didn't change the result. My co-worker also uses this version and the VM runs for him.

I asked my co-worker for his log and he sent me his recorded log after logging in and reaching the desktop. Note: the log was taken while the VM was still running, so it doesn't include the shutdown logging. His log seems to show the same message at login as mine (GA compatibility report), and also includes repeated "guest-screen count changed" messages except after login. The difference in the repeated guest-screen count messages is that his log shows PerformGuestResize, SetVideoModeHint, and UIMediumEnumerator messages in between the guest-screen count changes (bolded below)
00:03:05.956187 VMMDev: Guest Additions capability report: (0x0 -> 0x1) seamless: yes, hostWindowMapping: no, graphics: no
00:03:05.956459 GUI: UISession::sltAdditionsChange: GA state really changed, notifying listeners
00:03:05.956501 GUI: UIMachineViewNormal::adjustGuestScreenSize: Adjust guest-screen size if necessary
00:03:05.956555 GUI: UISession::sltAdditionsChange: GA state change event came, notifying listeners
00:03:05.956578 GUI: UIMachineLogicNormal::sltCheckForRequestedVisualStateType: Requested-state=0, Machine-state=5
00:03:06.013387 Shared Clipboard: New Clipboard API enabled
00:03:06.170340 VMMDev: Guest Additions capability report: (0x1 -> 0x5) seamless: yes, hostWindowMapping: no, graphics: yes
00:03:06.170623 GUI: UISession::sltAdditionsChange: GA state really changed, notifying listeners
00:03:06.170684 GUI: UIMachineViewNormal::adjustGuestScreenSize: Adjust guest-screen size if necessary
00:03:06.170721 GUI: UISession::sltAdditionsChange: GA state change event came, notifying listeners
00:03:06.170737 GUI: UIMachineLogicNormal::sltCheckForRequestedVisualStateType: Requested-state=0, Machine-state=5
00:03:06.186432 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=800 h=600 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:03:06.187540 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000f79f000 w=1920 h=950 bpp=32 cbLine=0x1E00 flags=0x1 origin=0,0
00:03:06.199400 GUI: UIMachineLogic: Guest-screen count changed
00:03:10.254208 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=1920 h=950 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:03:10.257246 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000f79f000 w=1920 h=950 bpp=32 cbLine=0x1E00 flags=0x1 origin=0,0
00:03:10.262169 GUI: UIMachineLogic: Guest-screen count changed
00:03:15.650145 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=1920 h=950 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:03:15.686762 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000f220000 w=800 h=600 bpp=32 cbLine=0xC80 flags=0x1 origin=0,0
00:03:15.705763 GUI: UIMachineLogic: Guest-screen count changed
00:03:39.547991 GUI: UIMachineView::sltPerformGuestResize: Sending guest size-hint to screen 0 as 640x480 if necessary
00:03:39.571087 VMMDev: SetVideoModeHint: Got a video mode hint (640x480x32)@(0x0),(1;0) at 0
00:03:39.581069 GUI: UIMediumEnumerator: Medium-enumeration finished!

00:03:39.710138 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=800 h=600 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:03:39.711743 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000f220000 w=640 h=480 bpp=32 cbLine=0xA00 flags=0x1 origin=0,0
00:03:39.744416 GUI: UIMachineLogic: Guest-screen count changed
00:03:40.300516 GUI: UIMachineView::sltPerformGuestResize: Sending guest size-hint to screen 0 as 1920x950 if necessary
00:03:40.330255 VMMDev: SetVideoModeHint: Got a video mode hint (1920x950x32)@(0x0),(1;0) at 0
00:03:40.337283 GUI: UIMediumEnumerator: Medium-enumeration finished!

00:03:40.492890 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=0000000000000000 w=640 h=480 bpp=0 cbLine=0x0 flags=0x2 origin=0,0
00:03:40.504358 Display::i_handleDisplayResize: uScreenId=0 pvVRAM=000000000f79f000 w=1920 h=950 bpp=32 cbLine=0x1E00 flags=0x1 origin=0,0
00:03:40.514650 GUI: UIMachineLogic: Guest-screen count changed
Attachments
co-worker_VBox_log.zip
My co-worker's log after logging in and reaching the desktop
(20.46 KiB) Downloaded 12 times
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by fth0 »

I don't want to start a competition here ;), but your co-worker has a Dell Latitude E6540 with a display resolution of 1920x1080, and you have a HP ProBook 6570b with a display resolution of 1366x768. Your VM starts under a wrong assumption:
No login - 3D acc OFF - Centos 8 Dev environment-2021-05-17-10-48-20.log wrote:
00:00:08.113684 GUI: UIMachineViewNormal::resendSizeHint: Restoring guest size-hint for screen 0 to 1920x950
Restart your Windows host, open a Windows command prompt and execute the following command:

Code: Select all

"C:\Program Files\Oracle\VirtualBox\VBoxManage" setextradata "Centos 8 Dev environment" "GUI/LastGuestSizeHint" "1280,720"
Afterwards, start the VM. If the problem persists, post a new VBox.log file. Please also report back if the problem is solved.
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

If there was a competition, they'd have me beat :)
No luck, unfortunately. The command executed, and I can see the change reflected in the log, but the same issue occurs. Attached are logs for two sessions with 3D acceleration ON and OFF.
Attachments
VBox_RedHat_Logs_LastGuestSizeHint.zip
Logs following the LastGuestSizeHint change with 3D acceleration ON/OFF
(62.99 KiB) Downloaded 12 times
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by fth0 »

Please provide the output of the following commands:

Code: Select all

"C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata "Centos 8 Dev environment" "GUI/LastGuestSizeHint"
"C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata "Centos 8 Dev environment" "GUI/LastNormalWindowPosition"
"C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata global "GUI/MaxGuestResolution"
The value of MaxGuestResolution may be empty. If the value of LastNormalWindowPosition ("x,y,w,h") results in a window specification larger than your display resolution, use an appropriate setextradata command to set some sensible values (e.g. "100,100,800,450"). It doesn't matter if they match the LastGuestSizeHint value. You can also try if the following command helps:

Code: Select all

"C:\Program Files\Oracle\VirtualBox\VBoxManage" setextradata global "GUI/MaxGuestResolution" "1366,768"
Note that this constrains the window, so if you connect a larger display to your notebook in the future ... ;)
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

MaxGuestResolution was not set to a value, so I set it to 1366,768 (keeping in mind connecting to external monitors in the future). LastNormalWindowPosition and LastGuestSizeHint seem to be fine at their current values, although I'm not sure what max refers to in LastNormalWindowPosition. I ran the VM after setting MaxGuestResolution, but still no luck. Attached is a log of the recent run with 3D acceleration ON.

Code: Select all

> "C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata "Centos 8 Dev environment" "GUI/LastGuestSizeHint"
Value: 1280,720

> "C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata "Centos 8 Dev environment" "GUI/LastNormalWindowPosition"
Value: 0,29,640,480,max

> "C:\Program Files\Oracle\VirtualBox\VBoxManage" getextradata global "GUI/MaxGuestResolution"
Value: 1366,768
Attachments
VBox_RedHat_Log_MaxGuestResolution.zip
MaxGuestResolution set to 1366,768 and 3D acceleration ON
(32.66 KiB) Downloaded 14 times
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

I also tried setting LastNormalWindowPosition to the example value you posted, then tried setting MaxGuestResolution to auto, but same outcome for both cases.
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by fth0 »

Ok, the current strategy seems to be a dead end. The latest VBox.log file still shows that the display is turned off (as you initially discovered), but the rest of it now looks ok to me.

What happens if you change the screen resolution on the host before starting the VM?

What happens if you change the screen resolution via the View menu of the VirtualBox VM window (incl. switching from/to Full-screen Mode)?

What happens if you change the screen resolution inside the guest OS by switching between virtual terminals?

Another thing to try: Uninstall the VirtualBox Guest Additions (GA), update VirtualBox to the current version 6.1.22 and install the matching GA.
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

Trying the screen resolution changes didn't change the outcome and the logs don't seem to show much either. Changing screen resolution via the View menu produces sltPerformGuestResize and SetVideoModeHint messages, and changing screen resolution by switching to virtual terminals produces the repeated "Guest-screen count changed" and i_handleDisplayResize messages as seen when 3D acceleration is turned off. Logs are attached for the three cases tested.

I'm going to try updating the GA, although I ran into trouble earlier on my first attempt. I'll try again and update as I go.
Attachments
VBox_Centos_logs_ResolutionChanges.zip
Screen resolution change logs
(98.69 KiB) Downloaded 14 times
streamlinestabilizer
Posts: 7
Joined: 17. May 2021, 13:53

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by streamlinestabilizer »

Note: Virtualbox has been updated to 6.1.22

After uninstalling GA from the guest OS, running rcvboxadd setup, as well as rcvboxdrv setup, displays "command not found" in the terminal. Attempting to install GA 6.1.22 as per the instructions given in the manual produces the message:

Code: Select all

VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong
VirtualBox Guest Additions: Running kernel modules will not be replaced until the system is restarted
Inspecting vboxadd-setup.log shows the message:

Code: Select all

ERROR: Kernel configuration is invalid.
include/generated/autoconf.h or include/config/auto.conf are missing.
Run 'make oldconfig && make prepare' on kernel src to fix it.
Not quite sure what to make of this yet, so continuing to investigate.

Edit: I tried following the instructions at this link:
https://www.if-not-true-then-false.com/ ... -hat-rhel/

I wasn't able to complete steps 2 and 4 completely as yum tried downloading bintray-rabbitmq-rpm which would throw a 403 error. I tried connecting to my company's VPN but still no luck, however, I was able to complete the other steps in the guide. Afterwards, uninstalling then attempting to reinstall the GA produced a new message:

Code: Select all

VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong
ValueError: File context for /opt/VBox/GuestAdditions-6.1.22/other/mount.vboxsf already defined
Still no luck with reinstalling GA. The investigation continues.
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Imported Red Hat boots to black screen (virtual display issues)

Post by fth0 »

fth0 wrote:Another thing to try: Uninstall the VirtualBox Guest Additions (GA), update VirtualBox to the current version 6.1.22 and install the matching GA.
The idea was to follow my suggestions in the order given (at least inside this last one). This wouldn't have allowed you to test everything with the combination of VirtualBox 6.1.22 and the VirtualBox Guest Additions 6.1.16, where you cannot rely on the internal communications between those two softwares to work reliably. Don't get me wrong: Your problem may not be related to this, but it could be, at least partially. So the results don't prove anythingmuch.

Since you have problems installing the GA 6.1.22, perhaps the installation of the GA 6.1.16 was flawed somehow. I believe I've seen your quotes regarding autoconf.h in these forums in the past, perhaps you could google for "site:forums.virtualbox.org centos autoconf.h" ...
Post Reply