使用多节点设置和lightdm进行虚拟终端切换

我的目标是为我的Ubuntu机器安装两个座位。 其中一个显示器是Mimo的USB触摸屏,带有displaylink芯片。 我已经通过重新配置xorg.conf使其成为主显示器。 甚至触摸界面也能工作。

但对于multiseats来说,改变xorg.conf还不够,因为还必须启动其他登录屏幕。 这必须进入lightdm配置。

通过为multiseats配置lightdm(lightdm.conf),我设法启动了两个X实例,每个实例为ServerLayout(xorg.conf)。 一个在虚拟终端7(VT7)上运行,一个在VT8上运行。 众所周知,您可以使用快捷键Ctrl + Alt + Fx(其中x是终端号)在虚拟终端之间切换。

现在的问题是:默认情况下,VT7已启用且VT8已禁用。 但是当我切换到VT8时,它会启用但VT7会被禁用。

如何使两个X Server终端/服务器并行运行?

谢谢。

这是我的lightdm.conf

[SeatDefaults] greeter-session=unity-greeter user-session=ubuntu [Seat:0] xserver-layout=default [Seat:1] xserver-layout=displaylink 

这里只是我的xorg.conf的相关部分:

 # Two Server Layouts Section "ServerLayout" Identifier "default" Screen 0 "Screen0" 0 0 InputDevice "Mouse0" "CorePointer" InputDevice "Keyboard0" "CoreKeyboard" EndSection Section "ServerLayout" Identifier "displaylink" Screen "DisplayLinkScreen" InputDevice "Mouse1" EndSection # Two Screens Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" SubSection "Display" Viewport 0 0 Depth 24 EndSubSection EndSection Section "Screen" Identifier "DisplayLinkScreen" Device "DisplayLinkDevice" Monitor "DisplayLinkMonitor" SubSection "Display" Depth 24 Modes "800x480" EndSubSection EndSection # Two Monitors Section "Monitor" Identifier "Monitor0" VendorName "Monitor Vendor" ModelName "Monitor Model" EndSection Section "Monitor" Identifier "DisplayLinkMonitor" EndSection # Two Graphics Cards/Interfaces Section "Device" Identifier "Card0" Driver "nvidia" BusID "PCI:1:0:0" EndSection Section "Device" Identifier "DisplayLinkDevice" driver "displaylink" Option "fbdev" "/dev/fb1" EndSection # Three Input Devices (the last is touchscreen of the USB monitor) Section "InputDevice" Identifier "Keyboard0" Driver "kbd" EndSection Section "InputDevice" Identifier "Mouse0" Driver "mouse" Option "Protocol" "auto" Option "Device" "/dev/input/mice" Option "ZAxisMapping" "4 5 6 7" EndSection Section "InputDevice" Identifier "Mouse1" Driver "mouse" Option "Device" "/dev/input/by-path/pci-0000:00:1d.7-usb-0:1.3:1.0-event" EndSection 

重读https://help.ubuntu.com/community/MultiseatX下的wiki条目,我想你应该看看如何调用X; 例如, -sharevts-novtswitch命令行选项应以某种方式传递给lightdm.conf中的lightdm.conf

如果您有工作状态,请考虑将Wiki条目更新为11.10。

谢谢你的提示。 -sharevts开关是关键。 Lightdm默认不添加它。 我查看了/var/log/lightdm/lightdm.log并添加了一个自定义的xserver-command选项,现在它终于可以工作了! 谢谢你的帮助。

我最后的lightdm.conf:

 [SeatDefaults] greeter-session=unity-greeter user-session=ubuntu [Seat:0] xserver-layout=default xserver-command=/usr/bin/X :0 -layout default -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch -sharevts [Seat:1] xserver-layout=displaylink xserver-command=/usr/bin/X :1 -layout displaylink -auth /var/run/lightdm/root/:1 -nolisten tcp vt8 -novtswitch -sharevts 

我认为第二个座位应该有一组单独的ttys,第二个X服务器应该在其中一个上运行。 在查看内核控制台代码之后,似乎它是在假设只有一个控制台的情况下编写的。 它使用全局变量将虚拟控制台多路复用到单个显示器上,并从所有连接的键盘读取键盘输入。

看起来Linux控制台代码需要显着重构才能支持多席位。