Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Arch Linux : Can't start Xorg X server #2253

Closed
AKA-nian opened this issue May 6, 2022 · 15 comments
Closed

Arch Linux : Can't start Xorg X server #2253

AKA-nian opened this issue May 6, 2022 · 15 comments

Comments

@AKA-nian
Copy link

AKA-nian commented May 6, 2022

i have install xrdp and xrdp-sesman, they can start ,but have some problems.My system is archlinux Kernel: 5.17.5
here is the xrdp service

sudo systemctl status xrdp|cat

● xrdp.service - xrdp daemon
     Loaded: loaded (/usr/lib/systemd/system/xrdp.service; enabled; vendor preset: disabled)
     Active: active (running) since Fri 2022-05-06 14:58:20 CST; 2min 3s ago
       Docs: man:xrdp(8)
             man:xrdp.ini(5)
    Process: 109697 ExecStart=/usr/local/sbin/xrdp $XRDP_OPTIONS (code=exited, status=0/SUCCESS)
   Main PID: 109698 (xrdp)
      Tasks: 1 (limit: 38340)
     Memory: 872.0K
        CPU: 4ms
     CGroup: /system.slice/xrdp.service
             └─ 109698 /usr/local/sbin/xrdp

May 06 14:58:19 nian systemd[1]: Starting xrdp daemon...
May 06 14:58:19 nian xrdp[109697]: [INFO ] address [0.0.0.0] port [3389] mode 1
May 06 14:58:19 nian xrdp[109697]: [INFO ] listening to port 3389 on 0.0.0.0
May 06 14:58:19 nian xrdp[109697]: [INFO ] xrdp_listen_pp done
May 06 14:58:19 nian systemd[1]: xrdp.service: Can't open PID file /run/xrdp.pid (yet?) after start: Operation not permitted
May 06 14:58:20 nian systemd[1]: Started xrdp daemon.
May 06 14:58:21 nian xrdp[109698]: [INFO ] starting xrdp with pid 109698
May 06 14:58:21 nian xrdp[109698]: [INFO ] address [0.0.0.0] port [3389] mode 1
May 06 14:58:21 nian xrdp[109698]: [INFO ] listening to port 3389 on 0.0.0.0
May 06 14:58:21 nian xrdp[109698]: [INFO ] xrdp_listen_pp done

here is the xrdp-sesman service

sudo systemctl status xrdp-sesman.service|cat
● xrdp-sesman.service - xrdp session manager
     Loaded: loaded (/usr/lib/systemd/system/xrdp-sesman.service; enabled; vendor preset: disabled)
     Active: active (running) since Fri 2022-05-06 14:58:19 CST; 7min ago
       Docs: man:xrdp-sesman(8)
             man:sesman.ini(5)
    Process: 109695 ExecStart=/usr/local/sbin/xrdp-sesman $SESMAN_OPTIONS (code=exited, status=0/SUCCESS)
   Main PID: 109696 (xrdp-sesman)
      Tasks: 1 (limit: 38340)
     Memory: 828.0K
        CPU: 3ms
     CGroup: /system.slice/xrdp-sesman.service
             └─ 109696 /usr/local/sbin/xrdp-sesman

May 06 14:58:19 nian systemd[1]: Starting xrdp session manager...
May 06 14:58:19 nian xrdp-sesman[109696]: [INFO ] starting xrdp-sesman with pid 109696
May 06 14:58:19 nian systemd[1]: Started xrdp session manager.
May 06 14:58:19 nian xrdp-sesman[109696]: [INFO ] Sesman now listening on /var/run/xrdp-sesman/sesman.socket

xrdp.log

[20220506-15:06:48] [INFO ] Socket 12: AF_INET connection received f
rom 192.168.1.23 port 47758
[20220506-15:06:48] [INFO ] Using default X.509 certificate: /etc/xr
dp/cert.pem
[20220506-15:06:48] [INFO ] Using default X.509 key file: /etc/xrdp/
key.pem
[20220506-15:06:48] [INFO ] Security protocol: configured [SSL|RDP],
 requested [SSL|HYBRID|RDP], selected [SSL]
