マルチシート設定と lightdm による仮想端末切り替え

マルチシート設定と lightdm による仮想端末切り替え

私の目標は、Ubuntu マシンに 2 つのシートを用意することです。モニターの 1 つは、ディスプレイリンク チップを搭載した Mimo の USB タッチスクリーンです。xorg.conf を再設定するだけで、メイン ディスプレイとして動作しています。タッチ インターフェイスも動作します。

しかし、マルチシートの場合は、追加のログイン画面も起動する必要があるため、xorg.conf を変更するだけでは不十分です。これは lightdm 構成に含める必要があります。

lightdm をマルチシート用に構成することで (lightdm.conf)、ServerLayout (xorg.conf) ごとに 1 つずつ、合計 2 つの X インスタンスを起動することができました。1 つは仮想ターミナル 7 (VT7) で実行され、もう 1 つは VT8 で実行されます。よく知られているように、仮想ターミナルはショートカット Ctrl + Alt + Fx (x はターミナル番号) を使用して切り替えることができます。

ここで問題となるのは、デフォルトでは VT7 が有効で、VT8 が無効になっていることです。しかし、VT8 に切り替えると、VT8 は有効になりますが、VT7 は無効になります。

両方の X サーバー端末/サーバーを並行して実行するにはどうすればよいですか?

ありがとう。

これが私の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

答え1

ウィキペディアのエントリを再度読み直すとhttps://help.ubuntu.com/community/MultiseatX、X がどのように呼び出されるかを確認したほうがよいと思います。たとえば、-sharevtsおよび-novtswitchコマンドライン オプションは、 で何らかの方法で X に渡されるはずですlightdm.conf

動作状態がある場合は、Wiki エントリを 11.10 に更新することを検討してください。

答え2

ヒントをありがとうございます。-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

答え3

2 番目のシートには別の tty セットを用意し、2 番目の X サーバーをその 1 つで実行する必要があると思います。しかし、カーネル コンソール コードを見ると、コンソールが 1 つしかないという前提で記述されているようです。グローバル変数を使用して仮想コンソールを 1 つのディスプレイに多重化し、接続されているすべてのキーボードからキーボード入力を読み取ります。

マルチシートをサポートするには、Linux コンソール コードを大幅にリファクタリングする必要があるようです。

関連情報