How to open a second X session in Linux

There are some situations when you need to start a second X session on your computer.

If you are running KDE the solution is quite simple, just go to

K->Leave->Switch User

and if you are not using KDE, the solution is still easy :),

Hit ALT+CTRL+F2

and log in the new terminal window, now run inside it.

xinit -- :1

A new X session will start, now you can switch between them using

ALT+CTRL+F7, F8

You can also start a third one, using the third terminal, and so on.

Another way is to run

startx -- :1

Instead of xinit, be sure to use :2 or :3 when :1 was already used, to start multiple X sessions.

Comments

Last week I delivered a talk titled "MySQL and Search at Craigslist" as part of the 2009 MySQL Conference and Expo. I talked about some of the good and bad of our MySQL work and also talked a lot about our recent Sphinx deployment. The slides are embedded below and here, thanks to SlideShare. (Anyone know why Google Docs doesn't yet handle OpenOffice presentations?) MySQL And Search At CraigslistView more presentations from jzawodn. I gave a copy to O'Reilly but...