[20220506-15:06:48] [INFO ] Connected client computer name: nian
[20220506-15:06:48] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type
0xc006 is unknown (ignored)
[20220506-15:06:48] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type
0xc00a is unknown (ignored)
[20220506-15:06:49] [INFO ] xrdp_load_keyboard_layout: Keyboard info
rmation sent by the RDP client, keyboard_type:[0x04], keyboard_subty
pe:[0x00], keylayout:[0x00000409]
[20220506-15:06:49] [INFO ] xrdp_load_keyboard_layout: model [] vari
ant [] layout [us] options []
[20220506-15:06:49] [INFO ] TLS connection established from 192.168.
1.23 port 47758: TLSv1.3 with cipher TLS_AES_256_GCM_SHA384
[20220506-15:06:49] [INFO ] xrdp_caps_process_pointer: client suppor
ts new(color) cursor
[20220506-15:06:49] [INFO ] xrdp_process_offscreen_bmpcache: support
 level 1 cache size 7864320 MB cache entries 2000
[20220506-15:06:49] [INFO ] xrdp_caps_process_codecs: RemoteFX, code
c id 3, properties len 49
[20220506-15:06:49] [WARN ] Client Capability: not enough orders sup
ported by client, client wants off screen bitmap but offscreen bitma
ps disabled
[20220506-15:06:49] [INFO ] Loading keymap file /etc/xrdp/km-0000040
9.ini
[20220506-15:06:49] [WARN ] local keymap file for 0x00000409 found a
nd doesn't match built in keymap, using local keymap file
[20220506-15:06:55] [INFO ] connecting to sesman on sesman.socket
[20220506-15:06:55] [WARN ] Ignoring obsolete SCP port value '3350'
[20220506-15:06:55] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20220506-15:06:55] [INFO ] sesman connect ok
[20220506-15:06:55] [INFO ] sending login info to session manager. P
lease wait...
[20220506-15:06:55] [INFO ] xrdp_wm_log_msg: login successful for us
er nian on display 10
[20220506-15:06:55] [INFO ] login successful for user nian on displa
y 10
[20220506-15:06:55] [INFO ] loaded module 'libxup.so' ok, interface
size 11064, version 4
[20220506-15:06:55] [INFO ] started connecting
[20220506-15:06:55] [INFO ] lib_mod_connect: connecting via UNIX soc
ket
[20220506-15:07:25] [INFO ] connection problem, giving up
[20220506-15:07:25] [INFO ] some problem
[20220506-15:07:25] [ERROR] xrdp_wm_log_msg: Error connecting to use
r session
[20220506-15:07:25] [INFO ] Error connecting to user session

xrdp-sesman.log

[20220506-15:06:55] [INFO ] Socket 13: AF_UNIX connection received
[20220506-15:06:55] [INFO ] Received request to create Xorg session
for user: nian
[20220506-15:06:55] [INFO ] Terminal Server Users group is disabled,
 allowing authentication
[20220506-15:06:55] [INFO ] ++ created session (access granted): use
rname nian, ip 192.168.1.23:47758 - socket: 12
[20220506-15:06:55] [INFO ] Starting session: session_pid 110140, di
splay :10.0, width 2516, height 1320, bpp 24, client ip 192.168.1.23
:47758 - socket: 12, user name nian
[20220506-15:06:55] [INFO ] [session start] (display 10): calling au
th_start_session from pid 110140
[20220506-15:06:55] [INFO ] Starting X server on display 10: Xorg :1
0 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -l
ogfile .xorgxrdp.%s.log
[20220506-15:07:04] [WARN ] Timed out waiting for X server on displa
y 10 to startup
[20220506-15:07:04] [INFO ] Session started successfully for user ni
an on display 10
[20220506-15:07:04] [INFO ] Session in progress on display 10, waiti
ng until the window manager (pid 110141) exits to end the session
[20220506-15:07:04] [INFO ] Starting the xrdp channel server for dis
play 10
[20220506-15:07:05] [WARN ] Timed out waiting for X server on displa
y 10 to startup
[20220506-15:07:05] [ERROR] There is no X server active on display 1
0
[20220506-15:07:05] [ERROR] A fatal error has occured attempting to
start the window manager on display 10, aborting connection
[20220506-15:07:05] [WARN ] Window manager (pid 110141, display 10)
exited quickly (1 secs). This could indicate a window manager config
 problem
