Turn on NumLock automatically on Linux

Turn on NumLock automatically on Linux

Add the following lines to /etc/rc.d/rc.local:

echo -n "Turning on numlock ... "
  for tty in /dev/tty[1-6] /dev/tty1[2]; do
    setleds -D +num < $tty &
  done
echo "done "

whoami
Stefan Pejcic
Join the discussion

I enjoy constructive responses and professional comments to my posts, and invite anyone to comment or link to my site.