neutrinolabs / xrdp

xrdp: an open source RDP server
http://www.xrdp.org/
Apache License 2.0
5.75k stars 1.73k forks source link

Resume existing session via MS RDP #2565

Closed KiLLeRRaT closed 1 year ago

KiLLeRRaT commented 1 year ago

Hi,

Sorry that I have to create yet another "existing session" or "same session" issue.

I have tried to connect to existing desktop sessions from Windows to my Manjaro machine to no avail.

I have tried using clean installs of Manjaro i3, as well as Manjaro XFCE.

Is this at all possible somehow? I'm happy to start listing all my versions and configs, but first I just want to find out if this should be at all possible.

I use my machine in such a way that I have all my applications and things open, then I leave the office to work remotely from a laptop (Windows, MacOS, OR Linux), and I want to be able to RDP using MSTSC from a Windows machine, and continue working on my machine at home with all my things still open.

I'm very hopeful, but I've tried a bunch of guides and such. If someone can answer whether this is possible, then I can start providing versions and configs.

At a high level, it's a clean install, and then installing xrdp, and xorgxrdp, enabling and starting the services for both these, then doing things like removing --exist-with-session from the ~/.xinitrc file, and a couple of other things I've read by following guides. None of these things lets me use my existing desktop session.

Thanks for your time, I also appreciate all the effort that goes into this project.

Regards, Albert

matt335672 commented 1 year ago

Not only is it possible, but it should be default behaviour. Your use-case is one I used to use myself quite a few years back.

There are a couple of possibilities here. First of all, if you're at work and you disconnect from your session, can you reconnect to it immediately?

KiLLeRRaT commented 1 year ago

Well it's great news that it's possible. I can't for the life of me get it working though. What's the catch?

Here are the steps I've taken

  1. Clean install of Manjaro i3, with a non encrypted BTRFS setup.

  2. Update system pamac update

  3. Install xrdp via pamac build xrdp

  4. Install xorgxrdp via pamac build xorgxrdp. This fails with a PGP key problem One or more PGP signatures could not be verified, so I add the key using sudo gpg --recv-keys 61ECEABBF2BB40E3A35DF30A9F72CDBC01BF10EB and without sudo: gpg --recv-keys 61ECEABBF2BB40E3A35DF30A9F72CDBC01BF10EB.

  5. This still didn't work, so then cloned the AUR package and ran makepkg:

    git clone https://aur.archlinux.org/xorgxrdp.git
    cd xorgxrdp
    makepkg -si
  6. Create /etc/X11/Xwrapper.config and add allowed_users = anybody

  7. Edit ~/.xinitrc a. Change local dbus_args=(–sh-syntax –exit-with-session) to local dbus_args=(–sh-syntax)

    b. Change exec $(get_session “$1”) to exec $(get_session “$DEFAULT_SESSION”). I've tried leaving this line as is also, no difference.

  8. Enable and start services:

    sudo systemctl enable xrdp
    sudo systemctl enable xrdp-sesman
    sudo systemctl start xrdp
    sudo systemctl start xrdp-sesman
    1. When I connect via MS RDP protocol using Remmina on another computer, I get a new session, none of my apps are open.

I have also tried these steps with Manjaro XFCE, same result...

I would be super happy if anyone could help me with this!

Other things I've tried:

I have noticed that I have dbus installed, and mangled my way to install dbus-x11 instead (read about this somewhere), to see if that would work, it made no difference.

Appendix

Versions

manjaro: 22.0.4 kernel: 5.15.94-1-MANJARO

xrdp --version:

xrdp 0.9.21.1
  A Remote Desktop Protocol Server.
  Copyright (C) 2004-2020 Jay Sorg, Neutrino Labs, and all contributors.
  See https://github.com/neutrinolabs/xrdp for more information.

  Configure options:
      --prefix=/usr
      --sysconfdir=/etc
      --localstatedir=/var
      --sbindir=/usr/bin
      --with-systemdsystemunitdir=/usr/lib/systemd/system
      --enable-jpeg
      --enable-tjpeg
      --enable-fuse
      --enable-fdkaac
      --enable-opus
      --enable-rfxcodec
      --enable-mp3lame
      --enable-pixman
      --enable-painter
      --enable-vsock
      --enable-ipv6
      --enable-pam-config=arch
      --enable-rdpsndaudin
      --with-imlib2
      CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection
      LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now

  Compiled with OpenSSL 3.0.8 7 Feb 2023

xorgxrdp: 0.9.19-2-x86_64

~/.xinitrc

#!/bin/bash
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap

DEFAULT_SESSION='i3 --shmlog-size 0'

# merge in defaults and keymaps

if [ -f $sysresources ]; then
    xrdb -merge $sysresources
fi

if [ -f $sysmodmap ]; then
    xmodmap $sysmodmap
fi

if [ -f "$userresources" ]; then
    xrdb -merge "$userresources"
fi

if [ -f "$usermodmap" ]; then
    xmodmap "$usermodmap"
fi

# start some nice programs

if [ -d /etc/X11/xinit/xinitrc.d ] ; then
    for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
        [ -x "$f" ] && . "$f"
    done
    unset f
fi

get_session(){
    #local dbus_args=(--sh-syntax --exit-with-session)
    local dbus_args=(--sh-syntax)
    case $1 in
        awesome) dbus_args+=(awesome) ;;
        bspwm) dbus_args+=(bspwm-session) ;;
        budgie) dbus_args+=(budgie-desktop) ;;
        cinnamon) dbus_args+=(cinnamon-session) ;;
        deepin) dbus_args+=(startdde) ;;
        enlightenment) dbus_args+=(enlightenment_start) ;;
        fluxbox) dbus_args+=(startfluxbox) ;;
        gnome) dbus_args+=(gnome-session) ;;
        i3|i3wm) dbus_args+=(i3 --shmlog-size 0) ;;
        jwm) dbus_args+=(jwm) ;;
        kde) dbus_args+=(startplasma-x11) ;;
        lxde) dbus_args+=(startlxde) ;;
        lxqt) dbus_args+=(lxqt-session) ;;
        mate) dbus_args+=(mate-session) ;;
        xfce) dbus_args+=(xfce4-session) ;;
        openbox) dbus_args+=(openbox-session) ;;
        *) dbus_args+=($DEFAULT_SESSION) ;;
    esac

    echo "dbus-launch ${dbus_args[*]}"
}

#exec $(get_session "$1")
exec $(get_session "$DEFAULT_SESSION")

