A hack to autologin


Guys, any trick with making [2018-12-08-ubiquity-xenial-lxde] to login automatically?
I have read tons of manuals on this topic, even posted at ubuntu-specific forums, but all suggested solutions don’t work:



For greeter-session I tried other values as well, no success.
The problem can be partially solved in GUI - to make the system login without password, but that’s not what is required.


What kind of auto login are you attempting? As in you are trying to get the graphical session to automatically load to the desktop instead of requiring a password?



I would like to have my Raspberry automatically logging in to GUI as default (ubuntu) user without password request. Currently my greeting page of GUI shows a small window with “Ubuntu User” and a button “Unlock”. It waits for the button to be pressed by somebody. I would like to avoid this step - just want the system to bypass this step.


The correct answer occurred to be:

You will need to create an /etc/lightdm/lightdm.conf with these contents: (do this as root)

autologin-user={YOUR USER}



My solution for auto-login was slightly different.

This worked both on the Lubuntu (from Ubiquity download) of 2018-Dec-08, and on the previous version of 2018-Nov-15

  • Create the following file

    sudo   touch  /etc/lightdm/lightdm.conf.d/10-autologin.conf
  • Edit the file

    sudo   nano  /etc/lightdm/lightdm.conf.d/10-autologin.conf
  • Add the contents as follows:

    autologin-guest = false
    autologin-user = ubuntu
    autologin-user-timeout = 0
    allow-guest =  false