安装X11和Gnome
1 2
| yum groupinstall "X Window System" yum groupinstall "GNOME Desktop"
|
切换启动模式
1 2
| systemctl set-default multi-user.target //设置成命令模式 systemctl set-default graphical.target //设置成图形模式
|
远程访问并启动X
1 2 3 4
| ssh -Y root@10.211.55.11 startx 或 systemctl start gdm
|
TigerVNC安装
yum install tigervnc tigervnc-server
设置vnc密码
TigerVNC配置
1 2 3 4
| cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@:1.service
vi /etc/systemd/system/vncserver@\:1.service 将<USER>替换
|
TigerVNC启动
1 2 3 4
| systemctl daemon-reload systemctl start vncserver@:1 systemctl status vncserver@:1 systemctl enable vncserver@:1
|
VNC以590+x作为访问端口,第1个server是5901端口
macOS访问VNC
原生支持VNC访问,Finder中cmd+k,弹出窗口中输入
vnc://10.211.55.11:5901