If your system uses AccountsService, you can not hide a user from the greeter screen by reconfiguring lightdm because it defers to AccountsService. That is stated very clearly in the comments in /etc/lightdm/users.conf.
What you need to do instead is to reconfigure AccountsService.
To hide a user named XXX, create a file named
/var/lib/AccountsService/users/XXX
containing two lines:
[User]
SystemAccount=true
If the file already exists, make sure you append the SystemAccount=true line to the [User] section.
The change takes effect after reloading AccountsService:
#
# User accounts configuration
#
# NOTE: If you have AccountsService installed on your system, then LightDM will
# use this instead and these settings will be ignored
#
# minimum-uid = Minimum UID required to be shown in greeter
# hidden-users = Users that are not shown to the user
# hidden-shells = Shells that indicate a user cannot login
#
[UserAccounts]
minimum-uid=500
hidden-users=nobody nobody4 noaccess
hidden-shells=/bin/false /usr/sbin/nologin
Of interest to us is the part here:
hidden-users=nobody nobody4 noaccess
To hide the username james, just add it like this:
On some versions of lighdm (Ubuntu 14.04) you need to rename [UserAccounts] to [UserList] (in /etc/lightdm/users.conf) for this method to work. (If you're interested in why this may be necessary, see common/user-list.c:321 from lightdm source.)
This a variation of James' answer. You can hide users in lightDM by simply assigning them an ID below the minimum ID found in:
/etc/lightdm/users.conf
On my PC it was 1000
# minimum-uid = Minimum UID required to be shown in greeter
# hidden-users = Users that are not shown to the user
# hidden-shells = Shells that indicate a user cannot login
#
[UserAccounts]
minimum-uid=1000
You can change UID easilly in terminal:
sudo usermod -u PutUserNameHere
It works on my PC (in 2016), so I guess the lightDM bug that Eliah Kagan mentioned in 2014 with regards James' answer has been resolved.
If your system uses
AccountsService
, you can not hide a user from the greeter screen by reconfiguringlightdm
because it defers toAccountsService
. That is stated very clearly in the comments in/etc/lightdm/users.conf
.What you need to do instead is to reconfigure
AccountsService
.To hide a user named
XXX
, create a file namedcontaining two lines:
If the file already exists, make sure you append the
SystemAccount=true
line to the[User]
section.The change takes effect after reloading AccountsService:
Currently this method is not working because of a bug in lightdm.
Please check the bug status before applying this method.
Heres what you want to do:
First, make a backup of your config.
Then, you need to edit your config:
You'll see something like this:
Of interest to us is the part here:
hidden-users=nobody nobody4 noaccess
To hide the username
james
, just add it like this:hidden-users=nobody nobody4 noaccess james
Then, reboot your computer and it should be gone.
As a reference to others, see
See https://bugs.launchpad.net/ubuntu/+source/accountsservice/+bug/857651
On some versions of lighdm (Ubuntu 14.04) you need to rename
[UserAccounts]
to[UserList]
(in/etc/lightdm/users.conf
) for this method to work. (If you're interested in why this may be necessary, seecommon/user-list.c:321
from lightdm source.)Your option until bug 857651 is fixed is to create the user with uid < 1000
For example, to assign new uid less than 1000, (we are using 999) use this command
Replace the
user-name
with the actual user name, just asanwar
ordetly
etc.because the Ubuntu 12.04 setup
so we need to reduce the
uid
less than 500example:
sudo usermod -u 499 user-name
It works with me! SOLVED Good luck.
This method is not works on Ubuntu 13.10.
To hide user login names correctly You must to open LightDM config:
and add the following options:
Then save and reboot. That's all.
This a variation of James' answer. You can hide users in lightDM by simply assigning them an ID below the minimum ID found in:
On my PC it was 1000
You can change UID easilly in terminal:
It works on my PC (in 2016), so I guess the lightDM bug that Eliah Kagan mentioned in 2014 with regards James' answer has been resolved.
In Ubuntu: