View Single Post
Old 12-16-08, 09:27 PM   #7
Registered User
Join Date: Jul 2005
Location: Munich
Posts: 910
Default Re: Building a multi-seat Xorg configuration with a dual head card


There are plenty of success reports with solutions built on xephyr,
even including (accelerated?) OpenGL, i.e.:

Unfortunately, there is no good single resource on that topic. Most
documentation seems to be pretty outdated and things seem to
be distribution specific.

Here's how i got at least something working on my machine using Fedora 8:

The following procedure allows to open a xephyr window while a user
session is already in progress. This is very handy, i.e. if your girl friend
walks in while your are working on all available displays and she likes to
do something on your computer. So you can "evacuate" one display and
place xeyphr into it instead, so she has her own work space with separate
mouse and keyboard :-)

1. Download the Xephyr package for Debian Lenny, unpack it and install Xephyr:

     ar -x xserver-xephyr_1.4.2-9_i386.deb
     tar -xzf data.tar.gz
     cp ./usr/bin/Xephyr /usr/local/bin/Xephyr
     chmod u+s /usr/local/bin/Xephyr
2. Make sure that your currently running (main) X-Server is not using the mouse and
keyboard that are intended to be used with Xephyr. I did this by specifying the
keyboard and mouse to be used with the "main/real" X-Server with the following
entries in my xorg.conf:

Section "InputDevice"
    Identifier     "Keyboard0"
    Driver         "evdev"
    Option         "Phys"         "usb-0000:00:0b.0-4.3/input0"
    Option         "XkbRules"     "xorg"
    Option         "XkbModel"     "evdev"
    Option         "XkbLayout"    "de"
    Option         "XkbVariant"   "nodeadkeys"

Section "InputDevice"
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol"        "IMPS/2"
    Option         "Device"          "/dev/input/by-path/pci-0000:00:0b.0-usb-0:4.2:1.0-mouse"
    Option         "ZAxisMapping"    "4 5"
    Option         "Emulate3Buttons" "no"

Section "ServerLayout"
    Identifier     "Layout0"
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0"    "CorePointer"
    Screen 0       "Screen0" 0 0
Where the the available keyboards and mice can be detected with

cat /proc/bus/input/devices | grep -B 5 kbd
cat /proc/bus/input/devices | grep -B 5 mouse

3. Run Xephyr from a console

xauth add :1 . e35a4dd7ad107110869f6972fa8326ad
xinit /usr/local/bin/fvwm95 -- /usr/local/bin/Xephyr :1 -screen 1280x1024 \
-fp /usr/share/X11/fonts/misc,/usr/share/X11/fonts/100dpi,/usr/share/X11/fonts/75dpi,/usr/share/X11/fonts/TTF,/usr/share/X11/fonts/Type1 \
-mouse evdev,,device=/dev/input/by-path/pci-0000:00:0b.0-usb-0:8:1.0-event-mouse,5 \
-keybd evdev,,device=/dev/input/by-path/pci-0000:00:0b.0-usb-0:3.1:1.0-event-kbd,xkbrules=xorg,xkbmodel=evdev,xkblayout=us \
+extension GLX
(where "/usr/local/bin/fvwm95" is my preferred window manager - YMMV)

However, it's not yet working perfectly for me:

* The mouse wheel is not yet working inside xephyr
* some fonts are missing (font path missing?)
* 3D is not working (i guess it is necessary to re-compile xephyr)
* It would be nice to start as different user

If you like to have a "static" multi-seat setup, where a display is always
bound to a different user session, i guess you need to setup gdm accordingly,
like it is described, here (didn't yet tried it out myself, yet):


JaXXoN is offline   Reply With Quote