拒绝从命令行访问 X 服务器

拒绝从命令行访问 X 服务器

我刚刚安装了 Ubuntu 15.04 和 Gnome 3 桌面环境。如果我尝试从命令行运行 GUI 程序(例如 Gedit),我会得到:

XXXXX:~$ gedit 
No protocol specified

** (gedit:3299): WARNING **: Could not open X display
No protocol specified
gdk_mir_display_open
Failed to connect to Mir: Failed to connect to server socket: No such file or directory
Unable to init server: Could not connect: Connection refused

(gedit:3299): Gtk-WARNING **: cannot open display: :0

But, if I launch gedit from the  gnome "search" window, it comes up fine.
I have some custom GUIs I use and I typically start them from the command line.

附言:由于 Nvidia 硬件问题,我无法使用 Ubuntu 桌面环境。

相关内容