I seem to remember that a few years back, in order to login on Windows you had to type Ctrl-Alt-Del to get a login screen.

The advantage of this was that if you had a cat or child that liked to press random keys on your computer keyboard, they wouldn't screw things up. Well, my kids are in their 40s now, but I do have a cat that likes to walk over the keyboard from time to time, and believe it or not - that requires a reboot to recover from the consequences.

Is there anything (short of hiding the keyboard) that can be done about this?

  • 14
    Related bug report on Launchpad: Cat sitting on keyboard crashes lightdm and especially Cat causes login screen to hang – Byte Commander Jun 22 '16 at 7:09
  • The funny thing is that I find "Press ctrl + alt + delete to login" pretty annoying. Guess it's because I don't have a cat or a child or anything else for that matter that might accidentally "sit" on my keyboard screen. – Parto Jun 22 '16 at 7:15
  • 2
    Get a wireless keyboard (all of them have a "off" button). "that requires a reboot to recover from the consequences." Nope. control-a and backspace is enough to clear the entry. – Rinzwind Jun 22 '16 at 8:01
  • 19
    @Parto: That's not the purpose. The purpose of Ctrl+Alt+Del is that it is a Secure Attention Key sequence (SAK), i.e. a key sequence that is handled directly by the kernel, deep down in the guts of the system, and cannot ever be intercepted by a user program, system service or even a kernel driver. So, you know when you type the SAK that you are talking to the system itself and not, for example, to a user program that is made to look exactly like the login screen and sends the password you just typed in straight to some Russian crime syndicate (or whatever). Nothing to do with pets or kids. – Jörg W Mittag Jun 22 '16 at 8:43
  • 2
    The lifehacks SE has solutions here and there are wikihow solutions here that involve teaching you cat to ignore your computer instead of teaching your computer to ignore your cat. – NonlinearFruit Jun 22 '16 at 16:34

Switch to virtual console x (x ≥ 8) (CtrlAltFx, say x = 12). Those don't have getty or LightDM (or anything, really) running on them, so the cat can walk over the keyboard to its heart's content. Then press CtrlAltF7 to get back to LightDM and the login screen.

You could automate this during boot by adding chvt 12 to /etc/rc.local (see this U&L post).

Special buttons like the power button might still be a cause for concern.

On second thought, other key combinations are available:

  • if the virtual console is not running X, then the CtrlAltFx can be used without Ctrl - just AltFx would work.
    • Alt+ arrow keys can also be used to switch to the previous and next VTs
    • CtrlAltDel triggers a reboot in any of the VTs not running X.

So a better solution might be running an empty X session (not running any other application) in VT12 to cut down the number of available key combinations and switching to it.

startx -- :100 vt12 &

This needs to be tested (you might need to write an .xinitrc to override the defaults).

  • 2
    That's the best solution, taking in account the mentioned bug, etc. But I am afraid that not many people will understand it. There is a small probability that the cat will press Ctrl+Alt+F7 though ;-) – Pilot6 Jun 22 '16 at 13:08
  • @Pilot6 yes, but you can also lock the screen and then move to a virtual console. It'd be not much different to having to press Ctrl+Alt+Del then having to enter credentials in Windows. – VLAZ Jun 22 '16 at 21:20
  • Won't that write the same enormous amount of data into the prompt? – Ismael Miguel Jun 23 '16 at 0:41
  • @IsmaelMiguel what prompt? – muru Jun 23 '16 at 5:45
  • 1
    @IsmaelMiguel the kernel does. It still listens for the keyboard shortcuts for switching VTs, Ctrl-Alt-Del, etc. – muru Jun 23 '16 at 10:21

You can to the same by pressing


This will lock the screen and require the password to unlock it.

  • 5
    I guess the OP is already at the login screen and wants something to protect his system from this rather funny but sadly true bug bugs.launchpad.net/ubuntu/+source/unity/+bug/1463112 – Byte Commander Jun 22 '16 at 7:08
  • 1
    It looks like OP is asking how to get to login screen, isn't it? – Pilot6 Jun 22 '16 at 7:17
  • And that bug has been fixed recently. It is a duplicate of a fixed bug. – Pilot6 Jun 22 '16 at 7:20
  • OP clearly says "in order to login on Windows you had to type Ctrl-Alt-Del to get a login screen" . It's called secure logon So yes, that's for login screen – Sergiy Kolodyazhnyy Jun 22 '16 at 8:17
  • 2
    @Pilot6: Quite the opposite: the OP is looking for a way to HIDE the login screen when logged out. In windows you had to press Ctrl-Alt-Del to show the login screen otherwise it will just show you the screensaver when pressing any other keys. On most other OSes pressing any key shows the login screen. The OP wants to disable this behaviour and hide the login screen when you press any keys except certain magic key combinations that are not easy to press accidentally. – slebetman Jun 22 '16 at 13:34

Some related bug reports on Launchpad:

Those bugs describe that lightdm (the package behind your login screen) experiences some kind of keyboard input buffer overflow if you keep on hitting keys on the lock or login screen.

The primary bug report mentions that a fix for this bug was finally released for 16.04:
They now limit said input buffer to 200 characters to prevent it from getting filled up with insane amounts of data.

So the hanging up if a cat sits on a keyboard on the login screen should be fixed in 16.04 now (maybe you want to upgrade?).

However, I don't think that older releases would profit from a setting that requires you to hit Ctrl+Alt+Del before logging in, as that would then probably be a feature of lightdm itself again and would likely not help and suffer from the same bug...


Place pre-warmed cardboard boxes near the keyboard. The cat will default to sitting in these and will leave your computer alone.

  • Ah, the social hack is sometimes the most effective. – flickerfly Jun 28 '16 at 17:46

Excessive keyboard input is known to hang the LightDm screen.

There is currently no way to prevent the problem from happening, however you can easily remove the characters from the login box by pressing Shift+Home (to select all) then Backspace (to delete). It may take a few seconds before the machine becomes responsive again.

Note that the issue has been fixed in the next version of Ubuntu.

  • I use Ctrl+A and then type password – NonlinearFruit Jun 22 '16 at 16:27
  • Ctrl+Backspace very often works, too. (Not always on Windows, though.) May or may not work in LightDM. – a CVn Jun 22 '16 at 19:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.