Distorted or Skewed Screen During Linux Install from Grub

I came across a strange problem when recently installing Linux to an older Laptop model that I hadn’t seen in many, many years. While the installation media would boot up fine into the actual GRUB2 menu, any decision to install the Linux distribution (text or graphical) after that would result in the screen skewing/distorting itself in a way so that I could tell there was text or a window up on the screen, but I couldn’t really see much more than that, with the resolution appearing to be out of control and everything shifted at a severe slant.

I was actual able to continue in the installation, hitting return and using the arrow keys, etc. However, it was incredibly frustrating as I couldn’t remember each and every step and I ended up typing in something wrong. (I know, I know, but I thought I could get away with it).

    The funny thing was, when I tried a Live boot, it would be distorted for a few seconds and then right itself as the system messages spit out and eventually popped me into the desktop environment.

Regardless, I couldn’t do an installation from the desktop management environment, or CLI for that matter (I won’t mention the distribution, but this was annoying to say the least).

I thought that perhaps there was something wrong with the video= mode since it was set to video=vesa:ywrap,mtrr and I monkeyed around with that for awhile to no avail.

I began to make changes to the the vga= mode option from GRUB since the laptop’s natural resolution was 1366x768 and believed that to be the culprit of the problem, having the “odd” resolution. So I went through the laundry list of vga= modes. I tried normal, I tried 791, 788, I even tried ask (vga=ask) and nothing worked. So then I decided to enter into the GRUB command line and see what was up with the videoinfo command.

That brought me to a screen that looked like this:

GRUB videoinfo

YMMV of course, in my case I noticed that it did see that the largest supported resolution was 1366x768 (in the example above, the highest supported mode was 1024x768 .

From there I decided to tackle it from a different approach and I dropped (escaped) back into the GRUB menu and decided to “edit” one of the install options. I saw the linux and initrd lines and add another line above those two (if you have tab completion turned on, dont worry about the line not matching up with the others, grub isn’t touchy about that.):

set gfxmode=1366x768

…and would you believe it. I had it execute by hitting F10 and Voila!  Linux booted up into the installation with everything looking perfectly. From what I understand it may be necessary to also add (or just change) the line [to]:

set gfxpayload=1366x768 or whatever resolution it is that you’re trying to achieve of course

Hopefully if you’re having a similar issue, this will solve it.

Belisarius Smith consults as a software engineer, cloud engineer, and security adviser. He has a BSBA in Security Management and is currently completing graduate studies in the Engineering Department at Penn State University with a Masters of Software Engineering. When he isn't traveling, mountain climbing, or reading, he spends his spare time on personal side projects and studies.

Leave a Reply