[SOLVED] Default user / username at login window

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.
esteban1uy

Re: Default user / username at login window

Post by esteban1uy »

undoIT wrote:These look very nice. But there are still two unnecessary keyboard clicks involved at the login window. I prefer username selected and cursor blinking in the password field, ready for action.
Ok, here we go:

Login with no extra keypresses nor clicks, (without LightDM, just out-of-the-box Mint 13).

1- Open a text editor and paste the following code:

Code: Select all

#!/bin/sh
gnome-screensaver-command -l
dbus-send --type=method_call --dest=org.gnome.ScreenSaver /org/gnome/ScreenSaver org.gnome.ScreenSaver.SimulateUserActivity
2- Save it inside your personal folder with the name .mylogin.sh
3- Open a terminal and execute the following code:

Code: Select all

chmod a+x ~/.mylogin.sh
4- From the main menu, go to "Preferences"->"Startup Applications" and add a new entry:

Code: Select all

Name: MyLoginMod
Code: sh /home/NAME_OF_YOUR_PERSONAL_FOLDER/.mylogin.sh
Comment: my login workaround
5- Again from the main menu, go to "Administration"->"Login Window", enter you password at prompt, go to the "Security" tab and check "Enable automatic login".

Restart your system and at login you'll get this (ready to type your password):
Image

There's no need to mess with other session managers (LightDM, XDM, Slim... whatever), you can have what you want with the default session manager.
Rüssel

Re: [SOLVED] Default user / username at login window

Post by Rüssel »

undoIT wrote:try running:

Code: Select all

sudo apt-get install lightdm liblightdm-gobject-1-0 unity-greeter
Thank you for the new code line. I gave the command, but these packages were already installed.
Do you have another idea what I can do to get lightdm running?
undoIT

Re: [SOLVED] Default user / username at login window

Post by undoIT »

At this point I would either try again with a fresh install or try re-installing mdm running dpkg-reconfigure and selecting mdm and using that instead.
Rüssel

Re: [SOLVED] Default user / username at login window

Post by Rüssel »

undoIT wrote:At this point I would either try again with a fresh install or try re-installing mdm running dpkg-reconfigure and selecting mdm and using that instead.
I did just that. Now I have mdm back. Better than having no dm at all.
:-)
Thank you for helping
Monsta
Level 10
Level 10
Posts: 3071
Joined: Fri Aug 19, 2011 3:46 am

Re: Default user / username at login window

Post by Monsta »

esteban1uy wrote:Ok, here we go:
Err... working around MDM's problem via autologin and lock screen?! :D
Well, quite impressive, but...

Can this be taken as an answer like "no, you can't have username selected right away in MDM, so press Up twice and bear with it"? :D
esteban1uy

Re: Default user / username at login window

Post by esteban1uy »

Monsta wrote:
esteban1uy wrote:Ok, here we go:
Err... working around MDM's problem via autologin and lock screen?! :D
Well, quite impressive, but...

Can this be taken as an answer like "no, you can't have username selected right away in MDM, so press Up twice and bear with it"? :D
Au contraire my friend... that's the proof that you can have exactly what you want using only things already included in Mint, without having to install anything else.

By the way, take a look at this (the future Gnome Lock Screen): https://live.gnome.org/GnomeOS/Design/W ... ScreenLock
http://www.youtube.com/embed/nQ9ZfpXcPt0
Monsta
Level 10
Level 10
Posts: 3071
Joined: Fri Aug 19, 2011 3:46 am

Re: [SOLVED] Default user / username at login window

Post by Monsta »

Funny... I've stumbled upon a four years old request on the same topic which has led me to this Ubuntu Brainstorm page. Looks like the "solution" one of the developers mentioned there was just a plain transition from gdm 2.20 to gdm3 :)
delicious

Re: Default user / username at login window

Post by delicious »

undoIT wrote:

Code: Select all

sudo apt-get install lightdm
sudo dpkg-reconfigure lightdm
Hit Enter to Ok and then select lightdm. Reboot. Aaaaaaah. Relief!

If you are feeling naughty...

Code: Select all

sudo apt-get remove mdm mint-mdm-themes
Just wanted to warn other newbies about this method. Like the OP who tried it when I followed this my linux system would not boot up. Now i get to groundhogs day it and spend 4 hours re-installing and re setting up my layout like I like it. Just did this 24 hours ago :(
Monsta
Level 10
Level 10
Posts: 3071
Joined: Fri Aug 19, 2011 3:46 am

Re: Default user / username at login window

Post by Monsta »

delicious wrote:Like the OP who tried it when I followed this my linux system would not boot up.
Well, of course, because that post was about installing lightdm only, no lightdm-gtk-greeter or unity-greeter were mentioned :D
And the second command is unnecessary. Configuration prompt is triggered automatically after lightdm is installed. Running dpkg-reconfigure is needed only in case something goes wrong.

It's better to read this thread: http://forums.linuxmint.com/viewtopic.php?f=47&t=102716
undoIT

Re: [SOLVED] Default user / username at login window

Post by undoIT »

I have updated the original instructions. I don't remember doing the extra step for the lightdm.conf, but I may have done so before installing lightdm and didn't realize it was necessary. Sorry to anyone who had problems with the original instrucitons.
andr3w321

Re: Default user / username at login window

Post by andr3w321 »

undoIT wrote:

Code: Select all

sudo apt-get install lightdm unity-greeter lightdm-gtk-greeter
sudo dpkg-reconfigure lightdm
Hit Enter to Ok and then select lightdm.

Next:

Code: Select all

gksudo gedit /etc/lightdm/lightdm.conf/
add the following and save:

Code: Select all

[SeatDefaults]
user-session=cinnamon
greeter-session=unity-greeter
(you can also set the greeter to lightdm-gtk-greeter)

Reboot. Aaaaaaah. Relief!

The next step is not required, but if you are feeling naughty...

Code: Select all

sudo apt-get remove mdm mint-mdm-themes
This will remove mdm.
THANK YOU! Worked for me.
bb333

Re: [SOLVED] Default user / username at login window

Post by bb333 »

How the hell is this marked solved? This is the number one result in search engines about this problem.

Problem: Linux Mint's login manager, MDM, sucks and won't allow a default user to be preselected. i.e. you just type in your password.
Solution: Replace MDM with lightdm.

1. Open a terminal window.

Code: Select all

sudo apt-get install --no-install-recommends lightdm lightdm-gtk-greeter
No ubuntu garbage is pulled in nor unity-greeter.

The terminal screen will walk you through setting up a login manager. Select lightdm when given the choice.

2.

Code: Select all

sudo leafpad /etc/lightdm/lightdm.conf 
(Change leafpad to whatever text editor you like)

Code: Select all

[SeatDefaults]
user-session=mate
greeter-session=lightdm-gtk-greeter
allow-guest=false
Change "unity-greeter" to "lightdm-gtk-greeter." You will get a black screen or MDM will launch if you don't do this.
Add allow-guest=false if you want to disable guests on your computer (recommended)

3. Restart. Select the user you want with the mouse. The next time you login it will automatically select that user and all you have to do is type your password.


Make the login screen "prettier" or more config options:
/etc/lightdm/lightdm-gtk-greeter.conf
/etc/lightdm/lightdm-gtk-greeter-ubuntu.conf
https://wiki.ubuntu.com/LightDM
Locked

Return to “Beginner Questions”