2017-07-19 391 views
0

我使用cygwin将我的Windows 7计算机连接到基于Linux的群集。在集群中的特定节点中,我想启动anaconda spyder gui。在cygwin中启动anaconda spyder gui

推出的Spyder你只需键入:

spyder到cygwin的

但返回:

QXcbConnection: Could not connect to display 
Aborted (core dumped) 

我也试过:

QTA_QPA_PLATFORM=offscreen spyder 

但返回:

QFontDatabase: Cannot find font directory /home/spotter/anaconda2/lib/fonts - is Qt installed correctly? 

我安装QT4开发的工具,但它并没有改变任何东西

编辑:

我安装了xinit的和xorg和我现在试试这个:

使用ssh我运行登录前:

export DISPLAY=localhost:0.0 

然后我使用SSH登录:

ssh -Y -X [email protected] 

,现在当我尝试使用spyder我得到:

connect localhost port 6000: Connection refused 
QXcbConnection: Could not connect to display localhost:11.0 

回答

0

对我来说,我所做的就是:

  1. 安装用startx
  2. 更改sshd_config文件,让X11相关的包转发
  3. export DISPLAY=localhost:0.0
  4. startx
  5. 登录与ssh -Y -X [email protected]
  6. spyder
0

所以,它听起来就像你是在本地Windows机器上运行的Cygwin,登录远程服务器ssh,并从该机器有它的意图运行spyder显示在您的本地屏幕上。现在您有startx工作,您接近解决方案。

在步骤5和6之间,需要在远程机器上运行export DISPLAY命令,并将其设置为本地计算机的名称。你需要知道你的主机名。步骤如下所示:

startx 
ssh -Y -X [email protected] 
export DISPLAY=win-machine-name:0.0 
spyder 

最后两个命令在远程机器上执行。我刚刚编造了win-machine-name。取而代之,你将把你的Windows机器的IP地址或机器名称。这就是你如何告诉在远程机器上设置DISPLAY环境变量,因此X客户端知道在哪里发送图形命令。

希望这会有所帮助!