Closed prabhinmp closed 2 years ago
Hi @prabhinmp
We'll need a bit more information that that. How's this for starters:-
xrdp -v
systemctl cat xrdp.service
Also I note that the service is disabled which seems a little odd.
Thanks.
Hi @matt335672 , Please find the below info
xrdp -v
xrdp 0.9.12
A Remote Desktop Protocol Server.
Copyright (C) 2004-2018 Jay Sorg, Neutrino Labs, and all contributors.
See https://github.com/neutrinolabs/xrdp for more information.
Configure options:
--enable-ipv6
--enable-jpeg
--enable-fuse
--enable-rfxcodec
--enable-opus
--enable-painter
--enable-vsock
--build=x86_64-linux-gnu
--prefix=/usr
--includedir=${prefix}/include
--mandir=${prefix}/share/man
--infodir=${prefix}/share/info
--sysconfdir=/etc
--localstatedir=/var
--disable-silent-rules
--libdir=${prefix}/lib/x86_64-linux-gnu
--libexecdir=${prefix}/lib/x86_64-linux-gnu
--disable-maintainer-mode
--disable-dependency-tracking
--with-socketdir=/run/xrdp/sockdir
build_alias=x86_64-linux-gnu
CFLAGS=-g -O2 -fdebug-prefix-map=/build/xrdp-GJgww4/xrdp-0.9.12=. -fstack-protector-strong -Wformat -Werror=format-security
LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -Wl,--as-needed
CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2
PKG_CONFIG_PATH=/build/xrdp-GJgww4/xrdp-0.9.12/pkgconfig
systemctl cat xrdp.service
# /lib/systemd/system/xrdp.service
[Unit]
Description=xrdp daemon
Documentation=man:xrdp(8) man:xrdp.ini(5)
Requires=xrdp-sesman.service
After=network.target xrdp-sesman.service
[Service]
Type=forking
PIDFile=/run/xrdp/xrdp.pid
RuntimeDirectory=xrdp
EnvironmentFile=-/etc/sysconfig/xrdp
EnvironmentFile=-/etc/default/xrdp
User=xrdp
Group=xrdp
PermissionsStartOnly=true
ExecStartPre=/bin/sh /usr/share/xrdp/socksetup
ExecStart=/usr/sbin/xrdp $XRDP_OPTIONS
ExecStop=/usr/sbin/xrdp $XRDP_OPTIONS --kill
[Install]
WantedBy=multi-user.target
I tried to disable the service and enable it again that why you have seen the service-disabled in the first comment.
It looks like systemd is failing to see the PID file created by the xrdp service
What's the output of these commands when this happens:-
ls -l /run/xrdp
ls -ld /run/xrdp
sudo systemctl status xrdp-sesman.service
here is the output
root@tapp:/home/dev# ls -l /run/xrdp
total 8
drwxrwsrwt 2 xrdp xrdp 140 Oct 19 04:59 sockdir
-rw------- 1 xrdp xrdp 4 Oct 19 01:39 xrdp-sesman.pid
-rw------- 1 xrdp xrdp 4 Oct 19 01:40 xrdp.pid
root@prabhin-instance:/home/dev# ls -ld /run/xrdp
drwxr-xr-x 3 xrdp xrdp 100 Oct 19 01:40 /run/xrdp
root@prabhin-instance:/home/dev# sudo systemctl status xrdp-sesman.service
● xrdp-sesman.service - xrdp session manager
Loaded: loaded (/lib/systemd/system/xrdp-sesman.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2021-10-19 01:39:58 UTC; 4h 23min ago
Docs: man:xrdp-sesman(8)
man:sesman.ini(5)
Main PID: 1139 (xrdp-sesman)
Tasks: 1 (limit: 135208)
Memory: 4.2M
CGroup: /system.slice/xrdp-sesman.service
└─1139 /usr/sbin/xrdp-sesman
Oct 19 02:33:45 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
Oct 19 02:48:44 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] A connection received from ::1 port 34868
Oct 19 02:48:45 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] ++ reconnected session: username dev, display :10.0, session_pid 2073, ip ::ffff:106.xx.xxx.xxx:32070 - socket: 12
Oct 19 02:48:45 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
Oct 19 03:14:42 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] A connection received from ::1 port 40388
Oct 19 03:14:42 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] ++ reconnected session: username dev, display :10.0, session_pid 2073, ip ::ffff:106.xx.xxx.xxx:33305 - socket: 12
Oct 19 03:14:42 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
Oct 19 04:59:10 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] A connection received from ::1 port 33946
Oct 19 04:59:10 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[INFO ] ++ reconnected session: username dev, display :10.0, session_pid 2073, ip ::ffff:106.xx.xxx.xxx:33093 - socket: 12
Oct 19 04:59:10 prabhin-instance xrdp-sesman[1139]: (1139)(140537479259712)[DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
That all looks fine to me, and that's working on my system here so there's something else going on here which isn't obvious.
Are those commands the result directly after the problem occurs, or have you restarted xrdp manually in the meantime? That sesman log looks like sesman is accepting connections from xrdp which it wouldn't be if xrdp wasn't running.
@prabhinmp - have you gotten any further with this?
Thanks.
getting below error when xrdp start, once the system is up , if I do start the service manullay. it works perfectly.