$ cat /etc/ssh/sshd_config | grep X11 X11Forwarding yes ←x11転送を許可 X11DisplayOffset 10 ←擬似xサーバのディスプレイ番号が :10 から始まる
/.ssh/config
Host * Compression yes CompressionLevel 9 TCPKeepAlive yes Ciphers blowfish-cbc,arcfou
$ ssh -X -l <user-name> <remote-host>
$ echo $DISPLAY
$ DISPLAY=<DISPLAY_ID> <X-app-to-be-started>→ remote で起動された X アプリケーションの画面が、 local の画面に表示される
field | description | for example |
---|---|---|
"Remote host*" | 接続先ホストを指定 | 192.168.0.3 |
"Specify username" | 接続時のユーザ名 | - |
field | description | for example |
---|---|---|
"Execute command:" | 何らかのプログラムを自動で起動したい場合に設定 | /usr/bin/gnome-terminal |
"Remote environment:" | WindowManager やデスクトップ環境を起動したい場合に設定(プルダウンから選択) | Gnome desktop |
ex.) 127.0.0.1:0 # localhost で X server を起動、 ディスプレイ番号が :10 の場合であってもこうする。なぜそうなのかは未調査。
$ ssh -X -l <username> <host-name-or-IP-address>
$ Xnest :10 -geometry 1900x1024+0+0 $ DISPLAY=:10 jwm & # WindowManager "jwm" を起動する場合