LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-29-2020, 02:41 PM   #1
yodamin
LQ Newbie
 
Registered: Apr 2012
Location: Ottawa, Ontario, Canada
Distribution: Kubuntu 20.04 LTS / Windows 10 21H2 (paused forever) / Windows 2016 Server
Posts: 23

Rep: Reputation: 0
Unhappy XRDP sending login information to login manager - failed display 0


Hey all. This was all working perfectly before I did an upgrade / dist-upgrade. So, Since the server sits behind me physically I promptly forgot about it-to busy at the time.
Got laid of work and have all kinds of time now:-)

To make things more complicated, the old 10yr old system (Dell XPS) that was running my website died on me. So, I removed the SDD from it and shelved it for about 2.5 months.

I got a 10 day warning to renew certbot, so installed the website SDD into this newer PC (Alienware R4).

Of course I had no video or keyboard/mouse or whatever else. So, booted into recovery and started to fix stuff. Deleted any lock files found in /var/lib/apt and /var/libdpkg

ran dpkg --configure -a until all resolved - done
ran apt clean
ran apt-update --fix-missing - all good
ran apt upgrade and dist-upgrade
reboot and back at the desktop.
everything working fine, including my website (LAMP/Wordpress)
certbot renewed just fine well within the 10 day limit.
I go back to my desktop and sometime/days later I attempt to access this linuxbox using xrdp (installed before the PC move) and sesman connects OK - sends login info to login manager and then fails to logon. I am using the correct password because it was preprogrammed into the windows 10 RDP connectoid. I can ping the linux from windows and vice versa.

I have tried some things on my own starting with systemctl service xrdp stop / then status to make sure its not running / then apt purge xrdp xorgxrdp.

Reboot. Reinstall from scratch and test. Same thing.
Well, I removed and re-added firewall rules, ensured snort wasn't interfering by shutting it down and clearing the alerts and blocks.
I looked at startwm.sh and tried the two following configs:

#test -x /etc/X11/Xsession && exec /etc/X11/Xsession
#exec /bin/sh /etc/X11/Xsession
startxfce

and the default

test -x /etc/X11/Xsession && exec /etc/X11/Xsession
exec /bin/sh /etc/X11/Xsession
#startxfce

I changed Xwrapper to read: allowed_users=anybody instead of allowed_users=console

I added vim /etc/polkit-1/localauthority.conf.d/02-allow-colord.conf
with contents:

--------------snip------------
polkit.addRule(function(action, subject) {
if ((action.id == “org.freedesktop.color-manager.create-device” || action.id == “org.freedesktop.color-manager.create-profile” || action.id == “org.freedesktop.color-manager.delete-device” || action.id == “org.freedesktop.color-manager.delete-profile” || action.id == “org.freedesktop.color-manager.modify-device” || action.id == “org.freedesktop.color-manager.modify-profile”) && subject.isInGroup(“{group}”))
{
return polkit.Result.YES;
}
});
-------------------snip---------

seems like no matter what I do I get login failed display 0.

Again, this all worked just fine before the upgrade/dist-upgrade.

I WOULD LIVE someone to be able to help me out. I've been reading/experimenting with fixing this for about 7 days now, about 6-8hrs per day, I am well and truly stumped.
 
Old 05-30-2020, 02:09 AM   #2
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,376

Rep: Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756
You show as posting from Ubuntu, so I assume this is the distribution being used from the list in your profile.
I use xrdp on Slackware. Slackware does not use systemd and Slackware-current has only recently adopted PAM, so I am not au fait with additional PAM requirements for using xrdp.

What you describe would appear to be an authentication failure. Perhaps the contents of the xrdp.log and xrdp-sesman.log would give a clue.

I note that the latest version of xrdp only supports TLSv1.2 by default. You could try setting 'ssl_protocol=TLSv1, TLSv1.1, TLSv1.2' in /etc/xrdp/xrdp.ini as a test.
 
Old 05-30-2020, 11:14 PM   #3
yodamin
LQ Newbie
 
Registered: Apr 2012
Location: Ottawa, Ontario, Canada
Distribution: Kubuntu 20.04 LTS / Windows 10 21H2 (paused forever) / Windows 2016 Server
Posts: 23

Original Poster
Rep: Reputation: 0
Hi AllenD - thanks for response:-)

xrdp.ini is already set to what you suggested, must be default because I did not edit it at anytime.

