The infamous Linux Black Screen with Cursor

Oh my my this can be a frustrating one. In short, something has gone wrong with the boot process.

In my case, I had an errant line in my grub config file. What’s that? It’s the bootloader. It’s the thing that controls how the machine passes control from the BIOS to the hard drive (not exactly, but that’s good enough to get you approving nods at cocktail parties; go with it.)

Sometimes when you monkey with things in Linux, you make mistakes, and oh shit. Now what. This is probably one of those times (if you’re seeing the infamous black screen with cursor). My story was simple. Instead of a “quiet splash”, where you don’t see the system messages as your computer boots and shuts down, which is the default behaviour with Ubuntu, I wanted to see the system messages. This is controlled by GRUB — the Grand Unified Bootloader.

There’s a simple file that controls how GRUB behaves. It is: /etc/default/grub

If you edit that file (as root (with sudo), of course), be very careful. In my case, I wanted to remove the “quiet splash” in the line

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

When I did this, I left some text between the quotes. Oops. In order to see the system messages, the line should read

GRUB_CMDLINE_LINUX_DEFAULT=""

In my case, the change results in this (after I fixed the error that precipitated this whole conversation):

Now, when you edit this file, in order for the changes you’ve made to have an effect, you must run:

sudo update-grub

Of course, I did this. But with the errant text between the quotes (not shown here, because I went back and fixed it), GRUB was like, what the fuck do you actually want??

The result: the black screen of death.

The solution: when booting, press whatever it takes to force the boot menu. For me, on a Lenovo Yoga 530, I pressed F12.

From the boot menu, you can drop into a command prompt (recovery mode) and edit the grub file and remove whatever is wrong.

Then, DON’T FORGET, run

sudo update-grub

Then resume boot as normal.

In my case, this fixed the problem. If this doesn’t fix the problem, then I recommend altering your GRUB config so that you can see system messages, then boot again and see where the problem is. Then, search for solutions to that problem, whatever it is.

But, in many cases, errant grub config might well have been the problem.

** A quick note about the black screen with the cursor: sometimes the system is really just waiting for something to finish, and if you’re patient enough, it’ll finish and the next phase of booting or whatever will commence. In this case, the question is how patient you’re willing to be. (I’m not very patient, so I’d just cold boot the bastard and figure out what was taking so long and eliminate or streamline it. But that’s me, and I’m really fun in queues.)