On an out-of-the-box (plus apt update; apt upgrade) Lubuntu 18.04 box, I followed these steps to install xrdp:
sudo apt-get install xrdp
echo 'lxsession -e LXDE -s Lubuntu' > ~/.xsession
sudo service xrdp restart
This worked right away, but it broke Xorg on the console. From another host with Remmina I can still use the system with a complete, 100% functional GUI, but the console remains stuck in text mode (black screen with cursor).
I believe this is a similar scenario to the one outlined in this unanswered 2 year old post.
In /var/log/Xorg.0.log I find:
[ 29.206] (II) glamor: OpenGL accelerated X.org driver based.
[ 29.232] (II) glamor: EGL version 1.4:
[ 29.255] (II) modeset(0): glamor initialized
[ 29.264] (II) modeset(0): Output VGA-1 has no monitor section
[ 29.271] (II) modeset(0): Output DVI-D-1 has no monitor section
[ 29.362] (II) modeset(0): Output SVIDEO-1 has no monitor section
[ 29.381] (II) modeset(0): EDID for output VGA-1
[ 29.381] (II) modeset(0): Printing probed modes for output VGA-1
[ 29.381] (II) modeset(0): Modeline "1024x768"x60.0 65.00 1024 1048 1184 1344 768 771 777 806 -hsync -vsync (48.4 kHz e)
[ 29.381] (II) modeset(0): Modeline "800x600"x60.3 40.00 800 840 968 1056 600 601 605 628 +hsync +vsync (37.9 kHz e)
[ 29.381] (II) modeset(0): Modeline "800x600"x56.2 36.00 800 824 896 1024 600 601 603 625 +hsync +vsync (35.2 kHz e)
[ 29.381] (II) modeset(0): Modeline "848x480"x60.0 33.75 848 864 976 1088 480 486 494 517 +hsync +vsync (31.0 kHz e)
[ 29.381] (II) modeset(0): Modeline "640x480"x59.9 25.18 640 656 752 800 480 490 492 525 -hsync -vsync (31.5 kHz e)
[ 29.386] (II) modeset(0): EDID for output DVI-D-1
[ 29.477] (II) modeset(0): EDID for output SVIDEO-1
[ 29.477] (II) modeset(0): Output VGA-1 connected
[ 29.478] (II) modeset(0): Output DVI-D-1 disconnected
[ 29.478] (II) modeset(0): Output SVIDEO-1 disconnected
[ 29.478] (II) modeset(0): Using exact sizes for initial modes
[ 29.478] (II) modeset(0): Output VGA-1 using initial mode 1024x768 +0+0
[ 29.478] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[ 29.478] (==) modeset(0): DPI set to (96, 96)
[ 29.478] (II) Loading sub module "fb"
[ 29.478] (II) LoadModule: "fb"
[ 29.478] (II) Loading /usr/lib/xorg/modules/libfb.so
[ 29.478] (II) Module fb: vendor="X.Org Foundation"
[ 29.478] compiled for 1.19.6, module version = 1.0.0
[ 29.479] ABI class: X.Org ANSI C Emulation, version 0.4
[ 29.479] (==) Depth 24 pixmap format is 32 bpp
[ 29.479] Require OpenGL version 2.1 or later.
[ 29.479] (EE) modeset(0): Failed to initialize glamor at ScreenInit() time.
[ 29.479] (EE)
Fatal server error:
[ 29.479] (EE) AddScreen/ScreenInit failed for driver 0
[ 29.479] (EE)
[ 29.479] (EE)
Please consult the The X.Org Foundation support
at http://wiki.x.org
for help.
[ 29.479] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
The 'startx' command on the console outputs the following (typed in manually here because I can't copy-and-paste from the text mode console; there's no mouse support there):
Xorg X Server 1.19.6
Release Date: 2017-12-20
X Protocol Version 11, Revision 0
Build Operating System: Linux 4.15.0-140-generic 1686 Ubuntu
Current Operating System: Linux de945 5.4.0-80-generic #90~18.04.1-Ubuntu SMP Tue Jul 13 19:38:58 UtC 201 i686
Kernel command line: BOOT_IMAGE=/boot/vmliuz-5.4.0-80-generic root=UUID=5e51f27a-0823-4e70-aff8-7c513bc63fb3 ro quiet splash vt.handoff=1
Buil Date: 08 April 2021 01:52:21PM
xorg-server 2:1.19.6-1ubuntu4.9 (For technical support please see http://www.ubuntu.com/support)
Current version of pixman: 0.34.0
Before reporting problems, check http://wiki.x.org to make surethatyou have the latest version.
Marker: (--) probed, (**) from config file, (==) default setting, (**) from command line, (!!) notice, (II) informational, (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/home/frankvw/.local/share/xorg/Xorg.0.log",Time: Mon Jul 26 13:31:18 2021
(==) Using system config directory "/usr/share/X11/xorg.conf.d"
Require OpenGL version 2.1 or later.
(EE) Fatal server error: (EE) AddScreen/ScreenInit failed for driver 0. (EE) Please consult the Xorg Foundation support at http://wiki.x.org for help. (EE) Please also check the log file at "/home/frankvw/.local/share/xorg/Xorg.0.log" for additional information.
(EE) Server terminated with error (1). CLosing logfile.
xinit: giving up
xinit: unable to connect to X server: Connection refused
Xinit: server error
The command glxinfo | grep "OpenGL version"
entered from Remmina (on the text mode console I get an "Error: unable to open display) produces OpenGL version string: 3.1 Mesa 20.0.8
.
Where do I go from here? How do I find out what has been borked by the xrdp install and where, and how to fix it?
All suggestions are welcome!
// FvW