4

I am running an Ubuntu 12.04 system. While I am logged in using the i3 window manager how is it possible to login as another user (perhaps using a different window manager) without losing my i3wm session?

This is something I can easily do when I am using Unity (and then use Ctrl+F7 and Ctrl+F8 to switch between the two users) but I haven't figured a way to do this from i3wm.

Marcus Junius Brutus
  • 4,587
  • 11
  • 44
  • 65

2 Answers2

6

You can ask your display manager to handle this, for instance:

  • lxdm: lxdm -c USER_SWITCH
  • lightdm: dm-tool switch-to-greeter
  • gdm: gdmflexiserver
  • kdm: kdmctl reserve

via edgardcastro on Reddit

So on Ubuntu 16.04 (that is i3 over LightDM), you could bind the following shortcut:

bindsym $mod+Shift+l exec dm-tool switch-to-greeter
Raphael
  • 2,055
4

This doesn't really have anything to do with your window manager.

From any window manager, you can switch to a different TTY with ctrl + alt + f{1-8}, login as a user, and start a new graphical session (e.g. with startx).

jayhendren
  • 8,384
  • 2
  • 33
  • 58
  • When I try to do that I get: Fatal Server Error: Server is already active for display 0 – Marcus Junius Brutus Nov 08 '16 at 21:12
  • Try startx -- :1. This tells startx to open the new server on display 1 By default startx tries to start any new session on display 0, which is already occupied by the original session. Hence the error message. – Adaephon Nov 09 '16 at 09:52
  • 1
    yes, doing that started what looked like another Unity session in tty-8 but it wasn't functional (I couldn't see the dash, couldn't start a terminal window with Ctrl+Atl+T, etc.). It seems that the issue is more complicated: http://askubuntu.com/q/416825/89663 but I am upvoting the answer as it pointed to the right direction. – Marcus Junius Brutus Nov 12 '16 at 06:08