[20220506-15:07:05] [INFO ] Calling auth_stop_session and auth_end f
rom pid 110140
[20220506-15:07:05] [INFO ] Terminating X server (pid 110142) on dis
play 10
[20220506-15:07:05] [INFO ] Terminating the xrdp channel server (pid
 110146) on display 10
[20220506-15:07:05] [INFO ] X server on display 10 (pid 110142) retu
rned exit code 1 and signal number 0
[20220506-15:07:05] [INFO ] xrdp channel server for display 10 (pid
110146) exit code 0 and signal number 0
[20220506-15:07:05] [INFO ] cleanup_sockets:
[20220506-15:07:05] [INFO ] Process 110140 has exited
[20220506-15:07:05] [INFO ] ++ terminated session:  username nian, d
isplay :10.0, session_pid 110140, ip 192.168.1.23:47758 - socket: 12
[20220506-15:07:25] [ERROR] sesman_main_loop: trans_check_wait_objs
failed, removing trans

cat /home/nian/.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=startplasma-x11

# 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)
    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")
@AKA-nian
Copy link
Author

AKA-nian commented May 6, 2022

image

@matt335672
Copy link
Member

Your X server isn't starting:-

[20220506-15:06:55] [INFO ] Starting X server on display 10: Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
[20220506-15:07:04] [WARN ] Timed out waiting for X server on display 10 to startup

On Arch, you should be trying to run /usr/lib/Xorg rather than Xorg without a path.

Edit /etc/xrdp/sesman.ini, find the [Xorg] section and replace param=Xorg with param=/usr/lib/Xorg. Then sudo systemctl restart xrdp-sesman and try again.

@matt335672 matt335672 changed the title xrdp service cannot open pid file Arch Linux : Can't start Xorg X server May 6, 2022
@Bengt-M
Copy link

Bengt-M commented Jul 16, 2022

I have the same problem (on Manjaro)
param was already set

@matt335672
Copy link
Member

Find the line in /etc/xrdp/xrdp-sesman.log which looks like this:-

[INFO ] Starting X server on display 10: Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log

Run the command as displayed on the command line as the user you are trying to use with xrdp and see what happens. So for the line above, try entering this command:-

Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log

@Lifschitz
Copy link

Exactly the same problem here. xrdp is running as root and the above command works as root.

@matt335672
Copy link
Member

@Lifschitz - you shouldn't need to run the X server as root.

If the command you're entering is the same as the above (with no filepath for the X server), you will be running Xorg from the PATH. This isn't recommended for non-root users. See this comment above.

@mustafa58
Copy link

Same exact problem here when root user invokes command no problem but non-root users can not start session using Xorg.

@mustafa58
Copy link

[  5864.966] 
X.Org X Server 1.21.1.4
X Protocol Version 11, Revision 0
[  5864.966] Current Operating System: Linux endev 5.19.2-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 17 Aug 2022 13:48:51 +0000 x86_64
[  5864.966] Kernel command line: BOOT_IMAGE=/vmlinuz-linux root=UUID=62aa25e6-293e-425d-9ac6-86a0eb5cf453 rw resume=UUID=9b1b523f-6607-4358-8640-08ee3ef9de08 loglevel=3 nowatchdog nvme_load=YES video=hyperv_fb:1920x1080
[  5864.966]  
[  5864.966] Current version of pixman: 0.40.0
[  5864.966]    Before reporting problems, check http://wiki.x.org
        to make sure that you have the latest version.
