centos6.5 yum update之后vnc报错unable to open display "localhost:1"

Sat Sep 10 09:58:11 2016
 vncext:      VNC extension running!
 vncext:      Listening for VNC connections on all interface(s), port 5901
 vncext:      created VNC server for screen 0
vncconfig: unable to open display "localhost:1"
vncconfig: unable to open display "localhost:1"
xrdb: Bad file descriptor
xrdb: Can't open display 'localhost:1'

xmodmap:  unable to open display 'localhost:1'


yum update 以后就变成这样了,改一下


把/root/.vnc/xstartup里面


export DISPLAY=localhost:1


改成

export DISPLAY=:1


重启vncserver就好了


你可能感兴趣的:(文章)