/etc/X11/Xwrapper.config:

allowed_users = anybody

/etc/xrdp/startwm.sh:

#!/usr/bin/env bash
#
# This script is an example. You might need to edit this script
# depending on your distro if it doesn't work for you.
#
# Uncomment the following line for debug:
# exec xterm

# Execution sequence for interactive login shell - pseudocode
#
# IF /etc/profile is readable THEN
#     execute ~/.bash_profile
# END IF
# IF ~/.bash_profile is readable THEN
#     execute ~/.bash_profile
# ELSE
#     IF ~/.bash_login is readable THEN
#         execute ~/.bash_login
#     ELSE
#         IF ~/.profile is readable THEN
#             execute ~/.profile
#         END IF
#     END IF
# END IF
pre_start()
{
  if [ -r /etc/profile ]; then
    . /etc/profile
  fi
  if [ -r ~/.bash_profile ]; then
    . ~/.bash_profile
  else
    if [ -r ~/.bash_login ]; then
      . ~/.bash_login
    else
      if [ -r ~/.profile ]; then
        . ~/.profile
      fi
    fi
  fi
  return 0
}

# When logging out from the interactive shell, the execution sequence is:
#
# IF ~/.bash_logout exists THEN
#     execute ~/.bash_logout
# END IF
post_start()
{
  if [ -r ~/.bash_logout ]; then
    . ~/.bash_logout
  fi
  return 0
}

#start the window manager
wm_start()
{
  if [ -r /etc/locale.conf ]; then
    . /etc/locale.conf
    export LANG LANGUAGE
  fi

  # arch user
  if [ -r ~/.xinitrc ]; then
    pre_start
    . ~/.xinitrc
    post_start
    exit 0
  fi
  # arch
  if [ -r /etc/X11/xinit/xinitrc ]; then
    pre_start
    . /etc/X11/xinit/xinitrc
    post_start
    exit 0
  fi

  # debian
  if [ -r /etc/X11/Xsession ]; then
    pre_start
    . /etc/X11/Xsession
    post_start
    exit 0
  fi

  # alpine
  # Don't use /etc/X11/xinit/Xsession - it doesn't work
  if [ -f /etc/alpine-release ]; then
    if [ -f /etc/X11/xinit/xinitrc ]; then
        pre_start
        /etc/X11/xinit/xinitrc
        post_start
    else
        echo "** xinit package isn't installed" >&2
        exit 1
    fi
  fi

  # el
  if [ -r /etc/X11/xinit/Xsession ]; then
    pre_start
    . /etc/X11/xinit/Xsession
    post_start
    exit 0
  fi

  # suse
  if [ -r /etc/X11/xdm/Xsession ]; then
    # since the following script run a user login shell,
    # do not execute the pseudo login shell scripts
    . /etc/X11/xdm/Xsession
    exit 0
  elif [ -r /usr/etc/X11/xdm/Xsession ]; then
    . /usr/etc/X11/xdm/Xsession
    exit 0
  fi

  pre_start
  xterm
  post_start
}

#. /etc/environment
#export PATH=$PATH
#export LANG=$LANG

# change PATH to be what your environment needs usually what is in
# /etc/environment
#PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
#export PATH=$PATH

# for PATH and LANG from /etc/environment
# pam will auto process the environment file if /etc/pam.d/xrdp-sesman
# includes
# auth       required     pam_env.so readenv=1

wm_start

exit 1

journalctl -u xrdp:

