2

16.04.2 When one clicks on the gearswitch thing at top right (to log out or shutdown), there is a list of users, can this list be suppressed somehow?

Edited to add: Need to set this for all users, not just the logged in user.

2 Answers2

1

This setting is controlled via gsettings. To disable showing other usernames in the panel, run the following in terminal

$ gsettings set com.canonical.indicator.session user-show-menu  false 

Compare:

enter image description here

enter image description here

0

This answer helps you if you want to hide one (or several) specific accounts from the list.
If you want to disable the list completely and show no users (except guest account), follow @Serg's answer.

The presence of an account in the system menu's user list is connected to whether it shows up in the lightdm greeter/login screen.

To hide a user in both places, you may follow e.g. this answer by Marc Culler (tested by me on Ubuntu 16.04), which can be summarized as

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.

Now in order to still be able to log into an account hidden this way through the GUI, you have to enable manual logins in lightdm, which allows you to type in any username. See How to configure lightdm to allow manual logins in Ubuntu 14.04 for more information about this.

Byte Commander
  • 110,243