|

楼主 |
发表于 2008-7-31 00:32:49
|
显示全部楼层
Post by lazyfai;1880440
你是用 ssh 吗? 如果是的话, ssh -Y user@hostname 登陆,然后就可以直接回传 X 程序的输出过来了,如果不是 ssh, 就要先在本地端 "xhost +" 一下,然后登陆服务器,在 tcsh 里面用 setenv 设定 DISPLAY 变量为 本地机IP:0 (bash 用 export DISPLAY=本地机IP:0)
多谢兄弟,好使。我整理了一下:
Q022. How can I open the server GUI display on local X11 display (using SSH terminal or not)?
A022.
Enables trusted X11 forwarding.
Case A: Local is Linux, using SSH to connect to the server
##########################################################
- ssh -Y user@hostname
Case B: Local is Windows, using PuTTY (SSH) to connect to the server
##########################################################
(1) Install Xming server (http://www.straightrunning.com/XmingNotes/);
(2) Turn on the Xming server from "Start --> Xming --> Xming";
(3) Run PuTTY and configure it as:
a) Session --> Host Name (or IP address), Port: 22
b) Session --> Connection type: SSH
c) Connection --> SSH --> X11 --> Enable X11 forwarding: Checked
(4) Done.
Case C: Local is Linux, using non-SSH to connect to server
##########################################################
local > xhost +
local > (connect to user@hostname using non-SSH)
server-tcsh > setenv DISPLAY LocalIP:0
OR:
server-bash > export DISPLAY=LocalIP:0
More see also:
http://www.peterlee.com.cn/blog.php?getArticleID=53 |
|