[  5864.966] Markers: (--) probed, (**) from config file, (==) default setting,
        (++) from command line, (!!) notice, (II) informational,
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[  5864.967] (++) Log file: ".xorgxrdp.11.log", Time: Fri Aug 19 22:46:34 2022
[  5864.971] (++) Using config file: "/etc/X11/xrdp/xorg.conf"
[  5864.971] (==) Using config directory: "/etc/X11/xorg.conf.d"
[  5864.971] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[  5864.977] (**) Option "defaultserverlayout" "X11 Server"
[  5864.977] (**) ServerLayout "X11 Server"
[  5864.977] (**) |-->Screen "Screen (xrdpdev)" (0)
[  5864.977] (**) |   |-->Monitor "Monitor"
[  5864.977] (**) |   |-->Device "Video Card (xrdpdev)"
[  5864.977] (**) |   |-->GPUDevice "Card0"
[  5864.977] (**) |-->Input Device "xrdpMouse"
[  5864.977] (**) |-->Input Device "xrdpKeyboard"
[  5864.977] (**) Option "DontVTSwitch" "on"
[  5864.977] (**) Option "AutoAddDevices" "off"
[  5864.977] (**) Not automatically adding devices
[  5864.977] (==) Automatically enabling devices
[  5864.977] (==) Automatically adding GPU devices
[  5864.977] (==) Automatically binding GPU devices
[  5864.977] (==) Max clients allowed: 256, resource mask: 0x1fffff
[  5864.978] (WW) The directory "/usr/share/fonts/misc" does not exist.
[  5864.978]    Entry deleted from font path.
[  5864.994] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/TTF".
[  5864.995]    Entry deleted from font path.
[  5864.995]    (Run 'mkfontdir' on "/usr/share/fonts/TTF").
[  5864.995] (WW) The directory "/usr/share/fonts/OTF" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/Type1" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/100dpi" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/75dpi" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/misc" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/TTF".
[  5864.995]    Entry deleted from font path.
[  5864.995]    (Run 'mkfontdir' on "/usr/share/fonts/TTF").
[  5864.995] (WW) The directory "/usr/share/fonts/OTF" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/Type1" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/100dpi" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (WW) The directory "/usr/share/fonts/75dpi" does not exist.
[  5864.995]    Entry deleted from font path.
[  5864.995] (**) FontPath set to:

[  5864.995] (**) ModulePath set to "/usr/lib/xorg/modules"
[  5864.995] (II) Module ABI versions:
[  5864.995]    X.Org ANSI C Emulation: 0.4
[  5864.995]    X.Org Video Driver: 25.2
[  5864.995]    X.Org XInput driver : 24.4
[  5864.995]    X.Org Server Extension : 10.0
[  5864.996] (--) using VT number 2

