Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 11 VM black screen when expanded to Full Screen mode #3631

Open
LPFchan opened this issue Feb 16, 2022 · 14 comments
Open

Windows 11 VM black screen when expanded to Full Screen mode #3631

LPFchan opened this issue Feb 16, 2022 · 14 comments
Labels
macOS macOS issues qemu QEMU related

Comments

@LPFchan
Copy link

LPFchan commented Feb 16, 2022

Describe the issue

Screen.Recording.2022-02-16.at.12.05.49.480p.mov

I have Windows 11 21H2 VM with SPICE 0.164.3 running. Resolution changes as I resize the VM window without issues. However when I expand the window into Full Screen mode (Globe+F or 🟢 button) the screen goes black and will not adapt to my monitor's full resolution (3840x2160). When I exit Full Screen mode the VM comes back to normal.

Configuration

  • UTM Version:
  • OS Version: macOS 12.2.1
  • Intel or Apple Silicon?: Apple Silicon
  • spice-guest-tools-0.164.3
  • Windows 11 21H2 (22000.527)
  • 3840x2160 (60hz) 4K Monitor

Crash log
No crashes.

Debug log

Running:  -L /Applications/UTM.app/Contents/Resources/qemu -S -qmp tcp:127.0.0.1:4001,server,nowait -nodefaults -vga none -spice "unix=on,addr=/Users/yeowool/Library/Group Containers/WDNLXAD4W8.com.utmapp.UTM/DACB7AD3-3E50-4767-B633-669CC4319FA0.spice,disable-ticketing=on,image-compression=off,playback-compression=off,streaming-video=off,gl=on" -device virtio-ramfb-gl -device virtio-rng-pci -cpu host -smp cpus=4,sockets=1,cores=4,threads=1 -machine virt,highmem=off -accel hvf -accel tcg,tb-size=1536 -drive if=pflash,format=raw,unit=0,file=/Applications/UTM.app/Contents/Resources/qemu/edk2-aarch64-code.fd,readonly=on -drive if=pflash,format=raw,unit=1,file=/Users/yeowool/Library/Containers/com.utmapp.UTM/Data/Documents/Windows.utm/Images/efi_vars.fd -boot menu=on -m 6144 -device intel-hda -device hda-duplex -name Windows -device nec-usb-xhci,id=usb-bus -device usb-tablet,bus=usb-bus.0 -device usb-mouse,bus=usb-bus.0 -device usb-kbd,bus=usb-bus.0 -device ich9-usb-ehci1,id=usb-controller-0 -device ich9-usb-uhci1,masterbus=usb-controller-0.0,firstport=0,multifunction=on -device ich9-usb-uhci2,masterbus=usb-controller-0.0,firstport=2,multifunction=on -device ich9-usb-uhci3,masterbus=usb-controller-0.0,firstport=4,multifunction=on -chardev spicevmc,name=usbredir,id=usbredirchardev0 -device usb-redir,chardev=usbredirchardev0,id=usbredirdev0,bus=usb-controller-0.0 -chardev spicevmc,name=usbredir,id=usbredirchardev1 -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,bus=usb-controller-0.0 -chardev spicevmc,name=usbredir,id=usbredirchardev2 -device usb-redir,chardev=usbredirchardev2,id=usbredirdev2,bus=usb-controller-0.0 -device usb-storage,drive=cdrom0,removable=true,bootindex=0,bus=usb-bus.0 -drive if=none,media=cdrom,id=cdrom0 -device nvme,drive=drive0,serial=drive0,bootindex=1 -drive if=none,media=disk,id=drive0,file=/Users/yeowool/Library/Containers/com.utmapp.UTM/Data/Documents/Windows.utm/Images/data.qcow2,cache=writethrough -device virtio-net-pci,mac=9A:14:F7:21:BF:F5,netdev=net0 -netdev vmnet-macos,mode=shared,id=net0 -device virtio-serial -device virtserialport,chardev=vdagent,name=com.redhat.spice.0 -chardev spicevmc,id=vdagent,debug=0,name=vdagent -device virtserialport,chardev=charchannel1,id=channel1,name=org.spice-space.webdav.0 -chardev spiceport,name=org.spice-space.webdav.0,id=charchannel1 -uuid DACB7AD3-3E50-4767-B633-669CC4319FA0 -rtc base=localtime
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: Started vmnet interface with configuration:
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: MTU:              1500
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: Max packet size:  1514
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: MAC:              ea:f3:90:b6:f2:1f
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: DHCP IPv4 start:  192.168.64.1
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: DHCP IPv4 end:    192.168.64.254
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: IPv4 subnet mask: 255.255.255.0
qemu-aarch64-softmmu: -netdev vmnet-macos,mode=shared,id=net0: info: UUID:             8B8293F2-CC04-4221-871F-DF582A6B0680
qemu-aarch64-softmmu: warning: Spice: playback:0 (0x1508d3140): setsockopt failed, Operation not supported on socket
qemu-aarch64-softmmu: warning: Spice: record:0 (0x1508d31f0): setsockopt failed, Operation not supported on socket
gl_version 30 - es profile enabled
WARNING: running without ARB/KHR robustness in place may crash
qemu-aarch64-softmmu: Spice: red-qxl.c:807:spice_qxl_gl_scanout: condition `qxl_state->gl_draw_cookie == GL_DRAW_COOKIE_INVALID' failed

Upload VM

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>ConfigurationVersion</key>
	<integer>2</integer>
	<key>Debug</key>
	<dict/>
	<key>Display</key>
	<dict>
		<key>ConsoleFont</key>
		<string>Menlo</string>
		<key>ConsoleFontSize</key>
		<integer>12</integer>
		<key>ConsoleOnly</key>
		<false/>
		<key>ConsoleTheme</key>
		<string>Default</string>
		<key>DisplayCard</key>
		<string>virtio-ramfb-gl</string>
		<key>DisplayDownscaler</key>
		<string>linear</string>
		<key>DisplayRetina</key>
		<true/>
		<key>DisplayUpscaler</key>
		<string>nearest</string>
	</dict>
	<key>Drives</key>
	<array>
		<dict>
			<key>DriveName</key>
			<string>cdrom0</string>
			<key>ImageType</key>
			<string>cd</string>
			<key>InterfaceType</key>
			<string>usb</string>
			<key>Removable</key>
			<true/>
		</dict>
		<dict>
			<key>DriveName</key>
			<string>drive0</string>
			<key>ImagePath</key>
			<string>data.qcow2</string>
			<key>ImageType</key>
			<string>disk</string>
			<key>InterfaceType</key>
			<string>nvme</string>
		</dict>
		<dict>
			<key>DriveName</key>
			<string>drive04BA9D5F-DA13-49F2-9B56-63C105CF2AC4</string>
			<key>ImagePath</key>
			<string>efi_vars.fd</string>
			<key>ImageType</key>
			<string>none</string>
			<key>InterfaceType</key>
			<string></string>
		</dict>
	</array>
	<key>Info</key>
	<dict>
		<key>Icon</key>
		<string>windows 11 start button 4x.png</string>
		<key>IconCustom</key>
		<true/>
	</dict>
	<key>Input</key>
	<dict>
		<key>InputInvertScroll</key>
		<true/>
		<key>InputLegacy</key>
		<false/>
	</dict>
	<key>Networking</key>
	<dict>
		<key>NetworkCard</key>
		<string>virtio-net-pci</string>
		<key>NetworkCardMAC</key>
		<string>9A:14:F7:21:BF:F5</string>
		<key>NetworkMode</key>
		<string>shared</string>
	</dict>
	<key>Printing</key>
	<dict/>
	<key>Sharing</key>
	<dict>
		<key>ClipboardSharing</key>
		<true/>
		<key>DirectoryReadOnly</key>
		<false/>
		<key>DirectorySharing</key>
		<true/>
		<key>Usb3Support</key>
		<false/>
		<key>UsbRedirectMax</key>
		<integer>3</integer>
	</dict>
	<key>Sound</key>
	<dict>
		<key>SoundCard</key>
		<string>intel-hda</string>
		<key>SoundEnabled</key>
		<true/>
	</dict>
	<key>System</key>
	<dict>
		<key>Architecture</key>
		<string>aarch64</string>
		<key>BootDevice</key>
		<string></string>
		<key>BootUefi</key>
		<true/>
		<key>CPU</key>
		<string>default</string>
		<key>CPUCount</key>
		<integer>4</integer>
		<key>MachineProperties</key>
		<string>highmem=off</string>
		<key>Memory</key>
		<integer>6144</integer>
		<key>RngEnabled</key>
		<true/>
		<key>SystemUUID</key>
		<string>DACB7AD3-3E50-4767-B633-669CC4319FA0</string>
		<key>Target</key>
		<string>virt</string>
		<key>UseHypervisor</key>
		<true/>
	</dict>
</dict>
</plist>

@osy
Copy link
Contributor

osy commented Feb 20, 2022

Wondering if it's too large for QEMU's graphics driver to handle. Can you, for testing, change your Mac's screen resolution to something low like 1080p (no retina) and see if you still experience this?

@LPFchan
Copy link
Author

LPFchan commented Feb 20, 2022 via email

@conath
Copy link
Contributor

conath commented Mar 11, 2022

I can reproduce this as well. With "Retina Mode" enabled going into full screen on a 4K display causes the VM to show black screen. Without "Retina Mode" the VM resizes to 1080p as expected and works fine.
Screenshot of UTM app VM Display settings, with the Retina Mode toggle enabled and highlighte with a red circle.

@conath conath added qemu QEMU related macOS macOS issues labels Mar 11, 2022
@berkaytheunicorn
Copy link

This issue still exists in 4.1.5

@dadepretto
Copy link

I have the same issue with version 4.1.5, SPICE Tools installed, "Retina Mode" enabled, and an LG UltraFine 5K monitor.

3456 x 2234 is working fine
4480 x 2520 and 5120 x 2880 display a black window (although the mouse is displayed correctly)

@kFYatek
Copy link

kFYatek commented Mar 27, 2023

It looks that the limit for the Windows guest resolution is 7.5*1024*1024 pixels (so e.g. 3840x2048 or 4096x1920) and it is probably a limitation or bug in the virtio graphics driver for Windows.

I reported this in the virtio-gpu-wddm-dod project a couple of months ago, too, but no response there: utmapp/virtio-gpu-wddm-dod#4

@maddoglee
Copy link

The issue still exists in 4.4.4

@reecho-tsai
Copy link

still exists in 4.5.2😢

@ghost
Copy link

ghost commented Jun 7, 2024

Still exists on version 4.5.3.

@cyn8
Copy link

cyn8 commented Jul 8, 2024

+1 - issue still exists on 4.5.3

@emircanerkul
Copy link

Using 4.5.3 having same issue. But in my case i get black screen after win login with/without fullscreen mode enabled.

@maddoglee
Copy link

Still exists in v4.5.4 (100)
I found that it goes black when the horizontal pixels go above 3750... (i think). My resized display works at 3748x2097 and 3747x2097.. when I drag the window horizontally a touch more, the screen goes black.
Anyone got a workaround? I've just been using UTM in a large window which is ok, but it would be nice to be absolutely full screen.

@kFYatek
Copy link

kFYatek commented Sep 2, 2024

@maddoglee As I mentioned in utmapp/virtio-gpu-wddm-dod#4, the limit seems to be exactly 7864320 pixels (7.5*1024*1024) in area. You can go beyond 3750 horizontally if you use less vertical space, e.g. 3840x2048 is fine (and exactly at the limit).

This is especially annoying because the limit is below some common resolutions, e.g. standard "4K", i.e. 3840x2160, is 8294400 pixels (i.e., ~7.91*1024*1024).

@maddoglee
Copy link

Ahhh I missed your other post. Thanks for the explanation!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macOS macOS issues qemu QEMU related
Projects
None yet
Development

No branches or pull requests

10 participants