Numlock activate at startup in login screen

Sponsored Link
It is very annoying that the numlock is not activated at startup in the login screen GDM, especially when using a password that contains numbers.

Make sure that the universe repository is enabled.

Execute the following commands in a terminal

sudo apt-get install numlockx

sudo gedit /etc/X11/gdm/Init/Default

Add the following lines at the end before the line "exit 0":

if [ -x /usr/bin/X11/numlockx ]; then
/usr/bin/X11/numlockx on
fi

Put off your numlock and restart X by pressing Ctrl+Alt+Backspace

The numlock should be activated now and every time when you reboot

Sponsored Link

Related posts

16 thoughts on “Numlock activate at startup in login screen

  1. In Gutsy, gedit /etc/gdm/Init/Default
    add
    if [ -x /usr/bin/numlockx ]; then
    /usr/bin/numlockx on
    fi

  2. In 8.04 Hardy 64bit it is slightly different. The command should be:

    sudo gedit /etc/gdm/Init/Default

    Add those lines as the instructions above describe. The only difference is the file is located in a different directory.

  3. Cannot find file:

    /etc/X11/gdm/Init/Default

    don’t have “gdm” in folder X11 and cannot find it anywhere else.

    Christopher

  4. The suggestion works, but in Ubuntu 8.10 the numlock is disabled after login and must be reenabled. Any suggestions?

  5. sudo apt-get install numlockx

    sudo gedit /etc/gdm/Init/Default

    Add the following above the last line (exit 0):
    if [ -x /usr/bin/numlockx ]; then
    /usr/bin/numlockx on
    fi

    Works in 9.04 Jaunty as well.

  6. for ubuntu 9.04 use

    sudo gedit /etc/gdm/Init/Default

    no

    sudo gedit /etc/X11/gdm/Init/Default

    the rest is the same

  7. Hello,

    Why do you change your instructions? Several people have corrected you… And the fi looks like a typo. Why not make it clear that it goes in there?

    Also, you might want to link to a new blog entry or one you’ve already created about the new Ubuntu disabling Ctrl+Alt+Backspace and needing to run “sudo dontzap --disable” in a terminal. (probably after sudo apt-get install dontzap)

    Thanks

  8. flippah…use the instructions bdoe gave. They work for Ubuntu 9.10.
    ————————————————

    sudo apt-get install numlockx

    sudo gedit /etc/gdm/Init/Default

    Add the following above the last line (exit 0):
    if [ -x /usr/bin/numlockx ]; then
    /usr/bin/numlockx on
    fi

  9. for ubuntu 10.04 (lucid), pay attention, second step is :

    sudo gedit /etc/gdm/Init/Default

    (and NOT sudo gedit /etc/X11/gdm/Init/Default : this would create a new file, so you would see an empty window with gedit)

  10. I’ve done all of above instructions,and get not through at all!
    I must run “numlocx on” in the Terminal window to activate it!
    Is there any fault in the instruction to edit “Default” file?

  11. ffs there is no gdm folder anywhere, as Christopher already pointed out years ago. Your page is stealing search results for solutions that don’t work.

Leave a comment

Your email address will not be published. Required fields are marked *