没有设置X11 DISPLAY变量,但是该程序执行了需要使用Putty进行的操作? [关闭]

问题描述 投票:2回答:1

我正在使用Putty连接到远程运行的服务器。为了监视服务器,我在腻子终端下输入了jconsole

我在下面的异常中得到了这个。

[[email protected] ~]$  jconsole
Exception in thread "AWT-EventQueue-0" java.awt.HeadlessException:
No X11 DISPLAY variable was set, but this program performed an operation which requires it.
        at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
        at java.awt.Window.<init>(Window.java:432)
        at java.awt.Frame.<init>(Frame.java:403)
        at javax.swing.JFrame.<init>(JFrame.java:202)
        at sun.tools.jconsole.JConsole.<init>(JConsole.java:97)
        at sun.tools.jconsole.JConsole$6.run(JConsole.java:770)
        at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
[[email protected] ~]$

即使我尝试在theis网站之后更改腻子设置。

Getting a HeadlessException: No X11 DISPLAY variable was set

但是我仍然一次又一次地遇到相同的异常,请让我知道如何解决这个问题?

linux x11 putty display
1个回答
-1
投票

在本地计算机上安装X服务器,并按照另一个问题中的说明启用X转发。

© www.soinside.com 2019 - 2024. All rights reserved.