Setting up Linux Mint Mate edition for remote desktop using xRDP
Note that xRDP allows you to create a new session, but does not connect to an existing graphical session. For that you need VNC.
xRDP also doesn't allow for being logged in locally and remotely at the same time. Log out of the local session before trying to log in remotely.
sudo apt install xrdp
sudo apt remove dbus-user-session
sudo apt install dbus-x11
Check to see if it is running:
sudo systemctl status xrdp
Making changes to the configuration
sudo nano /etc/xrdp/startwm.sh
Add your changes before the test and exec lines.
sudo systemctl restart xrdp
sudo systemctl status xrdp
Some people have problems after login and add the following:
unset DBUS_SESSION_BUS_ADDRESS
unset XDG_RUNTIME_DIR