Feb 28 10:41:01 albert-aspire systemd[1]: Starting xrdp daemon...
Feb 28 10:41:01 albert-aspire xrdp[49939]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:41:01 albert-aspire xrdp[49939]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:41:01 albert-aspire xrdp[49939]: [INFO ] xrdp_listen_pp done
Feb 28 10:41:01 albert-aspire systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
Feb 28 10:41:02 albert-aspire systemd[1]: Started xrdp daemon.
Feb 28 10:41:03 albert-aspire xrdp[49940]: [INFO ] starting xrdp with pid 49940
Feb 28 10:41:03 albert-aspire xrdp[49940]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:41:03 albert-aspire xrdp[49940]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:41:03 albert-aspire xrdp[49940]: [INFO ] xrdp_listen_pp done
Feb 28 10:42:13 albert-aspire xrdp[49940]: [INFO ] Socket 12: AF_INET6 connection received from ::ffff:192.168.111.250 port 54264
Feb 28 10:42:13 albert-aspire xrdp[49954]: [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
Feb 28 10:42:13 albert-aspire xrdp[49954]: [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
Feb 28 10:42:13 albert-aspire xrdp[49954]: [INFO ] Security protocol: configured [SSL|RDP], requested [SSL|HYBRID|RDP], selected [SSL]
Feb 28 10:42:15 albert-aspire xrdp[49954]: [INFO ] Connected client computer name: agouws
Feb 28 10:42:15 albert-aspire xrdp[49954]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
Feb 28 10:42:15 albert-aspire xrdp[49954]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000409]
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [us] options []
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] TLS connection established from ::ffff:192.168.111.250 port 54264: TLSv1.3 with cipher TLS_AES_256_GCM_SHA384
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 7864320 MB cache entries 2000
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
Feb 28 10:42:16 albert-aspire xrdp[49954]: [WARN ] Client Capability: not enough orders supported by client, client wants off screen bitmap but offscreen bitmaps disabled
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
Feb 28 10:42:16 albert-aspire xrdp[49954]: [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
Feb 28 10:42:16 albert-aspire xrdp[49954]: [INFO ] connecting to sesman on 127.0.0.1:3350
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] xrdp_wm_log_msg: sesman connect ok
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] sesman connect ok
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] sending login info to session manager. Please wait...
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] xrdp_wm_log_msg: login successful for user albert on display 10
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] login successful for user albert on display 10
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] loaded module 'libxup.so' ok, interface size 10296, version 4
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] started connecting
Feb 28 10:42:17 albert-aspire xrdp[49954]: [INFO ] lib_mod_connect: connecting via UNIX socket
Feb 28 10:42:18 albert-aspire xrdp[49954]: [INFO ] lib_mod_log_peer: xrdp_pid=49954 connected to X11rdp_pid=49959 X11rdp_uid=1000 X11rdp_gid=1000 client_ip=::ffff:192.168.111.250 client_port=54264
Feb 28 10:42:18 albert-aspire xrdp[49954]: [INFO ] connected ok
Feb 28 10:43:48 albert-aspire xrdp[50193]: stopping xrdp
Feb 28 10:43:48 albert-aspire xrdp[50193]: stopping process id 49940
Feb 28 10:43:48 albert-aspire systemd[1]: Stopping xrdp daemon...
Feb 28 10:43:48 albert-aspire systemd[1]: xrdp.service: Deactivated successfully.
Feb 28 10:43:48 albert-aspire systemd[1]: Stopped xrdp daemon.
Feb 28 10:43:48 albert-aspire systemd[1]: xrdp.service: Consumed 4.805s CPU time.
-- Boot 2d8614bbdd764dcc98f7e477635c393b --
Feb 28 10:44:14 albert-aspire systemd[1]: Starting xrdp daemon...
Feb 28 10:44:15 albert-aspire xrdp[461]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:44:15 albert-aspire xrdp[461]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:44:15 albert-aspire xrdp[461]: [INFO ] xrdp_listen_pp done
Feb 28 10:44:15 albert-aspire systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
Feb 28 10:44:16 albert-aspire systemd[1]: Started xrdp daemon.
Feb 28 10:44:17 albert-aspire xrdp[473]: [INFO ] starting xrdp with pid 473
Feb 28 10:44:17 albert-aspire xrdp[473]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:44:18 albert-aspire xrdp[473]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:44:18 albert-aspire xrdp[473]: [INFO ] xrdp_listen_pp done
Feb 28 10:45:06 albert-aspire xrdp[473]: [INFO ] Socket 12: AF_INET6 connection received from ::ffff:192.168.111.250 port 47660
Feb 28 10:45:07 albert-aspire xrdp[937]: [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
Feb 28 10:45:07 albert-aspire xrdp[937]: [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
Feb 28 10:45:07 albert-aspire xrdp[937]: [INFO ] Security protocol: configured [SSL|RDP], requested [SSL|HYBRID|RDP], selected [SSL]
Feb 28 10:45:07 albert-aspire xrdp[937]: [INFO ] Connected client computer name: agouws
Feb 28 10:45:07 albert-aspire xrdp[937]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
Feb 28 10:45:07 albert-aspire xrdp[937]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000409]
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [us] options []
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] TLS connection established from ::ffff:192.168.111.250 port 47660: TLSv1.3 with cipher TLS_AES_256_GCM_SHA384
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 7864320 MB cache entries 2000
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
Feb 28 10:45:08 albert-aspire xrdp[937]: [WARN ] Client Capability: not enough orders supported by client, client wants off screen bitmap but offscreen bitmaps disabled
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
Feb 28 10:45:08 albert-aspire xrdp[937]: [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] connecting to sesman on 127.0.0.1:3350
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] xrdp_wm_log_msg: sesman connect ok
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] sesman connect ok
Feb 28 10:45:08 albert-aspire xrdp[937]: [INFO ] sending login info to session manager. Please wait...
Feb 28 10:45:09 albert-aspire xrdp[937]: [INFO ] xrdp_wm_log_msg: login successful for user albert on display 10
Feb 28 10:45:09 albert-aspire xrdp[937]: [INFO ] login successful for user albert on display 10
Feb 28 10:45:09 albert-aspire xrdp[937]: [INFO ] loaded module 'libxup.so' ok, interface size 10296, version 4
Feb 28 10:45:09 albert-aspire xrdp[937]: [INFO ] started connecting
Feb 28 10:45:09 albert-aspire xrdp[937]: [INFO ] lib_mod_connect: connecting via UNIX socket
Feb 28 10:45:10 albert-aspire xrdp[937]: [INFO ] lib_mod_log_peer: xrdp_pid=937 connected to X11rdp_pid=942 X11rdp_uid=1000 X11rdp_gid=1000 client_ip=::ffff:192.168.111.250 client_port=47660
Feb 28 10:45:10 albert-aspire xrdp[937]: [INFO ] connected ok
Feb 28 10:45:27 albert-aspire xrdp[937]: [ERROR] xrdp_iso_send: trans_write_copy_s failed
Feb 28 10:45:27 albert-aspire xrdp[937]: [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
Feb 28 10:58:26 albert-aspire systemd[1]: Stopping xrdp daemon...
Feb 28 10:58:26 albert-aspire xrdp[1371]: stopping xrdp
Feb 28 10:58:26 albert-aspire xrdp[1371]: stopping process id 473
Feb 28 10:58:26 albert-aspire xrdp[473]: [INFO ] Received termination signal, stopping the server accept new connections thread
Feb 28 10:58:26 albert-aspire systemd[1]: xrdp.service: Deactivated successfully.
Feb 28 10:58:26 albert-aspire systemd[1]: Stopped xrdp daemon.
Feb 28 10:58:26 albert-aspire systemd[1]: xrdp.service: Consumed 1.103s CPU time.
Feb 28 10:58:26 albert-aspire systemd[1]: Starting xrdp daemon...
Feb 28 10:58:26 albert-aspire xrdp[1380]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:58:26 albert-aspire xrdp[1380]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:58:26 albert-aspire xrdp[1380]: [INFO ] xrdp_listen_pp done
Feb 28 10:58:26 albert-aspire systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
Feb 28 10:58:27 albert-aspire systemd[1]: Started xrdp daemon.
Feb 28 10:58:28 albert-aspire xrdp[1382]: [INFO ] starting xrdp with pid 1382
Feb 28 10:58:28 albert-aspire xrdp[1382]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:58:28 albert-aspire xrdp[1382]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:58:28 albert-aspire xrdp[1382]: [INFO ] xrdp_listen_pp done
Feb 28 10:58:30 albert-aspire systemd[1]: Stopping xrdp daemon...
Feb 28 10:58:30 albert-aspire xrdp[1386]: stopping xrdp
Feb 28 10:58:30 albert-aspire xrdp[1386]: stopping process id 1382
Feb 28 10:58:30 albert-aspire xrdp[1382]: [INFO ] Received termination signal, stopping the server accept new connections thread
Feb 28 10:58:31 albert-aspire systemd[1]: xrdp.service: Deactivated successfully.
Feb 28 10:58:31 albert-aspire systemd[1]: Stopped xrdp daemon.
Feb 28 10:58:31 albert-aspire systemd[1]: Starting xrdp daemon...
Feb 28 10:58:31 albert-aspire xrdp[1390]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:58:31 albert-aspire xrdp[1390]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:58:31 albert-aspire xrdp[1390]: [INFO ] xrdp_listen_pp done
Feb 28 10:58:31 albert-aspire systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
Feb 28 10:58:32 albert-aspire systemd[1]: Started xrdp daemon.
Feb 28 10:58:33 albert-aspire xrdp[1391]: [INFO ] starting xrdp with pid 1391
Feb 28 10:58:33 albert-aspire xrdp[1391]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 10:58:33 albert-aspire xrdp[1391]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 10:58:33 albert-aspire xrdp[1391]: [INFO ] xrdp_listen_pp done
Feb 28 10:58:34 albert-aspire xrdp[1391]: [INFO ] Socket 12: AF_INET6 connection received from ::ffff:192.168.111.250 port 45250
Feb 28 10:58:34 albert-aspire xrdp[1393]: [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
Feb 28 10:58:34 albert-aspire xrdp[1393]: [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
Feb 28 10:58:35 albert-aspire xrdp[1393]: [INFO ] Security protocol: configured [SSL|RDP], requested [SSL|HYBRID|RDP], selected [SSL]
Feb 28 10:58:35 albert-aspire xrdp[1393]: [INFO ] Connected client computer name: agouws
Feb 28 10:58:35 albert-aspire xrdp[1393]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
Feb 28 10:58:35 albert-aspire xrdp[1393]: [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
Feb 28 10:58:35 albert-aspire xrdp[1393]: [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000409]
Feb 28 10:58:35 albert-aspire xrdp[1393]: [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [us] options []
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] TLS connection established from ::ffff:192.168.111.250 port 45250: TLSv1.3 with cipher TLS_AES_256_GCM_SHA384
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 7864320 MB cache entries 2000
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
Feb 28 10:58:36 albert-aspire xrdp[1393]: [WARN ] Client Capability: not enough orders supported by client, client wants off screen bitmap but offscreen bitmaps disabled
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
Feb 28 10:58:36 albert-aspire xrdp[1393]: [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] connecting to sesman on 127.0.0.1:3350
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] xrdp_wm_log_msg: sesman connect ok
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] sesman connect ok
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] sending login info to session manager. Please wait...
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] xrdp_wm_log_msg: login successful for user albert on display 10
Feb 28 10:58:36 albert-aspire xrdp[1393]: [INFO ] login successful for user albert on display 10
Feb 28 10:58:37 albert-aspire xrdp[1393]: [INFO ] loaded module 'libxup.so' ok, interface size 10296, version 4
Feb 28 10:58:37 albert-aspire xrdp[1393]: [INFO ] started connecting
Feb 28 10:58:37 albert-aspire xrdp[1393]: [INFO ] lib_mod_connect: connecting via UNIX socket
Feb 28 10:58:37 albert-aspire xrdp[1393]: [INFO ] lib_mod_log_peer: xrdp_pid=1393 connected to X11rdp_pid=1396 X11rdp_uid=1000 X11rdp_gid=1000 client_ip=::ffff:192.168.111.250 client_port=45250
Feb 28 10:58:37 albert-aspire xrdp[1393]: [INFO ] connected ok
Feb 28 10:58:59 albert-aspire systemd[1]: Stopping xrdp daemon...
Feb 28 10:58:59 albert-aspire xrdp[1628]: stopping xrdp
Feb 28 10:58:59 albert-aspire xrdp[1628]: stopping process id 1391
Feb 28 10:58:59 albert-aspire xrdp[1391]: [INFO ] Received termination signal, stopping the server accept new connections thread
Feb 28 10:58:59 albert-aspire systemd[1]: xrdp.service: Deactivated successfully.
Feb 28 10:58:59 albert-aspire systemd[1]: Stopped xrdp daemon.
Feb 28 10:58:59 albert-aspire systemd[1]: xrdp.service: Consumed 1.336s CPU time.
-- Boot d6e4488bfeb44b7f8ad5a5a890908e5c --
Feb 28 11:01:21 albert-aspire systemd[1]: Starting xrdp daemon...
Feb 28 11:01:22 albert-aspire xrdp[465]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 11:01:22 albert-aspire xrdp[465]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 11:01:22 albert-aspire xrdp[465]: [INFO ] xrdp_listen_pp done
Feb 28 11:01:22 albert-aspire systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
Feb 28 11:01:23 albert-aspire systemd[1]: Started xrdp daemon.
Feb 28 11:01:24 albert-aspire xrdp[477]: [INFO ] starting xrdp with pid 477
Feb 28 11:01:24 albert-aspire xrdp[477]: [INFO ] address [0.0.0.0] port [3389] mode 1
Feb 28 11:01:24 albert-aspire xrdp[477]: [INFO ] listening to port 3389 on 0.0.0.0
Feb 28 11:01:25 albert-aspire xrdp[477]: [INFO ] xrdp_listen_pp done

