安裝遠端桌面管理軟體:
配置遠端桌面登入環境:$ sudo apt-get install xfce4 $ sudo apt-get install xrdp
啟動 xrdp 服務:This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
$ echo xfce4-session > ~/.xsession $ sudo vi /etc/xrdp/startwm.sh ... if test -r /etc/profile; then . /etc/profile fi startxfce4 test -x /etc/X11/Xsession && exec /etc/X11/Xsession exec /bin/sh /etc/X11/Xsession
確認服務正常運行:$ sudo service xrdp restart
在 Windows 執行遠端桌面連線 (mstsc) 連上 Ubuntu:$ netstat -na | grep 3389 tcp6 0 0 :::3389 :::* LISTEN如果是在 Ubuntu 是安裝在 Windows Subsystem for Linux, 並不會出現上述內容, 但仍可以正常運作.
參考文章: Ubuntu 安裝可讓 Windows 遠端桌面登入的 xrdp