Ubuntu – Ctrl+Alt+F-keys do not respond after having gone in the loginless virtual console

virtual-console

Situation

I am working with Ubuntu 14.04 LTS. My computer was (and is) running a several-day long task launched from a terminal in the desktop environment. I then sent it to the background and disowned from the host shell.

In this way I could log out of the desktop environment and have it going all the same. Prospected advantage: the memory usage will be kept at a minimum, for the applications in the graphical environment will not possibly leak memory and cause the system to freeze in the long run.

By using the tty consoles I could check the state of the run, and possibly log in back into the desktop environment if so wished. I tested this way of operating, and it went very well.

There was plenty of memory available for all processes running.

Issue

When I was logged out of any console, I played with the key combinations Alt + Ctrl + F1 through F7, just to see once again how the system switched between the login prompts/greeter for each tty.

I then went a few keystrokes too far, Alt + Ctrl + F8 and onwards, and landed on a blank page with a blinking cursor; this is expected. The unexpected is that I cannot go move away from this blank page any longer. I have checked on another machine that such a move back is possible.

The computer seems to keep on working as it should. The keyboard is properly wired onto the machine (the screen's sleep responds to it).

Questions

What could be a reason for this behaviour?

Is there a way to get the computer responding to the console selection other than kill all processes and starting from scratch?

Note

No avail from the following suggested answers:

ctrl+alt+f* is not working

How do I get Ctrl+Alt+F* virtual terminals to work in Ubuntu 12.04?

Ctrl+Alt+F[1-12] don't switch to TTY

Best Answer

I observed it on 18.04. It's hard to figure out the culprit - there is a concept of "seats" now, which ignore network logins. There is a concept of logind and login sessions. There is a concept of killing gettys and running them "on demand". There is kernel modesetting, wayland, etc. However, the virtual console was overtaken by systemd, logind, seats, and sessions have plenty open bugs, gettys are now some type of "service".

In the end - if you login as the same user - you're somewhere in "logind" + "session" + "seat" + "resource control", so exiting a getty might mean changes to login/session/seat/accounting, etc.

In my case I had additional usb(?) issues, as my mouse would no longer work, my keyboard was dead, but somehow the touchpad was ok. Or maybe there's something something with dbus on the way. We'll probably never know. My logs didn't say anything interesting, it was mostly: "systemd did this, systemd did that, the result of the service is RESULT". Go figure. It didn't break in debian stretch yet, but with coming upgrades - who knows what's gonna happen.