journalctl -u xrdp-sesman:

Feb 28 10:41:01 albert-aspire systemd[1]: Starting xrdp session manager...
Feb 28 10:41:01 albert-aspire systemd[1]: Started xrdp session manager.
Feb 28 10:41:01 albert-aspire xrdp-sesman[49938]: [INFO ] starting xrdp-sesman with pid 49938
Feb 28 10:42:16 albert-aspire xrdp-sesman[49938]: [INFO ] Socket 12: AF_INET6 connection received from ::1 port 46644
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: pam_systemd_home(xrdp-sesman:auth): systemd-homed is not available: Unit dbus-org.freedesktop.home1.service not found.
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [INFO ] Terminal Server Users group is disabled, allowing authentication
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [INFO ] ++ created session (access granted): username albert, ip ::ffff:192.168.111.250:54264 - socket: 12
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [INFO ] starting Xorg session...
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [INFO ] Starting session: session_pid 49957, display :10.0, width 1228, height 1376, bpp 24, client ip ::ffff:192.168.111.250:54264 - socket: 12, user name albert
Feb 28 10:42:17 albert-aspire xrdp-sesman[49957]: [INFO ] [session start] (display 10): calling auth_start_session from pid 49957
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [ERROR] sesman_data_in: scp_process_msg failed
Feb 28 10:42:17 albert-aspire xrdp-sesman[49957]: pam_unix(xrdp-sesman:session): session opened for user albert(uid=1000) by (uid=0)
Feb 28 10:42:17 albert-aspire xrdp-sesman[49957]: pam_systemd(xrdp-sesman:session): Failed to create session: No child processes
Feb 28 10:42:17 albert-aspire xrdp-sesman[49959]: [INFO ] Starting X server on display 10: Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
Feb 28 10:42:17 albert-aspire xrdp-sesman[49938]: [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans
Feb 28 10:42:18 albert-aspire xrdp-sesman[49958]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:42:18 albert-aspire xrdp-sesman[49957]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:42:18 albert-aspire xrdp-sesman[49958]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:42:18 albert-aspire xrdp-sesman[49957]: [INFO ] Session started successfully for user albert on display 10
Feb 28 10:42:18 albert-aspire xrdp-sesman[49962]: [INFO ] Starting the xrdp channel server for display 10
Feb 28 10:42:18 albert-aspire xrdp-sesman[49958]: [INFO ] Starting the default window manager on display 10: /etc/xrdp/startwm.sh
Feb 28 10:42:18 albert-aspire xrdp-sesman[49957]: [INFO ] Session in progress on display 10, waiting until the window manager (pid 49958) exits to end the session
Feb 28 10:42:18 albert-aspire xrdp-chansrv[49962]: [INFO ] Socket 12: AF_UNIX connection received
Feb 28 10:42:18 albert-aspire xrdp-chansrv[49962]: [INFO ] sound_process_training: round trip time 3
Feb 28 10:42:18 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Activating service name='org.gtk.vfs.Daemon' requested by ':1.0' (uid=1000 pid=50002 comm="pamac-tray")
Feb 28 10:42:18 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Successfully activated service 'org.gtk.vfs.Daemon'
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Activating service name='ca.desrt.dconf' requested by ':1.8' (uid=1000 pid=50078 comm="gsettings set org.gnome.desktop.interface cursor-t")
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Successfully activated service 'ca.desrt.dconf'
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Activating service name='org.a11y.Bus' requested by ':1.10' (uid=1000 pid=50000 comm="xfce4-power-manager")
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Successfully activated service 'org.a11y.Bus'
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Activating service name='org.freedesktop.Notifications' requested by ':1.2' (uid=1000 pid=50000 comm="xfce4-power-manager")
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: Setting bounce_freq in section global doesn't exist
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: Setting geometry in section global doesn't exist
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: Cannot set empty value for setting separator_color
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: Setting startup_notification in section global doesn't exist
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: Section shortcuts is deprecated.
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: Settings in the shortcuts sections have been moved to the global section.
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: Alternatively you can bind shortcuts in you window manager to dunstctl commands. For that, see the manual for dunstctl.
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: Ignoring this section.
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Successfully activated service 'org.freedesktop.Notifications'
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Activating service name='org.xfce.Xfconf' requested by ':1.2' (uid=1000 pid=50000 comm="xfce4-power-manager")
Feb 28 10:42:19 albert-aspire org.a11y.Bus[50095]: dbus-daemon[50095]: Activating service name='org.a11y.atspi.Registry' requested by ':1.1' (uid=1000 pid=49989 comm="volumeicon")
Feb 28 10:42:19 albert-aspire dbus-daemon[49980]: [session uid=1000 pid=49978] Successfully activated service 'org.xfce.Xfconf'
Feb 28 10:42:19 albert-aspire org.a11y.Bus[50095]: dbus-daemon[50095]: Successfully activated service 'org.a11y.atspi.Registry'
Feb 28 10:42:19 albert-aspire org.a11y.Bus[50114]: SpiRegistry daemon is running with well-known name - org.a11y.atspi.Registry
Feb 28 10:42:19 albert-aspire org.freedesktop.Notifications[50097]: WARNING: No icon found in path: 'nm-signal-75'
Feb 28 10:42:19 albert-aspire pkexec[50160]: albert: Error executing command as another user: Not authorized [USER=root] [TTY=unknown] [CWD=/home/albert] [COMMAND=/usr/bin/xfpm-power-backlight-helper --set-brightness-switch 0]
Feb 28 10:42:20 albert-aspire xrdp-chansrv[49962]: [ERROR] clipboard_event_selection_request: unknown target text/plain;charset=utf-8
Feb 28 10:42:20 albert-aspire xrdp-chansrv[49962]: [ERROR] clipboard_c2s_in_files: parse error
Feb 28 10:42:57 albert-aspire xrdp-chansrv[49962]: [ERROR] clipboard_event_selection_request: unknown target text/plain;charset=utf-8
Feb 28 10:42:57 albert-aspire xrdp-chansrv[49962]: [ERROR] clipboard_c2s_in_files: parse error
Feb 28 10:43:48 albert-aspire xrdp-sesman[49938]: [INFO ] sesman_main_loop: sesman asked to terminate
Feb 28 10:43:48 albert-aspire org.freedesktop.Notifications[50097]: X connection to :10.0 broken (explicit kill or server shutdown).
Feb 28 10:43:48 albert-aspire xrdp-sesman[49957]: [WARN ] Window manager (pid 49958, display 10) exited with non-zero exit code 143 and signal 0. This could indicate a window manager config problem
Feb 28 10:43:48 albert-aspire systemd[1]: Stopping xrdp session manager...
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] Calling auth_stop_session and auth_end from pid 49957
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: pam_unix(xrdp-sesman:session): session closed for user albert
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] Terminating X server (pid 49959) on display 10
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] Terminating the xrdp channel server (pid 49962) on display 10
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] X server on display 10 (pid 49959) returned exit code 0 and signal number 0
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] xrdp channel server for display 10 (pid 49962) exit code 0 and signal number 0
Feb 28 10:43:49 albert-aspire xrdp-sesman[49957]: [INFO ] cleanup_sockets:
Feb 28 10:43:49 albert-aspire systemd[1]: xrdp-sesman.service: Deactivated successfully.
Feb 28 10:43:49 albert-aspire systemd[1]: Stopped xrdp session manager.
Feb 28 10:43:49 albert-aspire systemd[1]: xrdp-sesman.service: Consumed 27.294s CPU time.
-- Boot 2d8614bbdd764dcc98f7e477635c393b --
Feb 28 10:44:14 albert-aspire systemd[1]: Starting xrdp session manager...
Feb 28 10:44:14 albert-aspire xrdp-sesman[460]: [INFO ] starting xrdp-sesman with pid 460
Feb 28 10:44:14 albert-aspire systemd[1]: Started xrdp session manager.
Feb 28 10:45:08 albert-aspire xrdp-sesman[460]: [INFO ] Socket 12: AF_INET6 connection received from ::1 port 44782
Feb 28 10:45:08 albert-aspire xrdp-sesman[460]: pam_systemd_home(xrdp-sesman:auth): systemd-homed is not available: Unit dbus-org.freedesktop.home1.service not found.
Feb 28 10:45:08 albert-aspire xrdp-sesman[460]: [INFO ] Terminal Server Users group is disabled, allowing authentication
Feb 28 10:45:08 albert-aspire xrdp-sesman[460]: [INFO ] ++ created session (access granted): username albert, ip ::ffff:192.168.111.250:47660 - socket: 12
Feb 28 10:45:09 albert-aspire xrdp-sesman[460]: [INFO ] starting Xorg session...
Feb 28 10:45:09 albert-aspire xrdp-sesman[460]: [INFO ] Starting session: session_pid 940, display :10.0, width 1228, height 1376, bpp 24, client ip ::ffff:192.168.111.250:47660 - socket: 12, user name albert
Feb 28 10:45:09 albert-aspire xrdp-sesman[940]: [INFO ] [session start] (display 10): calling auth_start_session from pid 940
Feb 28 10:45:09 albert-aspire xrdp-sesman[460]: [ERROR] sesman_data_in: scp_process_msg failed
Feb 28 10:45:09 albert-aspire xrdp-sesman[940]: pam_unix(xrdp-sesman:session): session opened for user albert(uid=1000) by (uid=0)
Feb 28 10:45:09 albert-aspire xrdp-sesman[940]: pam_systemd(xrdp-sesman:session): Failed to create session: No child processes
Feb 28 10:45:09 albert-aspire xrdp-sesman[942]: [INFO ] Starting X server on display 10: Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
Feb 28 10:45:09 albert-aspire xrdp-sesman[460]: [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans
Feb 28 10:45:10 albert-aspire xrdp-sesman[941]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:45:10 albert-aspire xrdp-sesman[940]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:45:10 albert-aspire xrdp-sesman[941]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:45:10 albert-aspire xrdp-sesman[940]: [INFO ] Session started successfully for user albert on display 10
Feb 28 10:45:10 albert-aspire xrdp-sesman[952]: [INFO ] Starting the xrdp channel server for display 10
Feb 28 10:45:10 albert-aspire xrdp-sesman[941]: [INFO ] Starting the default window manager on display 10: /etc/xrdp/startwm.sh
Feb 28 10:45:10 albert-aspire xrdp-sesman[940]: [INFO ] Session in progress on display 10, waiting until the window manager (pid 941) exits to end the session
Feb 28 10:45:10 albert-aspire xrdp-chansrv[952]: [INFO ] Socket 12: AF_UNIX connection received
Feb 28 10:45:10 albert-aspire xrdp-chansrv[952]: [INFO ] sound_process_training: round trip time 100
Feb 28 10:45:10 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Activating service name='org.gtk.vfs.Daemon' requested by ':1.0' (uid=1000 pid=990 comm="pamac-tray")
Feb 28 10:45:10 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Successfully activated service 'org.gtk.vfs.Daemon'
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Activating service name='ca.desrt.dconf' requested by ':1.7' (uid=1000 pid=1059 comm="gsettings set org.gnome.desktop.interface cursor-t")
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Successfully activated service 'ca.desrt.dconf'
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Activating service name='org.a11y.Bus' requested by ':1.10' (uid=1000 pid=990 comm="pamac-tray")
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Successfully activated service 'org.a11y.Bus'
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Activating service name='org.freedesktop.Notifications' requested by ':1.5' (uid=1000 pid=988 comm="xfce4-power-manager")
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: Setting bounce_freq in section global doesn't exist
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: Setting geometry in section global doesn't exist
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: Cannot set empty value for setting separator_color
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: Setting startup_notification in section global doesn't exist
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: Section shortcuts is deprecated.
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: Settings in the shortcuts sections have been moved to the global section.
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: Alternatively you can bind shortcuts in you window manager to dunstctl commands. For that, see the manual for dunstctl.
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: Ignoring this section.
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Successfully activated service 'org.freedesktop.Notifications'
Feb 28 10:45:11 albert-aspire org.a11y.Bus[1083]: dbus-daemon[1083]: Activating service name='org.a11y.atspi.Registry' requested by ':1.0' (uid=1000 pid=990 comm="pamac-tray")
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Activating service name='org.xfce.Xfconf' requested by ':1.5' (uid=1000 pid=988 comm="xfce4-power-manager")
Feb 28 10:45:11 albert-aspire org.freedesktop.Notifications[1093]: WARNING: No icon found in path: 'nm-signal-75'
Feb 28 10:45:11 albert-aspire org.a11y.Bus[1083]: dbus-daemon[1083]: Successfully activated service 'org.a11y.atspi.Registry'
Feb 28 10:45:11 albert-aspire org.a11y.Bus[1105]: SpiRegistry daemon is running with well-known name - org.a11y.atspi.Registry
Feb 28 10:45:11 albert-aspire dbus-daemon[968]: [session uid=1000 pid=966] Successfully activated service 'org.xfce.Xfconf'
Feb 28 10:45:11 albert-aspire pkexec[1149]: albert: Error executing command as another user: Not authorized [USER=root] [TTY=unknown] [CWD=/home/albert] [COMMAND=/usr/bin/xfpm-power-backlight-helper --set-brightness-switch 0]
Feb 28 10:45:12 albert-aspire xrdp-chansrv[952]: [ERROR] clipboard_event_selection_request: unknown target text/plain;charset=utf-8
Feb 28 10:45:12 albert-aspire xrdp-chansrv[952]: [ERROR] clipboard_c2s_in_files: parse error
Feb 28 10:58:26 albert-aspire systemd[1]: Stopping xrdp session manager...
Feb 28 10:58:26 albert-aspire xrdp-sesman[460]: [INFO ] sesman_main_loop: sesman asked to terminate
Feb 28 10:58:26 albert-aspire org.freedesktop.Notifications[1093]: X connection to :10.0 broken (explicit kill or server shutdown).
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [WARN ] Window manager (pid 941, display 10) exited with non-zero exit code 143 and signal 0. This could indicate a window manager config problem
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] Calling auth_stop_session and auth_end from pid 940
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: pam_unix(xrdp-sesman:session): session closed for user albert
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] Terminating X server (pid 942) on display 10
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] Terminating the xrdp channel server (pid 952) on display 10
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] X server on display 10 (pid 942) returned exit code 0 and signal number 0
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] xrdp channel server for display 10 (pid 952) exit code 0 and signal number 0
Feb 28 10:58:26 albert-aspire xrdp-sesman[940]: [INFO ] cleanup_sockets:
Feb 28 10:58:26 albert-aspire systemd[1]: xrdp-sesman.service: Deactivated successfully.
Feb 28 10:58:26 albert-aspire systemd[1]: Stopped xrdp session manager.
Feb 28 10:58:26 albert-aspire systemd[1]: xrdp-sesman.service: Consumed 2min 51.727s CPU time.
Feb 28 10:58:26 albert-aspire systemd[1]: Starting xrdp session manager...
Feb 28 10:58:26 albert-aspire xrdp-sesman[1379]: [INFO ] starting xrdp-sesman with pid 1379
Feb 28 10:58:26 albert-aspire systemd[1]: Started xrdp session manager.
Feb 28 10:58:31 albert-aspire systemd[1]: Stopping xrdp session manager...
Feb 28 10:58:31 albert-aspire xrdp-sesman[1379]: [INFO ] sesman_main_loop: sesman asked to terminate
Feb 28 10:58:31 albert-aspire systemd[1]: xrdp-sesman.service: Deactivated successfully.
Feb 28 10:58:31 albert-aspire systemd[1]: Stopped xrdp session manager.
Feb 28 10:58:31 albert-aspire systemd[1]: Starting xrdp session manager...
Feb 28 10:58:31 albert-aspire xrdp-sesman[1389]: [INFO ] starting xrdp-sesman with pid 1389
Feb 28 10:58:31 albert-aspire systemd[1]: Started xrdp session manager.
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [INFO ] Socket 12: AF_INET6 connection received from ::1 port 60062
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: pam_systemd_home(xrdp-sesman:auth): systemd-homed is not available: Unit dbus-org.freedesktop.home1.service not found.
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [INFO ] Terminal Server Users group is disabled, allowing authentication
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [INFO ] ++ created session (access granted): username albert, ip ::ffff:192.168.111.250:45250 - socket: 12
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [INFO ] starting Xorg session...
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [INFO ] Starting session: session_pid 1394, display :10.0, width 1228, height 1376, bpp 24, client ip ::ffff:192.168.111.250:45250 - socket: 12, user name albert
Feb 28 10:58:36 albert-aspire xrdp-sesman[1394]: [INFO ] [session start] (display 10): calling auth_start_session from pid 1394
Feb 28 10:58:36 albert-aspire xrdp-sesman[1389]: [ERROR] sesman_data_in: scp_process_msg failed
Feb 28 10:58:36 albert-aspire xrdp-sesman[1394]: pam_unix(xrdp-sesman:session): session opened for user albert(uid=1000) by (uid=0)
Feb 28 10:58:36 albert-aspire xrdp-sesman[1394]: pam_systemd(xrdp-sesman:session): Failed to create session: No child processes
Feb 28 10:58:36 albert-aspire xrdp-sesman[1396]: [INFO ] Starting X server on display 10: Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
Feb 28 10:58:37 albert-aspire xrdp-sesman[1389]: [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans
Feb 28 10:58:37 albert-aspire xrdp-sesman[1395]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:58:37 albert-aspire xrdp-sesman[1394]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:58:37 albert-aspire xrdp-sesman[1395]: [INFO ] Found X server running at /tmp/.X11-unix/X10
Feb 28 10:58:37 albert-aspire xrdp-sesman[1394]: [INFO ] Session started successfully for user albert on display 10
Feb 28 10:58:37 albert-aspire xrdp-sesman[1402]: [INFO ] Starting the xrdp channel server for display 10
Feb 28 10:58:37 albert-aspire xrdp-sesman[1395]: [INFO ] Starting the default window manager on display 10: /etc/xrdp/startwm.sh
Feb 28 10:58:37 albert-aspire xrdp-sesman[1394]: [INFO ] Session in progress on display 10, waiting until the window manager (pid 1395) exits to end the session
Feb 28 10:58:38 albert-aspire xrdp-chansrv[1402]: [INFO ] Socket 12: AF_UNIX connection received
Feb 28 10:58:38 albert-aspire xrdp-chansrv[1402]: [INFO ] sound_process_training: round trip time 101
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Activating service name='org.gtk.vfs.Daemon' requested by ':1.0' (uid=1000 pid=1439 comm="pamac-tray")
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Successfully activated service 'org.gtk.vfs.Daemon'
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Activating service name='ca.desrt.dconf' requested by ':1.8' (uid=1000 pid=1502 comm="gsettings set org.gnome.desktop.interface cursor-t")
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Successfully activated service 'ca.desrt.dconf'
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Activating service name='org.a11y.Bus' requested by ':1.10' (uid=1000 pid=1437 comm="xfce4-power-manager")
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Successfully activated service 'org.a11y.Bus'
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Activating service name='org.freedesktop.Notifications' requested by ':1.4' (uid=1000 pid=1437 comm="xfce4-power-manager")
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: Setting bounce_freq in section global doesn't exist
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: Setting geometry in section global doesn't exist
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: Cannot set empty value for setting separator_color
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: Setting startup_notification in section global doesn't exist
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: Section shortcuts is deprecated.
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: Settings in the shortcuts sections have been moved to the global section.
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: Alternatively you can bind shortcuts in you window manager to dunstctl commands. For that, see the manual for dunstctl.
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: Ignoring this section.
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Successfully activated service 'org.freedesktop.Notifications'
Feb 28 10:58:38 albert-aspire org.a11y.Bus[1532]: dbus-daemon[1532]: Activating service name='org.a11y.atspi.Registry' requested by ':1.2' (uid=1000 pid=1426 comm="volumeicon")
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Activating service name='org.xfce.Xfconf' requested by ':1.4' (uid=1000 pid=1437 comm="xfce4-power-manager")
Feb 28 10:58:38 albert-aspire dbus-daemon[1417]: [session uid=1000 pid=1415] Successfully activated service 'org.xfce.Xfconf'
Feb 28 10:58:38 albert-aspire org.a11y.Bus[1532]: dbus-daemon[1532]: Successfully activated service 'org.a11y.atspi.Registry'
Feb 28 10:58:38 albert-aspire org.a11y.Bus[1549]: SpiRegistry daemon is running with well-known name - org.a11y.atspi.Registry
Feb 28 10:58:38 albert-aspire org.freedesktop.Notifications[1534]: WARNING: No icon found in path: 'nm-signal-75'
Feb 28 10:58:39 albert-aspire pkexec[1599]: albert: Error executing command as another user: Not authorized [USER=root] [TTY=unknown] [CWD=/home/albert] [COMMAND=/usr/bin/xfpm-power-backlight-helper --set-brightness-switch 0]
Feb 28 10:58:39 albert-aspire xrdp-chansrv[1402]: [ERROR] clipboard_event_selection_request: unknown target text/plain;charset=utf-8
Feb 28 10:58:39 albert-aspire xrdp-chansrv[1402]: [ERROR] clipboard_c2s_in_files: parse error
Feb 28 10:58:59 albert-aspire xrdp-sesman[1389]: [INFO ] sesman_main_loop: sesman asked to terminate
Feb 28 10:59:00 albert-aspire org.freedesktop.Notifications[1534]: X connection to :10.0 broken (explicit kill or server shutdown).
Feb 28 10:58:59 albert-aspire xrdp-sesman[1394]: [WARN ] Window manager (pid 1395, display 10) exited with non-zero exit code 143 and signal 0. This could indicate a window manager config problem
Feb 28 10:58:59 albert-aspire systemd[1]: Stopping xrdp session manager...
Feb 28 10:59:00 albert-aspire xrdp-sesman[1394]: [INFO ] Calling auth_stop_session and auth_end from pid 1394
Feb 28 10:59:00 albert-aspire xrdp-sesman[1394]: pam_unix(xrdp-sesman:session): session closed for user albert
Feb 28 10:59:00 albert-aspire xrdp-sesman[1394]: [INFO ] Terminating X server (pid 1396) on display 10
Feb 28 10:59:00 albert-aspire xrdp-sesman[1394]: [INFO ] Terminating the xrdp channel server (pid 1402) on display 10
Feb 28 10:59:00 albert-aspire xrdp-sesman[1394]: [INFO ] X server on display 10 (pid 1396) returned exit code 0 and signal number 0
Feb 28 10:59:01 albert-aspire xrdp-sesman[1394]: [INFO ] xrdp channel server for display 10 (pid 1402) exit code 0 and signal number 0
Feb 28 10:59:01 albert-aspire xrdp-sesman[1394]: [INFO ] cleanup_sockets:
Feb 28 10:59:01 albert-aspire systemd[1]: xrdp-sesman.service: Deactivated successfully.
Feb 28 10:59:01 albert-aspire systemd[1]: Stopped xrdp session manager.
Feb 28 10:59:01 albert-aspire systemd[1]: xrdp-sesman.service: Consumed 9.084s CPU time.
-- Boot d6e4488bfeb44b7f8ad5a5a890908e5c --
Feb 28 11:01:21 albert-aspire systemd[1]: Starting xrdp session manager...
Feb 28 11:01:21 albert-aspire xrdp-sesman[464]: [INFO ] starting xrdp-sesman with pid 464
Feb 28 11:01:21 albert-aspire systemd[1]: Started xrdp session manager.

Guides I've looked at for help/ideas

KiLLeRRaT commented 1 year ago

First of all, if you're at work and you disconnect from your session, can you reconnect to it immediately?

Yes,

I also tested this by:

KiLLeRRaT commented 1 year ago

More findings:

On this new session via RDP, I can open windows, but I have found that when I open a terminal, and type, the terminal doesn't show what I'm typing. It's as if it doesn't repaint the screen or something. If I then open another window it forces a repaint, and then shows everything I've typed in the terminal.

I have also noticed two processes for Xorg, one on display :0 and one on display :10. The one on :0 is running as root, and the one on :10 is running as my user.

matt335672 commented 1 year ago

Let's stick with the reconnecting to the session. I've got no ideas on the repainting at the moment, and if we can't get the reconnect working the repainting is irrelevant.

The Xorg on :0 is the console X server and the Xorg on :10 is your xrdp session. Bear in mind that these can't both be logged in to the same user at the same time.

The reconnecting is a good first step - it shows you it's possible. Now we need to get some logs to see what's happening between the disconnect and a reconnect from a different machine.

1) Create an XRDP session. 2) Make a note of the time using the date command 3) Disconnect your RDP client. 4) (Possibly later) Connect from another client 5) Post the contents of xrdp-sesman.log from after the time noted in step 2)