[  5864.996] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[  5864.997] (II) xfree86: Adding drm device (/dev/dri/card0)
[  5864.997] (II) Platform probe for /sys/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A03:00/device:07/VMBUS:01/5620e0c7-8062-4dce-aeb7-520c7ef76171/drm/card0
[  5865.033] (--) PCI:*(0@0:8:0) 1414:5353:0000:0000 rev 0, Mem @ 0xf8000000/67108864, BIOS @ 0x????????/131072
[  5865.033] (WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)
[  5865.033] (II) "glx" will be loaded. This was enabled by default and also specified in the config file.
[  5865.033] (II) LoadModule: "dbe"
[  5865.033] (II) Module "dbe" already built-in
[  5865.033] (II) LoadModule: "ddc"
[  5865.033] (II) Module "ddc" already built-in
[  5865.033] (II) LoadModule: "extmod"
[  5865.033] (II) Module "extmod" already built-in
[  5865.033] (II) LoadModule: "glx"
[  5865.036] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[  5865.050] (II) Module glx: vendor="X.Org Foundation"
[  5865.050]    compiled for 1.21.1.4, module version = 1.0.0
[  5865.050]    ABI class: X.Org Server Extension, version 10.0
[  5865.050] (II) LoadModule: "int10"
[  5865.050] (II) Loading /usr/lib/xorg/modules/libint10.so
[  5865.099] (II) Module int10: vendor="X.Org Foundation"
[  5865.099]    compiled for 1.21.1.4, module version = 1.0.0
[  5865.099]    ABI class: X.Org Video Driver, version 25.2
[  5865.099] (II) LoadModule: "record"
[  5865.099] (II) Module "record" already built-in
[  5865.099] (II) LoadModule: "vbe"
[  5865.099] (II) Loading /usr/lib/xorg/modules/libint10.so
[  5865.099] (II) Module int10: vendor="X.Org Foundation"
[  5865.099]    compiled for 1.21.1.4, module version = 1.0.0
[  5865.099]    ABI class: X.Org Video Driver, version 25.2
[  5865.099] (II) LoadModule: "xorgxrdp"
[  5865.100] (II) Loading /usr/lib/xorg/modules/libxorgxrdp.so
[  5865.145] (II) Module XORGXRDP: vendor="X.Org Foundation"
[  5865.145]    compiled for 1.21.1.4, module version = 0.2.18
[  5865.145]    ABI class: X.Org Video Driver, version 25.2
[  5865.145] xorgxrdpSetup:
[  5865.145] (II) LoadModule: "fb"
[  5865.145] (II) Module "fb" already built-in
[  5865.145] (II) LoadModule: "xrdpdev"
[  5865.210] (II) Loading /usr/lib/xorg/modules/drivers/xrdpdev_drv.so
[  5865.243] (II) Module XRDPDEV: vendor="X.Org Foundation"
[  5865.243]    compiled for 1.21.1.4, module version = 0.2.18
[  5865.243]    ABI class: X.Org Video Driver, version 25.2
[  5865.243] xrdpdevSetup:
[  5865.244] (II) LoadModule: "fbdev"
[  5865.244] (II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
[  5865.244] (II) Module fbdev: vendor="X.Org Foundation"
[  5865.244]    compiled for 1.21.1.1, module version = 0.5.0
[  5865.244]    Module class: X.Org Video Driver
[  5865.244]    ABI class: X.Org Video Driver, version 25.2
[  5865.244] (II) LoadModule: "xrdpmouse"
[  5865.244] (II) Loading /usr/lib/xorg/modules/input/xrdpmouse_drv.so
[  5865.245] (II) Module XRDPMOUSE: vendor="X.Org Foundation"
[  5865.245]    compiled for 1.21.1.4, module version = 0.2.18
[  5865.245]    Module class: X.Org XInput Driver
[  5865.245]    ABI class: X.Org XInput driver, version 24.4
[  5865.245] rdpmousePlug:
[  5865.245] (II) LoadModule: "xrdpkeyb"
[  5865.245] (II) Loading /usr/lib/xorg/modules/input/xrdpkeyb_drv.so
[  5865.304] (II) Module XRDPKEYB: vendor="X.Org Foundation"
[  5865.304]    compiled for 1.21.1.4, module version = 0.2.18
[  5865.304]    Module class: X.Org XInput Driver
[  5865.304]    ABI class: X.Org XInput driver, version 24.4
[  5865.304] rdpkeybPlug:
[  5865.304] rdpIdentify:
[  5865.304] (II) XRDPDEV: driver for xrdp: XRDPDEV
[  5865.304] rdpDriverFunc: op 10
[  5865.304] (II) FBDEV: driver for framebuffer: fbdev
[  5865.304] (EE) 
Fatal server error:
[  5865.304] (EE) xf86OpenConsole: Cannot open virtual console 2 (Permission denied)
[  5865.304] (EE) 
[  5865.304] (EE) 
Please consult the The X.Org Foundation support 
         at http://wiki.x.org
 for help. 
[  5865.304] (EE) Please also check the log file at ".xorgxrdp.11.log" for additional information.
[  5865.304] (EE) 
[  5865.304] (WW) xf86CloseConsole: KDSETMODE failed: Bad file descriptor
[  5865.304] (WW) xf86CloseConsole: VT_GETMODE failed: Bad file descriptor
[  5865.304] (EE) Server terminated with error (1). Closing log file.

@mustafa58
Copy link

mustafa58 commented Aug 21, 2022

Soulution: /etc/X11/Xwrapper.config

allowed_users=anybody
needs_root_rights=yes

than add your user to do the input and video groups.
sudo usermod -aG tty,input,video username
than finally create a new udev rule under /etc/udev/rules.d/99-mytty.rules:
SUBSYSTEM=="tty", KERNEL=="tty[0-7]*", GROUP="tty", MODE="0660"
and finally use: udevadm control --reload-rules to reload rules.
These configuration will let your fbdev or modesetting drivers to write/read to virtual terminals.

@matt335672
Copy link
Member

Thanks for the links @mustafa58, and for taking the time to look into this.

I can only re-iterate that if you shouldn't need to edit /etc/X11/Xwrapper.config - see my comment above.

I think in your case, the X config appears to be loading a driver for a physical card too, which is why you're running in to the problems with the virtual console:-

[  5864.977] (**) ServerLayout "X11 Server"
[  5864.977] (**) |-->Screen "Screen (xrdpdev)" (0)
[  5864.977] (**) |   |-->Monitor "Monitor"
[  5864.977] (**) |   |-->Device "Video Card (xrdpdev)"
[  5864.977] (**) |   |-->GPUDevice "Card0"
[  5864.977] (**) |-->Input Device "xrdpMouse"
[  5864.977] (**) |-->Input Device "xrdpKeyboard"

On my (virtual) system, the corresponding lines are:-

[   506.744] (**) ServerLayout "X11 Server"
[   506.744] (**) |-->Screen "Screen (xrdpdev)" (0)
[   506.744] (**) |   |-->Monitor "Monitor"
[   506.745] (**) |   |-->Device "Video Card (xrdpdev)"
[   506.745] (**) |-->Input Device "xrdpMouse"
[   506.745] (**) |-->Input Device "xrdpKeyboard"

Most likely thing to my mind is that there's a file in /etc/X11/xorg.conf.d or /usr/share/X11/xorg.conf.d which is loading the GPUDevice.

As well as the GPUDevice setting in xorg.conf, there's a config setting called AutoAddGPU which was added for version 1.15 of the X server in December 2013. This is similar to AutoAddDevices, but applies to the GPUs.

Could you possibly try adding the line in bold below to your /etc/X11/xrdp/xorg.conf:-

Section "ServerFlags"
    # This line prevents "ServerLayout" sections in xorg.conf.d files
    # overriding the "X11 Server" layout (xrdp #1784)
    Option "DefaultServerLayout" "X11 Server"
    Option "DontVTSwitch" "on"
    Option "AutoAddDevices" "off"
    Option "AutoAddGPU" "off"
EndSection

If this works, it will be simpler than adding users to groups and changing udev rules, and we can add a quick fix to get this in to xrdp.

If it doesn't work, I'd like to see the X server log.

@matt335672
Copy link
Member

@mustafa58 - did adding the AutoAddGPU setting to the config file help?

Thanks.

@jknockel
Copy link

Hi @matt335672 , I am experiencing a similar issue as @mustafa58 . Adding Option "AutoAddGPU" "off" as you suggested didn't work for me. However, I found that adding GPUDevice "" right underneath Device "Video Card (xrdpdev)" in the "Screen" section fixed the problem. From some testing, it seems that this GPUDevice "" setting is needed because I have a "Device" section in one of the *.conf files in /etc/X11/xorg.conf.d/ . X must be seeing that and automatically adding the device specified in that section as a GPUDevice since it isn't the Device proper. Why Option "AutoAddGPU" "off" isn't working is less clear to me, but according to the documentation AutoAddGPU may only apply to devices added from the udev backend, not devices specified in *.conf files.

If you would like me to file a separate issue, post my logs, etc., please let me know.

@matt335672
Copy link
Member

Hi @jknockel

Thanks for that - it's very useful.

I'm tracking this under #2379 too - in the next few days (time permitting) I'll put together a PR to address both of these.

@matt335672
Copy link
Member

Fixed by neutrinolabs/xorgxrdp#241

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants