[20241108-12:25:04] [INFO ] [session start] (display 10): calling authstartsession from…
- User
[20241108-12:25:04] [INFO ] [session start] (display 10): calling auth_start_session from pid 2113035 [20241108-12:25:04] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans [20241108-12:25:04] [INFO ] Starting X server on display 10: /usr/lib/xorg/Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
[20241108-12:25:04] [INFO ] Found X server running at /tmp/.X11-unix/X10 [20241108-12:25:04] [INFO ] Found X server running at /tmp/.X11-unix/X10 [20241108-12:25:04] [INFO ] Found X server running at /tmp/.X11-unix/X10 [20241108-12:25:04] [INFO ] Starting the default window manager on display 10: /etc/xrdp/startwm.sh [20241108-12:25:04] [INFO ] Session started successfully for user nvidia on display 10 [20241108-12:25:04] [INFO ] Session in progress on display 10, waiting until the window manager (pid 2113036) exits to end the session [20241108-12:25:04] [INFO ] Starting the xrdp channel server for display 10 c[20241108-12:34:30] [INFO ] Socket 7: AF_INET6 connection received from ::1 port 33036 [20241108-12:34:30] [INFO ] ++ reconnected session: username nvidia, display :10.0, session_pid 2113035, ip ::ffff:76.103.135.209:50007 - socket: 11 [20241108-12:34:30] [ERROR] sesman_data_in: scp_process_msg failed [20241108-12:34:30] [INFO ] Starting session reconnection script on display 10: /etc/xrdp/reconnectwm.sh [20241108-12:34:30] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans ^C - Assistant
Based on the log entries you've provided, it appears that you're experiencing issues with xrdp sessions on your system. Let's analyze the log and identify potential causes and solutions.
Log Analysis
-
Session Start:
[20241108-12:25:04] [INFO ] [session start] (display 10): calling auth_start_session from pid 2113035- A new xrdp session is starting on display
:10for usernvidia.
- A new xrdp session is starting on display
-
Error in
sesman_main_loop:[20241108-12:25:04] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans- The session manager (
sesman) encountered an error in the main loop. The functiontrans_check_wait_objsfailed, leading to the removal of the transport (trans).
- The session manager (
-
Starting X Server and Window Manager:
[20241108-12:25:04] [INFO ] Starting X server on display 10: /usr/lib/xorg/Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log [20241108-12:25:04] [INFO ] Found X server running at /tmp/.X11-unix/X10 [20241108-12:25:04] [INFO ] Starting the default window manager on display 10: /etc/xrdp/startwm.sh- The X server and default window manager are being started as part of the session initiation.
-
Session Established:
[20241108-12:25:04] [INFO ] Session started successfully for user nvidia on display 10 [20241108-12:25:04] [INFO ] Session in progress on display 10, waiting until the window manager (pid 2113036) exits to end the session [20241108-12:25:04] [INFO ] Starting the xrdp channel server for display 10- The session appears to start successfully, and the system is waiting for the window manager process.
-
Reconnection Attempt:
[20241108-12:34:30] [INFO ] Socket 7: AF_INET6 connection received from ::1 port 33036 [20241108-12:34:30] [INFO ] ++ reconnected session: username nvidia, display :10.0, session_pid 2113035, ip ::ffff:76.103.135.209:50007 - socket: 11- A reconnection to the session is being attempted, possibly due to a disconnection or network interruption.
-
Error in
sesman_data_in:[20241108-12:34:30] [ERROR] sesman_data_in: scp_process_msg failed- The session manager failed to process an incoming message through the
scp_process_msgfunction.
- The session manager failed to process an incoming message through the
-
Reconnection Script Initiated and Further Error:
[20241108-12:34:30] [INFO ] Starting session reconnection script on display 10: /etc/xrdp/reconnectwm.sh [20241108-12:34:30] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans- The reconnection script is executed, but the same error as before occurs in the
sesman_main_loop.
- The reconnection script is executed, but the same error as before occurs in the
Possible Causes
-
Communication Breakdown Between xrdp and sesman:
- Errors in
trans_check_wait_objsandscp_process_msgsuggest issues with the transport layer or inter-process communication between xrdp and sesman.
- Errors in
-
Misconfiguration in Reconnection Scripts:
- The reconnection script
/etc/xrdp/reconnectwm.shmight have issues that prevent successful reconnection.
- The reconnection script
-
Port Conflicts or Firewall Restrictions:
- Network-related errors could be due to port conflicts or firewall settings blocking necessary ports.
-
User Permission Issues:
- The user
nvidiamight not have the necessary permissions for xrdp sessions or access to required resources.
- The user
-
X Server Issues:
- The X server might not be properly configured, or there could be conflicts with existing X sessions.
Recommended Troubleshooting Steps
-
Check xrdp and sesman Logs for More Details:
-
Examine the full log files for xrdp and sesman:
sudo less /var/log/xrdp.log sudo less /var/log/xrdp-sesman.log -
Look for any additional error messages or warnings around the timestamps of the errors.
-
-
Verify User Permissions and Environment:
-
Ensure that the user
nvidiahas a valid home directory and appropriate permissions:sudo ls -ld /home/nvidia -
Check ownership and permissions of critical files:
ls -la /home/nvidia/.Xauthority ls -la /home/nvidia/.xrdp -
If permissions are incorrect, you can fix them:
sudo chown nvidia:nvidia /home/nvidia/.Xauthority sudo chown -R nvidia:nvidia /home/nvidia/.xrdp
-
-
Inspect Reconnection Script:
-
Review the contents of
/etc/xrdp/reconnectwm.shto ensure it's correctly configured and executable.sudo cat /etc/xrdp/reconnectwm.sh sudo chmod +x /etc/xrdp/reconnectwm.sh -
Ensure the script correctly re-initializes the user's session.
-
-
Verify X Server Configuration:
-
Check the xrdp Xorg configuration file
/etc/X11/xrdp/xorg.conffor any anomalies.sudo cat /etc/X11/xrdp/xorg.conf -
Confirm that the display settings match your system's configuration.
-
-
Ensure xrdp and Xorg Components are Up-to-Date:
-
Update your system to ensure all packages are current:
sudo apt update sudo apt upgrade -
Reinstall xrdp and its dependencies if necessary:
sudo apt install --reinstall xrdp xorgxrdp
-
-
Test with a Different Desktop Environment:
-
Some desktop environments have compatibility issues with xrdp. Try installing and using a lightweight desktop environment like XFCE.
-
Install XFCE:
sudo apt install xfce4 xfce4-goodies -
Configure xrdp to use XFCE by creating or editing
~/.xsession:echo "startxfce4" > /home/nvidia/.xsession sudo chown nvidia:nvidia /home/nvidia/.xsession -
Restart xrdp:
sudo systemctl restart xrdp
-
-
-
Check Firewall Settings:
-
Ensure that the firewall allows xrdp traffic (default port 3389):
-
If using
ufw(Uncomplicated Firewall):sudo ufw allow 3389/tcp -
Check if the port is listening:
sudo netstat -tlnp | grep 3389
-
-
-
Review SELinux or AppArmor Policies:
-
If SELinux or AppArmor is enforcing policies, they might interfere with xrdp.
-
For SELinux:
-
Check the status:
sestatus -
Temporarily set SELinux to permissive mode for testing:
sudo setenforce 0 -
If this resolves the issue, consider adjusting SELinux policies.
-
-
For AppArmor:
-
Disable AppArmor profiles for xrdp to test:
sudo aa-complain /usr/sbin/xrdp sudo aa-complain /usr/sbin/xrdp-sesman
-
-
-
Examine Network Configuration:
-
Since the reconnection involves both IPv4 and IPv6 addresses, ensure that your network configuration supports both protocols correctly.
-
Check your
hostsfile for proper loopback settings:cat /etc/hosts- Ensure you have entries for
localhostfor both127.0.0.1and::1.
- Ensure you have entries for
-
-
Ensure No Conflicting Services:
-
Verify that no other remote desktop services are conflicting with xrdp.
-
Check for VNC servers or other instances of xrdp:
sudo netstat -tlnp | grep -E '(5900|3389)'
-
Additional Considerations
-
Date and Time Synchronization:
-
Ensure that your system's date and time are correct. Incorrect time settings can cause authentication and session issues.
date sudo timedatectl
-
-
Test with a New User Account:
-
Create a new user to determine if the issue is user-specific.
sudo adduser testuser -
Attempt to start an xrdp session with this new user.
-
Summary
The errors indicate that there's a communication issue between the xrdp session manager and the sessions themselves. Common causes include misconfigurations, permission issues, or conflicts with other services.
By systematically checking configurations, permissions, and logs, you can identify and resolve the underlying issue. Start by checking logs for more detailed error messages, then verify user permissions and configurations. Testing with a different desktop environment or a new user can help isolate the problem.
If the Problem Persists
If after following these steps the issue remains unresolved, please provide:
- Any additional error messages from
/var/log/xrdp.logand/var/log/xrdp-sesman.log. - Details about your operating system and version.
- The desktop environment you're using (e.g., GNOME, KDE, XFCE).
- Any recent changes to the system before the issue began.
With more information, I can offer further assistance to help resolve the problem.
-