首先安装vncviewer
之后在服务器输入你想要开启的·端口号
conda deactivatevncserver :88
VNC Server这里写
你的服务器地址:5900+端口号
如果出现以下问题,可能是配置文件的问题
进入/home/huhao/.vnc文件夹中
conifg配置文件为
## Supported server options to pass to vncserver upon invocation can be listed## in this file. See the following manpages for more: vncserver(1) Xvnc(1).## Several common ones are shown below. Uncomment and modify to your liking.### securitytypes=vncauth,tlsvnc# desktop=sandbox# geometry=2000x1200# localhost# alwaysshared
xstartup为
#!/bin/shunset SESSION_MANAGERunset DBUS_SESSION_BUS_ADDRESS/etc/X11/xinit/xinitrc# Assume either Gnome will be started by default when installed# We want to kill the session automatically in this case when user logs out. In case you modify# /etc/X11/xinit/Xclients or ~/.Xclients yourself to achieve a different result, then you should# be responsible to modify below code to avoid that your session will be automatically killedif [ -e /usr/bin/gnome-session ]; then vncserver -kill $DISPLAYfi
ubuntu:vncserver :86 -geometry 1920x1080 -localhost no
来源地址:https://blog.csdn.net/weixin_48262500/article/details/127076275