Xmanager远程连接CentOS7

Xmanger官网博客得知:

“Gnome in CentOS 7 tries to use local hardware acceleration and this becomes a problem when trying to connect remotely using XDMCP. To avoid this problem, you have to use an alternative display manager (other than ‘gdm’) and desktop environment.”
“This guide explains how you can change the display manager to lightdm from gdm and desktop environment from Gnome to Xfce.”

这就是使用Xfce而不用gdm的原因(仅限CentOS7),嗯,不懂的可以百度一下。

参考:
http://blog.netsarang.com/89/connecting-to-centos-7/
http://blog.csdn.net/lic95/article/details/48948099
http://blog.csdn.net/wuzhimang/article/details/51523867

安装epel源

yum install -y epel-release
  • 1

这里写图片描述

安装lightdm和xfce

yum install -y lightdm 
yum groupinstall -y xfce
  • 1
  • 2

这个下的有点慢
这里写图片描述

修改配置文件

vim /etc/lightdm/lightdm.conf
...
[XDMCPServer]
enabled=true
port=177
...
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6

将Display Manager切换为lightdm

systemctl disable gdm && systemctl enable lightdm
  • 1

启动lightdm

systemctl start lightdm
  • 1

关闭防火墙

systemctl stop firewalld.service
  • 1

登录

打开Xmanger客户端,选择XDMCP并输入服务器的ip,回车运行即可。
这里写图片描述
输入账号密码
这里写图片描述
然后就出现下图:(如果正常跳过这步)
这里写图片描述
这是因为刚开始安装的是Gnome,所以系统默认使用它,现在要改成Xfce,最简单的方法就是把xfce.desktopz之外的文件都干掉。

cd /usr/share/xsessions/
mkdir bak
mv gnome* bak
systemctl restart lightdm   
  • 1
  • 2
  • 3
  • 4

重新连接

一切正常操作之后就成功连接了。然后就可以快速便捷的工作了。
这里写图片描述

猜你喜欢

转载自blog.csdn.net/cdc811/article/details/80056421