How do I make GDM the default display manager?

I believe my question says what I am trying to achieve.

Steps I tried to make gdm my default display manager:

  1. sudo dpkg-reconfigure than select gdm as my default.
  2. Edit /etc/X11/default-display-manager and change its content to

    /usr/sbin/gdm
    

After the above two steps I logged out myself and after that when I see my login screen it still shows lightdm as my display manager.

What am I doing wrong here.?


Solution 1:

You seem to have configured gdm correctly, but you did not actually stop lightdm. Logging out doesn't stop it.

After doing sudo dpkg-reconfigure gdm, you need to stop lightdm

sudo service lightdm stop

and start gdm

sudo service gdm start

Hope this helps.