Does the shortcut Ctrl-Alt-F... turn off the GUI or is it still running in the background?
When you switch to a "virtual terminal" by pressing Ctrl+Alt+F3 everything else remains as it was. So when you later press Alt+F2 (or Alt+Left or repeatedly Alt+Right) you get back to the GUI session and can continue your work.
In previous Ubuntu versions VT1 would be unused and the standard X session would run on VT7. Currently (at least from 18.04 onwards) VT1 is used for the display manager ("login screen"), the standard X session uses VT2. Hence we have VT3 as the first usable VT.
If you ever logged in with two users on the same machine or started gui on another tty1 with startx
, you'd notice something like this:
$ who
xieerqi tty1 2015-07-31 22:17
xieerqi :0 2015-07-31 22:18 (:0)
xieerqi pts/7 2015-07-31 22:18 (:0)
Here I have 3 logins - on tty1, on screen :0, and in gnome-terminal. With another user, it'd be reporting another display :1. So what's happening ? All the sessions are still active, GUI and tty are active at the same time. But switching between them makes linux switch who has control over keyboard (or more technically stdin
device ) and screen (stdout
) at the moment.
Now, if I'd kill all my GUI sessions (sudo pkill unity
), then GUI would be disabled temporarily. Or if I stopped lightdm
because it's a parent process of GUI (because I logged in there). And of course it could be restarted.
GUI is not disabled, in other-words, it just doesn't have control over keyboard and screen until you switch back with CtrlAltF7 or cycle through with AltL/R Arrow.