Here is a snippet from my xrdp.log and another from xrdp-sesman.log follows it.

Thank you very much for your interest/help.

xrdp.log snippet:

200529-13:39:26] [DEBUG] Testing if xrdp can listen on 0.0.0.0 port 3389.
[20200529-13:39:26] [DEBUG] Closed socket 7 (AF_INET6 :: port 3389)
[20200529-13:39:28] [INFO ] starting xrdp with pid 2123
[20200529-13:39:28] [INFO ] listening to port 3389 on 0.0.0.0
[20200529-13:41:34] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20200529-13:41:34] [DEBUG] Testing if xrdp can listen on 0.0.0.0 port 3389.
[20200529-13:41:34] [DEBUG] Closed socket 7 (AF_INET6 :: port 3389)
[20200529-13:41:36] [INFO ] starting xrdp with pid 2669
[20200529-13:41:36] [INFO ] listening to port 3389 on 0.0.0.0
[20200529-13:42:31] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20200529-13:42:51] [DEBUG] Testing if xrdp can listen on 0.0.0.0 port 3389.
[20200529-13:42:51] [DEBUG] Closed socket 7 (AF_INET6 :: port 3389)
[20200529-13:42:53] [INFO ] starting xrdp with pid 999
[20200529-13:42:53] [INFO ] listening to port 3389 on 0.0.0.0
[20200529-13:43:20] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:192.168.1.2 port 50068
[20200529-13:43:20] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:192.168.1.223 port 3389)
[20200529-13:43:20] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20200529-13:43:20] [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
[20200529-13:43:20] [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
[20200529-13:43:20] [DEBUG] TLSv1.2 enabled
[20200529-13:43:20] [DEBUG] TLSv1.1 enabled
[20200529-13:43:20] [DEBUG] TLSv1 enabled
[20200529-13:43:20] [DEBUG] Security layer: requested 11, selected 1
[20200529-13:43:20] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:192.168.1.223 port 3389)
[20200529-13:43:56] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:192.168.1.2 port 50076
[20200529-13:43:56] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:192.168.1.223 port 3389)
[20200529-13:43:56] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20200529-13:43:56] [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
[20200529-13:43:56] [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
[20200529-13:43:56] [DEBUG] TLSv1.2 enabled
[20200529-13:43:56] [DEBUG] TLSv1.1 enabled
[20200529-13:43:56] [DEBUG] TLSv1 enabled
[20200529-13:43:56] [DEBUG] Security layer: requested 11, selected 1
[20200529-13:43:56] [INFO ] connected client computer name: MYPC
[20200529-13:43:56] [INFO ] TLS connection established from ::ffff:192.168.1.2 port 50076: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384
[20200529-13:43:56] [DEBUG] xrdp_0000053e_wm_login_mode_event_00000001
[20200529-13:43:56] [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
[20200529-13:43:56] [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
[20200529-13:44:08] [DEBUG] xrdp_wm_log_msg: connecting to sesman ip 127.0.0.1 port 3350
[20200529-13:44:09] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20200529-13:44:09] [DEBUG] xrdp_wm_log_msg: sending login info to session manager, please wait...
[20200529-13:44:09] [DEBUG] return value from xrdp_mm_connect 0
[20200529-13:44:09] [INFO ] xrdp_wm_log_msg: login failed for display 0
[20200529-13:44:09] [DEBUG] xrdp_mm_module_cleanup
[20200529-13:44:09] [DEBUG] Closed socket 24 (AF_INET6 ::1 port 34300)


and xrdp-sesman.log snippet:

d[20200529-13:39:27] [DEBUG] libscp initialized
[20200529-13:39:27] [DEBUG] Testing if xrdp-sesman can listen on 127.0.0.1 port 3350.
[20200529-13:39:27] [INFO ] starting xrdp-sesman with pid 2210
[20200529-13:39:27] [DEBUG] Closed socket 5 (AF_INET6 ::1 port 3350)
[20200529-13:39:27] [INFO ] listening to port 3350 on 127.0.0.1
[20200529-13:41:34] [INFO ] shutting down sesman 1
[20200529-13:41:34] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20200529-13:41:34] [DEBUG] libscp initialized
[20200529-13:41:34] [DEBUG] Testing if xrdp-sesman can listen on 127.0.0.1 port 3350.
[20200529-13:41:34] [INFO ] starting xrdp-sesman with pid 2659
[20200529-13:41:34] [DEBUG] Closed socket 5 (AF_INET6 ::1 port 3350)
[20200529-13:41:34] [INFO ] listening to port 3350 on 127.0.0.1
[20200529-13:42:31] [INFO ] shutting down sesman 1
[20200529-13:42:31] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20200529-13:42:51] [DEBUG] libscp initialized
[20200529-13:42:51] [DEBUG] Testing if xrdp-sesman can listen on 127.0.0.1 port 3350.
[20200529-13:42:51] [INFO ] starting xrdp-sesman with pid 938
[20200529-13:42:51] [DEBUG] Closed socket 5 (AF_INET6 ::1 port 3350)
[20200529-13:42:51] [INFO ] listening to port 3350 on 127.0.0.1
[20200529-13:44:08] [INFO ] A connection received from ::1 port 34300
[20200529-13:44:09] [INFO ] login denied for user jd
[20200529-13:44:09] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20200529-13:44:19] [INFO ] A connection received from ::1 port 34302
[20200529-13:44:19] [INFO ] login denied for user jd
[20200529-13:44:19] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20200529-14:55:56] [INFO ] shutting down sesman 1
[20200529-14:55:56] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20200529-14:55:56] [DEBUG] libscp initialized
[20200529-14:55:56] [DEBUG] Testing if xrdp-sesman can listen on 127.0.0.1 port 3350.
[20200529-14:55:56] [INFO ] starting xrdp-sesman with pid 7925
[20200529-14:55:56] [DEBUG] Closed socket 5 (AF_INET6 ::1 port 3350)
[20200529-14:55:56] [INFO ] listening to port 3350 on 127.0.0.1
[20200529-14:57:40] [INFO ] A connection received from ::1 port 34474
[20200529-14:57:41] [INFO ] login denied for user jd
 
