Topic: Can I run startx multi times to start multipy desktop like gdm?

startx have many parameters, and I've tried this after the first startx:

startx -- :1.0

It really open a new windows and can display the mouse pointer, and I can move it. But the desktop can't start. It always said that 'connection to ":1.0" refused by server'.

Re: Can I run startx multi times to start multipy desktop like gdm?

What you want to do should work just fine. The error message you get indicates that your DISPLAY variable is set correctly too, so I'm not sure what the problem is. Can you give more details about which commands you're running and where (console? xterm? Which X server?) you're running them?

For me, the following works fine:
(in X server on :0, xterm 1: startx -- :1 - starts up second X server on :1
(in X server on :0, xterm 2: env DISPLAY=:1 xclock - xclock is displayed on second X server

Two more things: since startx executes your ~/.xinitrc, you could also put the commands to launch your desktop environment in there. And if you switch to KDE, you'll find the entry "Swich User > Start New Session" which automates all of this and launches a second KDE session in a second X server.

Re: Can I run startx multi times to start multipy desktop like gdm?

I'm not very clear about the display number so it seems I made a mistake. This one works:

startx -- :1

But with KDE I still have a problem. In my .xinitrc:
export LANG=zh_CN.UTF-8
exec startkde

I can display Chinese and some programs say the Terminal is also Chinese version, but the KDE environment itself is still English version. For GNOME this work  well, I can control the language of it.

By the way, when using startx instead of GDM, the 'switch user' can't work, just no response, no prompt. But with GDM, it seems that 'switch user' can only start a GNOME session.

Re: Can I run startx multi times to start multipy desktop like gdm?

Did you install the chinese/kde3-i18n-zh_CN port? After that, you'll need to select the language in the KDE control center. Start kcontrol, go to "Regional & Accessibility" -> "Country/Region" and click on "Add Language" to select chinese. The language that is listed at the top is the default language, the other one is a fallback. You can switch all of KDE to chinese by putting chinese at the top here. Or you can switch individual KDE applications to chinese by opening the Help menu and selecting "Switch application language..." (This setting will be persistant.)

It appears that KDE ignores the LANG environment variable in favor of the control center settings. I don't know if there's a way to change this behaviour.

As for figuring out why startkde doesn't work in the second session, put 'exec xterm' into your .xinitrc and run startkde in there. That way you'll see any error messages.

Re: Can I run startx multi times to start multipy desktop like gdm?

I've already have kde3-i18n-zh_CN port installed, and it works. Thanks a lot.