[root@host02 ~]# vncservice You will require a password to access your desktops. Password: Verify: xauth: creating new authority file /root/.Xauthority New 'host02:1 (root)' desktop is host02:1 #我没设置过密码 这里需要设置密码 [root@host02 ~]# export DISPLAY=host02:2 #根据上面的结果 设置DISPLAY [root@host02 ~]# xhost + access control disabled, clients can connect from any host