Xrdp 是一个微软
远程桌面协议(RDP)的开源实现,支持通过图形界面控制远程 Linux 系统
安装
安装 ubuntu desktop
sudo apt install ubuntu-desktopubuntu desktop 远程软件:
sudo apt install xrdp xorgxrdp- 配置
- 配置文件
/etc/xrdp/xrdp.ini - Xrdp 使用
/etc/ssl/private/ssl-cert-snakeoil.key,它仅仅对ssl-cert用户组成语可读,将 xrdp 用户添加到这个用户组
- 配置文件
sudo adduser xrdp ssl-cert使用
- 启动服务,监听在
3389端口
sudo systemctl enable xrdp
sudo systemctl restart xrdp- 链接
- Windows:搜索栏输入
remote,点击Remote Desktop Connection - Mac 使用软件
Windows App for Mac(原名Microsoft Remote Desktop) - Ubuntu 使用软件
Remmina或者Vinagre
- Windows:搜索栏输入
F&Q
xrdp_wm_log_msg: login failed for display 0
- 在
/var/log/xrdp.log看到如上错误日志 - 创建
/etc/xrdp/xrdp.ini中配置的用户:
sudo useradd -m ask
adduser ask sudo
passwd ask
$ sudo vi /etc/sudoers
ask ALL=(ALL) ALLask 用户登录黑屏
日志文件 /home/ask/.xorgxrdp.10.log 错误
[ 211.842] (EE) Please also check the log file at ".xorgxrdp.10.log" for additional information.
[ 211.842] (EE)
[ 211.842] (WW) xf86CloseConsole: KDSETMODE failed: Bad file descriptor
[ 211.842] (WW) xf86CloseConsole: VT_GETMODE failed: Bad file descriptor
[ 211.847] (EE) Server terminated with error (1). Closing log file.- 解决
sudo apt install xorgxrdp