Old 05-31-2020, 08:12 AM   #4
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,376

Rep: Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756Reputation: 2756
It appears that the server running xrdp does not approve the login for user jd
Quote:
[20200529-13:44:09] [INFO ] login denied for user jd
In my logs I see '++ created session (access granted): username ...'
Perhaps this is relevant.
 
Old 05-31-2020, 01:18 PM   #5
yodamin
LQ Newbie
 
Registered: Apr 2012
Location: Ottawa, Ontario, Canada
Distribution: Kubuntu 20.04 LTS / Windows 10 21H2 (paused forever) / Windows 2016 Server
Posts: 23

Original Poster
Rep: Reputation: 0
Already put xrdp into ssl-cert group. Am fed up with Linux being so much less stable than Windows. I can't believe I am saying this but after 20 years of using Windows and Linux I gotta say Windows NEVER GIVES me as much trouble as Linux does. Every single major upgrade of Linux breaks something seriously. Windows does this routinely with little or no issues whatsoever 99.9% of the time.

About 20 Years ago a friend told me he had run a linux box (redhat) (websrv mostly but a couple of other services also) for five years without a reboot or update/upgrade. I ask him why and he replied Linux will break if you update or upgrade it. Linux will only break if you reboot it. He was a developer and an expert at IP Chains and he was trying to help me recover from a Linux box crash after accepted an upgrade and upgraded the OS.

I'm done with Linux now I believe. I'll use it the way it is; as long as my website loads I can put up with the current situation. When the website stops loading, I'll reinstall Windows 10 on that box and run WAMP/Wordpress on it. I am SO tired of Linux breaking on an update or upgrade. This happens on a regular basis while windows routinely updates/upgrades even major versions with 99.9% success rate - meaning no issues after update/upgrade.

Linux has had just as much brains, talent and money thrown at it as Windows has and almost as much time. Linux has NOT matured or stabilized as well as Windows has. Especially Windows 10. When something is free and no one is at the head (except for some REALLY BIG EGOS who are NOT willing to compromise in anyway, shape or form) of the Linux camp to organize and direct you get exactly what you see now. A half assed Operating system that breaks if you change something on a regular basis.

Even the BIG corp. Linux's suck compared to Windows. Linux has free software, is open source so code can be inspected freely (but whose to say the developer use the source he provided for inspection to actually compile the software huh? No one that's who cause it's impossible to tell! AND WHO compiles all their software, including the OS itself from source? less than 1% of the open source community that's who - so is it really more secure, I mean REALLY??)

I am really disappointed in Linux at this time as you can tell.

