# Edit the xrdp init file
sudo vim /etc/xrdp/xrdp.ini
# Add this at the bottom
[xrdp1]
name=sesman-Xvnc
lib=libvnc.so
username=
password=ask
ip=127.0.0.1
port=ask-1

# For local or distributed Users, edit this file
sudo vim /etc/pam.d/xrdp-sesman
# Add this line at the bottom 
session required pam_limits.so

# For users of xRDP same session management
sudo vim /etc/pam.d/common-session
# Add this line at the bottom
session required pam_limits.so