KiLLeRRaT commented 1 year ago

Thanks for getting back to me.

Is it not possible to connect to my console session with all my apps open via xrdp? So that it doesn’t spawn another Xorg session. My normal use case would be using the machine by logging in directly (console session?) and the wanting to continue working remotely from my laptop.

Focussing on what you mentioned,

I have tried logging in from client A via xrdp. Opening some windows . Then disconnecting.

Then I log in from client B via xrdp as the same user. Those windows are still open.

So it looks like that part works as intended. Do you still need my sesman logs? If so I’ll have to grab them in the morning for you and send it through :)

(the repaint is a problem on both client A and B)

Thanks for the help!

matt335672 commented 1 year ago

If you want to connect to the existing console session you'll need to look at using something like x11vnc to export the console session over VNC. You can then connect to the VNC session remotely using VNC-over-ssh (i.e. Remmiba) or by configuring xrdp to connect to the x11vnc port.

If you're interested in looking further at this option (which matches your use-case), have a look at this post[(/neutrinolabs/xrdp/issues/2479#issuecomment-1362999717) and the whole of the issue it's in.

KiLLeRRaT commented 1 year ago

Cool thanks for that info. I’ll take a look. I’ve found his tic ally that the RDP protocol performed much better than VNC but I guess this is my only option.

For the repaint problem I have where my terminals don’t repaint over the rdp session, do you have any other ideas I can look at? They only repaint if I open another terminal or close one via i3.

EDIT: I just reread your last message again about the x11vnc going through xrdp. Does that mean that we’re using vnc on the machine between x11 and xrdp only and that remote clients will still connect using RDP. So xrdp will be like a translation layer if you like?

Cheers!

matt335672 commented 1 year ago

I can't really comment on the repaint problem - it's not really my area. You seem to be running the latest version of xorgxrdp, so that's not it.

Your question about VNC is exactly right.

KiLLeRRaT commented 1 year ago

Excellent! I never understood that fully, and now that I know how we can use xrdp as a VNC proxy, and I can connect over the internet using RDP, everything has fallen into place.

I have managed to set up x11vnc now, and I can connect to my console session from a remote location using RDP. That is great!

Thanks so much for the help!

Regards,