macOS-Simple-KVM icon indicating copy to clipboard operation
macOS-Simple-KVM copied to clipboard

Advice for users with 1366x768 screen resolution

Open SichangHe opened this issue 3 years ago • 4 comments

In one word: use 1360x768 resolution instead!

If you want to know the whole story of how I came to this conclusion, read the rest of this.

My Lenovo ThinkPad has a default resolution of 1366x768, and when I enter full-screen mode the displace scaled from 1280x720 and nothing was shown clear. So, I followed the instructions and changed the resolution to 1366x768 and the display was completely messed up. It simply showed diagonal spikes of pixels, I couldn't figure out anything my screen was showing.

At one point I felt hopeless and thought about deleting the whole thing and do it again. But I came up with the idea of controlling the VM using keyboard without seeing the actual screen. Here's what I did: I ran basic.sh and waited, then I pressed "right" 3 times to choose the correct starter disk (from my memory) and pressed enter. The screen flashed black and white and then white and grey and a diagonal apple loading bar. I waited for a while and pressed command+space, and typed in "terminal." I waited for a while and pressed enter. So, now we have the terminal at the front. Then, I typed in the command I used to mount EFI (later I realized that I could have pressed "up" to get it) and typed in my password and pressed enter. I command+spaced again and typed "finder." I actually have another mac so I tried to there several times. Press shift+command+G and type in "/Volumes/EFI/EFI/CLOVER" and press enter. Then press "right" twice and press enter. Now the config.plist file is open, I watched a video (Install macOS virtual machine on Ubuntu, https://www.youtube.com/watch?v=Fz07YhB2v60) where they opened the same file. I looked at the file in the video and imagined the position of my pointer. Using this method, I successfully changed the resolution back to 1280x720 and command+S. I moved the mouse to the top-left corner and pressed "down" 8 times and pressed enter. So, it shut down. I reopened it and changed the resolution in the BIOS as well (if you can't get to the BIOS pressing ESC, simply spam ESC when it starts. That's what I do).

But the scale effect still sucks and I wanted to change it for the better. I then searched through the available resolutions and found 1360x768. So, I actually went to change my host system's resolution to that, and then changed the VM's resolution to that. It worked like a charm.

So, above is my experience dealing with 1366x768 screen resolution. I hope it can be helpful to you.

My device: Lenovo ThinkPad E470c Processor: Intel® Core™ i5-6200U CPU @ 2.30GHz × 4 Operating system: Ubuntu 20.04.2 LTS Windowing system: X11 macOS version: Mojave 10.14.4

SichangHe avatar Jul 22 '21 00:07 SichangHe

I checked the docs for the project, and in the docs, under guide-screen-resolution.md, there's actually a line about this already:

Some odd/intermediate resolutions like 1366×768 may not work well. Try to stick to more common 16:9, 16:10, and 4:3 form factors.

https://github.com/foxlet/macOS-Simple-KVM/blob/master/docs/guide-screen-resolution.md

Prasantacharya avatar Jul 22 '21 15:07 Prasantacharya

I understand that it was stated that such resolution may not work well. But I believe that there should be a proper solution. 1360x768 did work for me as well. But scaling is still so annoying.

If anyone face the same issue of not being able to see anything after setting it to 1366x768 in the future, here's what I did. Simply exit the vm and mount the qcow2 image in the host.

modprobe nbd max_part=8
qemu-nbd --connect=/dev/nbd0 ./ESP.qcow2
fdisk /dev/nbd0 -l # just to see the partitions
mount /dev/nbd0p1 /mnt/somewhere

Now you can edit your configs under /mnt/somewhere. Once done, unmount and disconnect everything.

umount /mnt/somewhere
qemu-nbd --disconnect /dev/nbd0
rmmod nbd

Reference: https://gist.github.com/shamil/62935d9b456a6f9877b5

Naheel-Azawy avatar Sep 17 '21 13:09 Naheel-Azawy

1366x768 was buggy but when I tried 1360x768 it works thanks!

Clockiscool1234 avatar Jun 13 '23 12:06 Clockiscool1234

@Naheel-Azawy answer is great but if you are using OneClick-Mac-Os-KVM like me. You need to connect to OpenCore.qcow2 file in the second command. So it will be:

qemu-nbd --connect=/dev/nbd0 ./OpenCore.qcow2

MohamadTheWarrior avatar Jul 11 '23 12:07 MohamadTheWarrior