6

I know this question comes up a lot, and I've seen some answers.

But the thing is, from what I understand numlockx is made for Xorg and does not work on Wayland.

I saw that some implementations of Wayland like Weston have a config file where I can chose the default behavior for numlock. But I haven't been able to find anything similar for the Gnome Shell implementation on Ubuntu 17.10

Also, I have numlock ON on my UEFI, and it is on during GRUB, but after I start Ubuntu it is switched off.

How can I manage to set this behavior without having to change to Xorg?

3
  • askubuntu.com/a/977793/692175
    – user692175
    Commented Nov 19, 2017 at 2:30
  • 1
    That question was also made by me and does not solve the problem. Just made me understand unlockx wont work on Wayland.
    – Galvas
    Commented Nov 19, 2017 at 2:38
  • The point was to remind you that there's no point in bringing up weston again. I hope you get an answer soon.
    – user692175
    Commented Nov 19, 2017 at 2:42

2 Answers 2

3

You need to set it as gdm user via gsettings command

The solution that should work:

  1. Open terminal via Ctrl+Alt+T, then run command to get root privilege:

    sudo -i

  2. Switch to user gdm in the terminal:

    su gdm -s /bin/bash

  3. Finally set ‘Numlock on’ via gdm user:

    gsettings set org.gnome.settings-daemon.peripherals.keyboard numlock-state 'on'

Restart the computer and done

1

Don't have the reputation to comment so I have to post this this way.

The @bonhomag 's solution does not work for me. The procedure works with the command

gsettings set org.gnome.settings-daemon.peripherals.keyboard numlock-state on

instead of the last command in his answer (same command but no '' around the on).

Using Ubuntu 18.04 LTS.

Found that on ArchWiki.

You must log in to answer this question.

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