How to permanently disable user switching in Gnome 3?

Solution 1:

This is for Gnome 3 (aka gnome-shell, NOT Unity), and will disable both the "Switch User" option in the user menu as well as on the lock screen:

  • Start the terminal with Ctrl-Alt-T, and then type:

    1. sudo apt-get install dconf-tools
    2. Start dconf-editor
    3. Disable apps->indicator-session->user-show-menu:

    enter image description here

  • Enable org->gnome->desktop->lockdown->disable-user-switching:

    enter image description here

  • Close dconf-editor, logout and log in to see the changes.

Solution 2:

Another way to do this would be using the 'dconf editor'.
You can install it from software center.
After opening it click on 'apps' -> 'indicator session' and uncheck 'user-show-menu'.
Close the program and log out and back in.

View of the dconf editor