环境:Ubuntu 12.04 LTS
工具:GDM
第一步:
sudo apt-get install gdm
第二步:
编辑文件
1、sudo gedit /usr/share/doc/gdm/examples/custom.conf
(在Ubuntu 14.04 LTS中为/etc/gdm/custom.conf)
添加
[security]
DisallowTCP=false
#允许用root用户进行远程连接
AllowRemoteRoot=true
[xdmcp]
Enable=true
Port=177
#设置连接数量
DisplaysPerHost=10
2、sudo gedit /usr/share/gdm/gdm.schemas
修改xdmcp/Enable字段:
<schema>
<key>xdmcp/Enable</key>
<signature>b</signature>
<default>true</default>
</schema>
3、Open port udp 177(开启177端口):
sudo ufw allow 177
4、Reboot the system(重启gdm):
sudo /etc/init.d/gdm restart
第三步:
要在 Ubuntu 12.04 中启用 xdmcp 服务器是一件相对比较容易的事情,还需运行命令
sudo vi /etc/lightdm/lightdm.conf
并在 lightdm.conf 文件末尾添加下述内容即可:
[XDMCPServer]
enabled=true
修改完成之后重启系统就可以使用 xmanager 来远程登录了。
附:
1.Ubuntu下轻松切换GDM, LightDM , KDM
sudo dpkg-reconfigure gdm
2.路径问题:
以上设置在Ubuntu 12.04 LTS中按步骤操作即可正常使用,其它linux版本尚未做验证。
参考文章:
1.《Ubuntu 12.04 Xmanager 配置》;
2.《Xmanger 远程桌面Ubuntu 12.04LTS》;
3.《Ubuntu下轻松切换GDM, LightDM , KDM》;