Bon voyage Linux. When the two boxes I have die thats it, Linux loses another long time user to the bigger and better Windows.
 
Old 06-02-2020, 06:35 PM   #6
yodamin
LQ Newbie
 
Registered: Apr 2012
Location: Ottawa, Ontario, Canada
Distribution: Kubuntu 20.04 LTS / Windows 10 21H2 (paused forever) / Windows 2016 Server
Posts: 23

Original Poster
Rep: Reputation: 0
I resolved this situation by "apt purge xrdp xorgxrdp"
reboot
apt install x2gosever x2goserver-session
restart

install windows client x2goclient - everything just works. I got the software name from another thread in the Ubuntu forums.

I had no idea it existed, now I do, all is well in the world again. Except for the obvious issues with Linux development, that's still pretty pathetic.

Please don't tell me Linux is all volunteer's either. Debian, Red Hat, Ubuntu none of these companies rely on volunteer's.

Cheers, marking resolved.
 
Old 06-02-2020, 06:36 PM   #7
yodamin
LQ Newbie
 
Registered: Apr 2012
Location: Ottawa, Ontario, Canada
Distribution: Kubuntu 20.04 LTS / Windows 10 21H2 (paused forever) / Windows 2016 Server
Posts: 23

Original Poster
Rep: Reputation: 0
Don't want to sound ungrateful to the people who ARE volunteers, you guys are pretty awesome:-) But, volunteers are NOT going to bring Linux up to speed with Windows.
 
Old 11-03-2020, 08:05 PM   #8
Sevemo
LQ Newbie
 
Registered: Nov 2020
Distribution: Ubuntu 20.04LTS / Windows Server 2008, 2012 / Windows 7, 10
Posts: 1

Rep: Reputation: Disabled
Did username and password good enough?

I got that " login failed for display 0" problem on my new installed Ubuntu 20.04 LTS.

After read/trial a lot of suggestions on internet, I think that it is a matching issues between xrdp and my ubuntu: My linux passwords were too simple, and or usernames not met the requirement between the systems -

1) User name cannot beginning with numbers and cap-letters;
2) Passwords in high security form is a must, i.e. It should contain characters from at least 3 of the 4 primary categories, including: uppercase letters, lowercase letters, numbers, and characters.

After the above correction had done, no more users on my 20.04 got that problem.
 
Old 10-25-2021, 08:25 AM   #9
carlz
LQ Newbie
 
Registered: Jan 2015
Posts: 2

Rep: Reputation: Disabled
I'm just adding my experience, since this was one of the first hits on my google search.

I received this error when trying to connect (I've been using ssh successfully on the box, so I knew my account was fine). My troubleshooting ended up including:
  • create a new local user an try to log in as them. (success)
  • log in as my existing user (it was an ldap user) (failure)
  • follow some other directions to make sure xrdp is hooked up to ldap (in /etc/pam.d/xrdp-sessman)
  • try to login as me, no luck, but used my fully qualified name (user@domain) and it got to the point that it complained about the display being unavailable.
  • check my .xsession-errors file in my home directory. It was trying to connect as xfce, but I am running gnome.
  • realize my .Xclient file is owned by root, so chown it and change the window manager to gnome-session.
  • success.

I know it is a bit roundabout, but these were the steps I took. The "unable to connect to DISPLAY:0 was coming because my user's home account was misconfigured with the wrong windowmanager and the .Xclient file had the wrong entry and permissions.
 
Old 11-05-2022, 02:56 PM   #10
alexbo
LQ Newbie
 
Registered: Nov 2022
Posts: 1

Rep: Reputation: 0
Thumbs up the problem stopped, though didn't fix for me

hello friend,

to make the error disappear, all i had to do is
supplying username and password in the rdp client.
the same worked for me in ms rdp and remmina,
either direct and over ssh.

however, i'm connecting through a public key to
the ssh port, and would sincerely prefer to have
no password for this user login.

hope this helps,
alex
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Sending login info to session manager, Login failed for display 0 nt100 Linux - Newbie 8 08-17-2021 10:29 AM
XRDP failes authentication via xRDP divernick Linux - Software 3 02-06-2019 05:19 AM
[SOLVED] xrdp-v0.6.0 RHEL 6.4 Workstation. xrdp loaded started with sesman, but cannot connect capperdog Linux - Newbie 4 02-04-2014 02:56 PM
XRDP - Login failed m_harrison Slackware 1 06-22-2013 11:11 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration