How can I disable auto login?

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Jasper
Level 1
Level 1
Posts: 13
Joined: Sat Apr 17, 2021 4:10 pm

How can I disable auto login?

Post by Jasper »

I want Mint to ask for a login password. Unfortunately none of the solutions Google provides seem to apply to the latest version 20 with all updates.

Thank you
Last edited by SMG on Tue Jul 12, 2022 8:22 pm, edited 1 time in total.
Reason: Locking old topic to prevent new questions from being added.
JeremyB
Level 21
Level 21
Posts: 13881
Joined: Fri Feb 21, 2014 8:17 am

Re: How can I disable auto login?

Post by JeremyB »

If you are using Cinnamon it is in the Login window settings, under users tab
Jasper
Level 1
Level 1
Posts: 13
Joined: Sat Apr 17, 2021 4:10 pm

Re: How can I disable auto login?

Post by Jasper »

No sir. As I stated, that setting has no effect. I'm still logging in automatically and still have to input 2 passwords to connect to a network share. Time to reinstall. :(
User avatar
majpooper
Level 8
Level 8
Posts: 2087
Joined: Thu May 09, 2013 1:56 pm
Location: North Carolina, USA

Re: How can I disable auto login?

Post by majpooper »

Jasper wrote: Sat Apr 17, 2021 5:38 pm No sir. As I stated, that setting has no effect. I'm still logging in automatically and still have to input 2 passwords to connect to a network share. Time to reinstall. :(
I just did it so I know it is quite simple - but I may not be running the same version of MInt that you are.
here is what I am running - as you can see LM19.3 Cinnamon

Code: Select all

majpooper@1150z:~$ inxi -Fxz
System:    Host: 1150z Kernel: 5.4.0-54-generic x86_64 bits: 64 compiler: gcc v: 7.5.0 Desktop: Cinnamon 4.4.8 
           Distro: Linux Mint 19.3 Tricia base: Ubuntu 18.04 bionic 
If you type the command

Code: Select all

inxi -Fxz
in the terminal then someone with the same version can help you.
If it matches mine (LM 19.3 Cinnamon) or maybe even LM 20.x Cinnamon it is a two step process in System Settings > Login Window > Users
first, you have to move the slider to On to Allow Manual Login
second you need to delete the user that appears in the Username box in the Automatic Login section.

There is also away to accomplish by editing

Code: Select all

/etc/lightdm/lightdm.conf
but the System Settings GUI is the better way imo.
Jasper
Level 1
Level 1
Posts: 13
Joined: Sat Apr 17, 2021 4:10 pm

Re: How can I disable auto login?

Post by Jasper »

I'm running the latest LM 20, all updates current. Thanks.
User avatar
JOPETA
Level 17
Level 17
Posts: 7762
Joined: Thu Nov 20, 2014 6:10 am
Location: En un lugar de cuyo nombre no quiero acordarme

Re: How can I disable auto login?

Post by JOPETA »

I wonder is you need to reconfigure lightdm (sudo dpkg-reconfigure ligtdm) if another dm was installed and/or using another greeter.

Anyway, be sure you/your user don't belong to nopasswdlogin group in Menu>Administration>Users and group or terminal with id.
Last edited by JOPETA on Sun Apr 18, 2021 12:10 pm, edited 1 time in total.
Ni cola de león ni cabeza de ratón, prefiero ser diente de ajo.(Javier Krahe)
User avatar
majpooper
Level 8
Level 8
Posts: 2087
Joined: Thu May 09, 2013 1:56 pm
Location: North Carolina, USA

Re: How can I disable auto login?

Post by majpooper »

JOPETA wrote: Sun Apr 18, 2021 11:21 am I wonder is you need to reconfigure lightdm (dpkg-reconfigure ligtdm) if another dm was installed and/or using another greeter.

Anyway, be sure you/your user don't belong to nopasswdlogin group in Menu>Administration>Users and group or terminal with id.
lightdm is the display manager installed for a Cinnamon install. IF it is an LM 20.x Cinnamon install. There is really no reason though to even mess with lightdm configuratio file

Code: Select all

/etc/lightdm/lightdm.conf
I shouldn't have brought it up. I have no idea what DMs are used with MATE or Xfce. But, yeah, you are correct if we are talking a different display manager than lightdm then re-config of the lightdm config file would make no sense if it even exists.

But at any rate without knowing what the DE the OP is using (Cinnamon, MATE or Xfce) it's hard to help.
rene
Level 20
Level 20
Posts: 12212
Joined: Sun Mar 27, 2016 6:58 pm

Re: How can I disable auto login?

Post by rene »

All editions of Mint use lightdm. OP seems not very keen on helping him or herself though anyway (i.e., you already advised checking and/or editing the config file directly if for some reason the GUI tool doesn't work) so I'd advise not being overly concerned either.
User avatar
Flemur
Level 20
Level 20
Posts: 10096
Joined: Mon Aug 20, 2012 9:41 pm
Location: Potemkin Village

Re: How can I disable auto login?

Post by Flemur »

Jasper wrote: Sat Apr 17, 2021 5:38 pmNo sir. As I stated, that setting has no effect.
No sir, you didn't state that.
Time to reinstall. :(
It might be easier to edit the lightdm.conf file.
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
User avatar
JOPETA
Level 17
Level 17
Posts: 7762
Joined: Thu Nov 20, 2014 6:10 am
Location: En un lugar de cuyo nombre no quiero acordarme

Re: How can I disable auto login?

Post by JOPETA »

majpooper wrote: Sun Apr 18, 2021 11:39 am have no idea what DMs are used with MATE or Xfce
Linux Mint now, only install lightdm by default in Mate, Cinnamon or Xfce. I was only wondering if OP has installed another desktop as gnome or KDE or packages native from those another desktop so another dm would be installed (gdm3 or sddm). DM reconfiguration is also needed sometimes when installing other packages (graphic drivers, xorg...).
Ni cola de león ni cabeza de ratón, prefiero ser diente de ajo.(Javier Krahe)
JeremyB
Level 21
Level 21
Posts: 13881
Joined: Fri Feb 21, 2014 8:17 am

Re: How can I disable auto login?

Post by JeremyB »

JOPETA wrote: Sun Apr 18, 2021 11:53 am
majpooper wrote: Sun Apr 18, 2021 11:39 am have no idea what DMs are used with MATE or Xfce
Linux Mint now, only install lightdm by default in Mate, Cinnamon or Xfce. I was only wondering if OP has installed another desktop as gnome or KDE or packages native from those another desktop so another dm would be installed (gdm3 or sddm). DM reconfiguration is also needed sometimes when installing other packages (graphic drivers, xorg...).
We could find out if they post results from terminal for

Code: Select all

inxi -Sxxx
User avatar
JOPETA
Level 17
Level 17
Posts: 7762
Joined: Thu Nov 20, 2014 6:10 am
Location: En un lugar de cuyo nombre no quiero acordarme

Re: How can I disable auto login?

Post by JOPETA »

Yes, waiting for OP to comeback, as we can not discard anything (including no free space in root partition would explain why your first proposal didn't work), I think it is better the whole system information (inxi -Fxxxzr) :wink:
Ni cola de león ni cabeza de ratón, prefiero ser diente de ajo.(Javier Krahe)
Dave B
Level 4
Level 4
Posts: 392
Joined: Thu Jan 08, 2015 10:49 pm
Location: UK

Re: How can I disable auto login?

Post by Dave B »

Sometimes screenshots can be more helpful in explaining.

When a username is entered in the 'Username *' field (below example), then the system will automatically login.
Image


With username removed (as below), future logins will require a password
Image
Vithyaathar
Level 1
Level 1
Posts: 2
Joined: Mon Jun 14, 2021 7:14 am

Re: How can I disable auto login?

Post by Vithyaathar »

Yeah, i had the same problem but finally i got it to work without reinstall..
I had this problem.. Even when i removed my name from Login window>Auto-login and rebooted my device, it got logged on automatically.. Hope this is the solution you're looking for...

STEP 1: On your desktop, right click and select open as root.. Enter your password when it prompts you..
STEP 2: Navigate to Filesystem>etc>lightdm>lightdm.conf
STEP 3: Open the file lightdm.conf with a text editor or something.. Remember that if you skipped step 1, you won't have overwrite privileges.
STEP 4: You'll find a line like
autologin-user=<your_username>
In that, replace your username with false (all lowercase) and hit save..
AND YOU"RE DONE!!! This worked for me when all the mentioned methods failed for me :D :D :D
frostymusic
Level 5
Level 5
Posts: 502
Joined: Fri Jul 06, 2018 8:21 pm
Location: East Coast Canada

Re: How can I disable auto login?

Post by frostymusic »

DaveB, your suggestion worked for me Mint Mate 20
open_sky
Level 1
Level 1
Posts: 2
Joined: Thu Jan 06, 2022 4:51 am

Re: How can I disable auto login?

Post by open_sky »

In linux Mint 20.2 (Cinnamon 5) you need to type in your terminal:

Code: Select all

xed admin:///etc/lightdm/lightdm.conf

Code: Select all

autologin-user=false
Autologin must be with "false" key
Last edited by xenopeek on Thu Jan 06, 2022 5:18 am, edited 1 time in total.
Reason: replaced unsafe sudo command with normal admin:// way to open system files
Locked

Return to “Beginner Questions”