gpm prevents loging to the console: spurious “Enter” events seems inserted

Bug #1814261 reported by EOLE team
32
This bug affects 6 people
Affects Status Importance Assigned to Milestone
gpm (Ubuntu)
Confirmed
Undecided
Unassigned
linux (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Hello,

When our servers boot, We can't login because of spurious “enter”.

We have this problem on virtual and physical machines since:

* kernel linux-image-4.15.0-44-generic on bionic
* kernel linux-image-4.4.0-142-generic on xenial

To reproduce:

1. start an ubuntu server with the specific kernel
2. install GPM
3. on a console
   1. type the user name “root”
   2. hit “enter”
   3. wait few seconds => spurious “Enter” are send to the console
4. Stop gpm.service
5. retry to login on a console => no problem

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.1 LTS
Release: 18.04
Codename: bionic

Tags: bionic xenial
Revision history for this message
Alexis Wilke (alexis-m2osw) wrote :

I have the exact same problem on Ubuntu 16.04 (vmlinuz-4.4.0-142-generic).

I will try to turn off GPM and see how my console functions without it.

What a surprise though! Not being able to log in the simplest console. Not something I've seen in ages...

Revision history for this message
Alexis Wilke (alexis-m2osw) wrote :

I rebooted on Ubuntu 16.04 (4.4.0-142-generic) and it worked as expected once gpm was turned off.

I used the following command to prevent gpm from starting on a reboot and messing up the login screen:

sudo systemctl mask gpm

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gpm (Ubuntu):
status: New → Confirmed
Revision history for this message
Mike Wescott (wescott) wrote :

Seen on linux-image-4.15.0-44-generic and linux-image-4.15.0-45-generic.

When /bin/login is exec'd by agetty it tries to read stdin and gets EAGAIN:

    5640 write(2, "Password: ", 10) = 10
    5640 read(0, 0x7ffcca86a7f0, 511) = -1 EAGAIN (Resource temporarily unavailable)
    ...
    55640 write(2, "\n", 1) = 1

taking that as a failed login attempt it tries again:

    55640 write(2, "hilbert login: ", 15) = 15
    55640 read(0, 0x7ffcca86a160, 511) = -1 EAGAIN (Resource temporarily unavailable)

eventually logging a failed login attempt

reverting to linux-image-4.15.0-43-generic also fixes the problem

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in linux (Ubuntu):
status: New → Confirmed
affects: linux-meta (Ubuntu) → linux (Ubuntu)
Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Norbert (nrbrtx) wrote :

Yesterday I went to this bug on Ubuntu 16.04.5 LTS with all updates and without PPAs on physical hardware.
The problem was with 4.4.0-142-generic kernel. Rebooting with previous kernel (138 in may case) helped.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.