我的电脑是windows 10 ,我通过virtualbox安装了ubuntu 18.04。
我想从我的窗口和图形输出在 ubuntu 中运行一个python 程序。
但是运行程序后,它总是报告:
Could not find ':' in DISPLAY: needs-to-be-defined
Unable to init server: Could not connect: Connection refused
(Original:2079): Gtk-WARNING **: 14:39:33.441: cannot open display: 127.0.0.1:10.0
我做了什么:
1:我在/etc/ssh/sshd_config
开启时做了设置:
ForwardX11 yes
ForwardX11Trusted yes
2:登录:ssh username@pc-name -X
3:更改IP地址:
$ export DISPLAY=127.0.0.1:10.0 # original was localhost:10.0
你知道,怎么了?为什么我看不到图片?