2

I've just bought a new laptop from Asus: Rog Strix Scar G17 G733QS and I tried installing Ubuntu 20.04 on it.

The problem is that every time I press any key on the laptop keyboard, the shut-down dialog/pop-up appears and if I forget about this and mistakenly press multiple keys, the laptop shuts down.

It seems that I can use Ubuntu just fine with a USB keyboard, but this is clearly not okay.

Do you have any idea about what I could do?

Update 1: I encountered the same behaviour on Fedora 33, but the live OS worked fine. Maybe the driver in the kernel is not compatible with the controller of the keyboard?

Update 2: I also tested Linux Mint with Cinnamon and everything works fine so far! Since both Ubuntu 20.04 and Fedora 33 use GNOME, I suspect it is somehow related to the DE. I further suspect that the underlying problem has to do with the preinstalled nouveau drivers which at the moment do not support the RTX 3080 laptop in the laptop because I got a warning, right before the DE gest loaded at boot time, saying that the device was not recognized.

Update 3: Now, one day later, the same behaviour started on Linux Mint too. When I press any key on the laptop's keyboard, the associated letter is generated if inside a text editor, but also the shut down dialog appears. When using an external keyboard, everything works fine. As recommended by Jason Croyle, here is the output of xev associated with me pressing a key on the laptop's keyboard:


MappingNotify event, serial 44, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

KeyPress event, serial 44, synthetic NO, window 0x5000001,
    root 0x50f, subw 0x0, time 423525, (-550,168), root:(942,438),
    state 0x0, keycode 24 (keysym 0x71, q), same_screen YES,
    XLookupString gives 1 bytes: (71) "q"
    XmbLookupString gives 1 bytes: (71) "q"
    XFilterEvent returns: False

KeyRelease event, serial 45, synthetic NO, window 0x5000001,
    root 0x50f, subw 0x0, time 423602, (-550,168), root:(942,438),
    state 0x0, keycode 24 (keysym 0x71, q), same_screen YES,
    XLookupString gives 1 bytes: (71) "q"
    XFilterEvent returns: False

MappingNotify event, serial 45, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

FocusOut event, serial 45, synthetic NO, window 0x5000001,
    mode NotifyGrab, detail NotifyAncestor

FocusIn event, serial 46, synthetic NO, window 0x5000001,
    mode NotifyUngrab, detail NotifyAncestor

KeymapNotify event, serial 46, synthetic NO, window 0x0,
    keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   
           0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0 

as opposed to the output of xev when pressing a key on the external keyboard:

KeyPress event, serial 38, synthetic NO, window 0x6200001,
    root 0x50f, subw 0x0, time 826960, (-20,-2), root:(841,452),
    state 0x0, keycode 24 (keysym 0x71, q), same_screen YES,
    XLookupString gives 1 bytes: (71) "q"
    XmbLookupString gives 1 bytes: (71) "q"
    XFilterEvent returns: False

KeyRelease event, serial 38, synthetic NO, window 0x6200001,
    root 0x50f, subw 0x0, time 827056, (-20,-2), root:(841,452),
    state 0x0, keycode 24 (keysym 0x71, q), same_screen YES,
    XLookupString gives 1 bytes: (71) "q"
    XFilterEvent returns: False

After searching the extra events, I found out that KeymapNotify happens everytime an application is awakened and is a way to inform that application about the state of the keyboard. I suspect this happens because the shut-down dialog is the awakened application in this case.

The MappingNotify event, on the other hand, seems to point out that the mapping of the physical key press has changed. And it seems like this happens once for the key press and once for the key release.

3 Answers 3

2

That sounds like a possible hardware problem: the laptop's built-in keyboard matrix might be short-circuited with the power button signal or some other function key that triggers the shut-down dialog.

While you probably could disable the ACPI power button handling as a workaround, if you have been sold a faulty product, you should probably get it fixed or replaced with a good one while it's still under warranty.

1
  • Fortunately or unfortunately, this is not the problem, as the keyboard works fine in Windows and it also worked during Ubuntu installation, although during installation, there was a delay between the moment I pressed a key and the moment it appeared on screen
    – A01XP
    Feb 22, 2021 at 15:21
1

This is related to Linux kernell 5.11/Nvidia 30* video cards. After update to 5.11 following these steps, the system becomes stable

  1. update to 5.11 https://sypalo.com/how-to-upgrade-ubuntu In case after the restart, the screen remains black with an error message use the advanced option choose 5.11 (recovery mode)

  2. do these steps https://forums.developer.nvidia.com/t/ubuntu-mate-20-04-with-rtx-3070-on-ryzen-5900-black-screen-after-boot/167681/30

1
  • 1
    This worked for me, thank you! I also encountered the problem of a black screen with the error message of the form: <partition path>: clean <a/b> files, <c/d> blocks" and no access to any terminal via CTRL + ALT + F<n> and starting Ubuntu in recovery mode worked! This solution has the bonus of also having working Nvidia drivers afterwards.
    – A01XP
    Mar 6, 2021 at 13:13
1

Try running “xev” in the terminal it will show you exactly what key event are being sent. This should be a good place to start. If everything is working with Mint I would think it probably has to do with some shortcuts. But “xev” will get us some info and a place to start.

Hope it helps, Jason

1
  • Today, when I logged into Mint, I started encountering the same behaviour as in Ubuntu and Fedora :( I took your advice and updated the question with the output of xev associated with a key press on the laptop's keyboard and on an external keyboard. I think you're right, there seems to be some sort of key mapping being triggered.
    – A01XP
    Feb 23, 2021 at 12:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .