LINUX.ORG.RU

Как победить xrdp в xfce debian 12

 ,


0

1

Линукс на вм. Ставлю с нуля xrdp. С винды подключение есть, логинюсь к xorg, допустим под root, почему рабочий стол запускается именно в консоли, а в терминале тишина? Под юзером даже в консоли ничего.



Последнее исправление: Dimez (всего исправлений: 2)
Ответ на: комментарий от einhander

Напиши четкую последовательность своих действий.

Чистый debian 12

useradd user -b /home -m -U -s /bin/sh

apt -y update
apt -y install tasksel
tasksel
apt -y install xrdp
systemctl is-enabled xrdp
systemctl status xrdp
mkdir -p /etc/xrdp/certs; cd /etc/xrdp/certs
openssl req -x509 -newkey rsa:2048 -nodes -keyout key.pem -out cert.pem -days 3650
chown -R xrdp:xrdp /etc/xrdp/certs
chmod 0644 /etc/xrdp/certs/cert.pem
chmod 0600 /etc/xrdp/certs/key.pem

nano /etc/xrdp/xrdp.ini
############### edit
security_layer=tls
certificate=/etc/xrdp/certs/cert.pem
key_file=/etc/xrdp/certs/key.pem
ssl_protocols=TLSv1.2, TLSv1.3
###############

systemctl restart xrdp

mstsc.exe

xorg -> user -> pass

пустой экран

Зачем?

Как факт. Работа будет через юзера.

tolikd
() автор топика
Последнее исправление: tolikd (всего исправлений: 3)

Попробуй погуглить! Проблема с черным экраном при подключении бывает даже при подключении Винда-Винда (нужно правильно настраивать клиент). А на Дебиане нужно править /etc/xrdp/startwm.sh - как описано, например, здесь - https://phoenixnap.com/kb/debian-remote-desktop или здесь - https://debianforum.ru/index.php?topic=16970.0
Ну и у xrdp лог файл есть: /var/log/xrdp.log и /var/log/xrdp-sesman.log - туда он пишет ошибки при подключении. Ты его не предоставил!

sigurd ★★★★★
()
Последнее исправление: sigurd (всего исправлений: 2)
Ответ на: комментарий от sigurd

По указанным ссылкам уже пробовал, та же проблема

xrdp.log

[20240716-06:48:10] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxxx
[20240716-06:48:10] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|HYBRID_EX|RDP], selected [SSL]
[20240716-06:48:11] [INFO ] Connected client computer name: xxxxxxxxx
[20240716-06:48:11] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
[20240716-06:48:11] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
[20240716-06:48:11] [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000419]
[20240716-06:48:11] [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [ru] options []
[20240716-06:48:11] [INFO ] TLS connection established from ::ffff:xx.xx.xx.xx port xxx: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384
[20240716-06:48:12] [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
[20240716-06:48:12] [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 5242880 MB cache entries 100
[20240716-06:48:12] [INFO ] xrdp_caps_process_codecs: nscodec, codec id 1, properties len 3
[20240716-06:48:12] [WARN ] xrdp_caps_process_codecs: unknown codec id 5
[20240716-06:48:12] [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
[20240716-06:48:12] [INFO ] Loading keymap file /etc/xrdp/km-00000419.ini
[20240716-06:48:12] [WARN ] local keymap file for 0x00000419 found and doesn't match built in keymap, using local keymap file
[20240716-06:48:29] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxx
[20240716-06:48:29] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxx
[20240716-06:48:29] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|HYBRID_EX|RDP], selected [SSL]
[20240716-06:48:29] [ERROR] libxrdp_force_read: header read error
[20240716-06:48:29] [ERROR] [ITU-T X.224] Connection Sequence: CR-TPDU (Connection Request) failed
[20240716-06:48:29] [ERROR] xrdp_sec_incoming: xrdp_iso_incoming failed
[20240716-06:48:29] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-06:48:29] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-06:48:29] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-06:48:29] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-06:48:29] [INFO ] Connected client computer name: xxxxxxxxx
[20240716-06:48:29] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
[20240716-06:48:29] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
[20240716-06:48:29] [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000409]
[20240716-06:48:29] [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [us] options []
[20240716-06:48:29] [INFO ] TLS connection established from ::ffff:xx.xx.xx.xx port xxx: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384
[20240716-06:48:30] [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
[20240716-06:48:30] [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 5242880 MB cache entries 100
[20240716-06:48:30] [INFO ] xrdp_caps_process_codecs: nscodec, codec id 1, properties len 3
[20240716-06:48:30] [WARN ] xrdp_caps_process_codecs: unknown codec id 5
[20240716-06:48:30] [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
[20240716-06:48:30] [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
[20240716-06:48:30] [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
[20240716-06:48:33] [INFO ] connecting to sesman on 127.0.0.1:xxxx
[20240716-06:48:33] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20240716-06:48:33] [INFO ] sesman connect ok
[20240716-06:48:33] [INFO ] sending login info to session manager. Please wait...
[20240716-06:48:33] [INFO ] xrdp_wm_log_msg: login successful for user user on display 10
[20240716-06:48:33] [INFO ] login successful for user user on display 10
[20240716-06:48:33] [INFO ] loaded module 'libxup.so' ok, interface size 10296, version 4
[20240716-06:48:33] [INFO ] started connecting
[20240716-06:48:33] [INFO ] lib_mod_connect: connecting via UNIX socket
[20240716-06:48:38] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxxx
[20240716-06:48:38] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|RDP], selected [SSL]
[20240716-06:48:38] [ERROR] SSL_accept: I/O error
[20240716-06:48:38] [ERROR] trans_set_tls_mode: ssl_tls_accept failed
[20240716-06:48:38] [ERROR] xrdp_sec_incoming: trans_set_tls_mode failed
[20240716-06:48:38] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-06:48:38] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-06:48:38] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-06:48:38] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-06:51:26] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxxx
[20240716-06:51:26] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|RDP], selected [SSL]
[20240716-06:51:26] [ERROR] SSL_accept: I/O error
[20240716-06:51:26] [ERROR] trans_set_tls_mode: ssl_tls_accept failed
[20240716-06:51:26] [ERROR] xrdp_sec_incoming: trans_set_tls_mode failed
[20240716-06:51:26] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-06:51:26] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-06:51:26] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-06:51:26] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-06:52:03] [INFO ] connection problem, giving up
[20240716-06:52:03] [INFO ] some problem
[20240716-06:52:03] [ERROR] xrdp_wm_log_msg: Error connecting to user session
[20240716-06:52:03] [INFO ] Error connecting to user session
[20240716-06:52:44] [ERROR] xrdp_sec_recv: xrdp_mcs_recv failed
[20240716-06:52:44] [ERROR] xrdp_rdp_recv: xrdp_sec_recv failed
[20240716-06:52:44] [ERROR] libxrdp_process_data: xrdp_rdp_recv failed
[20240716-06:52:44] [ERROR] xrdp_process_data_in: xrdp_process_loop failed
[20240716-06:53:00] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:xx.xx.xx.xx port xxx
[20240716-06:53:00] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|RDP], selected [SSL]
[20240716-06:53:00] [ERROR] SSL_accept: I/O error
[20240716-06:53:00] [ERROR] trans_set_tls_mode: ssl_tls_accept failed
[20240716-06:53:00] [ERROR] xrdp_sec_incoming: trans_set_tls_mode failed
[20240716-06:53:00] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-06:53:00] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-06:53:00] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-06:53:00] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed


tolikd
() автор топика
Последнее исправление: tolikd (всего исправлений: 1)
Ответ на: комментарий от sigurd

xrdp-sesman.log


[20240716-06:48:33] [INFO ] Socket 12: AF_INET6 connection received from ::1 port xxx
[20240716-06:48:33] [INFO ] Terminal Server Users group is disabled, allowing authentication
[20240716-06:48:33] [INFO ] ++ created session (access granted): username user, ip ::ffff:xx.xx.xx.xx:xx - socket: 12
[20240716-06:48:33] [INFO ] starting Xorg session...
[20240716-06:48:33] [INFO ] Starting session: session_pid 45326, display :10.0, width 1364, height 768, bpp 24, client ip ::ffff:xx.xx.xx.xx:xx - socket: 12, user name user
[20240716-06:48:33] [ERROR] sesman_data_in: scp_process_msg failed
[20240716-06:48:33] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans
[20240716-06:48:33] [INFO ] [session start] (display 10): calling auth_start_session from pid 45326
[20240716-06:48:34] [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  
[20240716-06:48:44] [WARN ] Timed out waiting for X server on display 10 to startup
[20240716-06:48:44] [INFO ] Session started successfully for user user on display 10
[20240716-06:48:44] [INFO ] Session in progress on display 10, waiting until the window manager (pid 45347) exits to end the session
[20240716-06:48:44] [INFO ] Starting the xrdp channel server for display 10
[20240716-06:48:44] [WARN ] Timed out waiting for X server on display 10 to startup
[20240716-06:48:44] [ERROR] There is no X server active on display 10
[20240716-06:48:44] [ERROR] A fatal error has occurred attempting to start the window manager on display 10, aborting connection
[20240716-06:48:44] [WARN ] Window manager (pid 45347, display 10) exited quickly (0 secs). This could indicate a window manager config problem
[20240716-06:48:44] [INFO ] Calling auth_stop_session and auth_end from pid 45326
[20240716-06:48:44] [INFO ] Terminating X server (pid 45348) on display 10
[20240716-06:48:44] [INFO ] Terminating the xrdp channel server (pid 45403) on display 10
[20240716-06:48:44] [INFO ] X server on display 10 (pid 45348) returned exit code 1 and signal number 0
[20240716-06:48:44] [INFO ] xrdp channel server for display 10 (pid 45403) exit code 0 and signal number 0
[20240716-06:48:44] [INFO ] cleanup_sockets:
[20240716-06:48:44] [INFO ] Process 45326 has exited
[20240716-06:48:44] [INFO ] ++ terminated session:  username user, display :10.0, session_pid 45326, ip ::ffff:xx.xx.xx.xx:xx - socket: 12

tolikd
() автор топика
Последнее исправление: tolikd (всего исправлений: 1)
Ответ на: комментарий от tolikd

Timed out waiting for X server on display 10 to startup

[20240716-06:48:44] [ERROR] There is no X server active on display 10

А иксы то у тебя вообще стартуют?

einhander ★★★★★
()
Последнее исправление: einhander (всего исправлений: 1)
Ответ на: комментарий от sigurd

Я уже понял, что иксы не открывались под юзером, нашел решение для /etc/X11/Xwrapper.config

allowed_users=anybody
needs_root_rights = yes 

Но проблема та же, иксы запустились только в консоли лог xrdp

xrdp.log

[20240716-12:30:08] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:x.x.x.x port x
[20240716-12:30:08] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:x.x.x.x port x
[20240716-12:30:08] [ERROR] libxrdp_force_read: header read error
[20240716-12:30:08] [ERROR] [ITU-T X.224] Connection Sequence: CR-TPDU (Connection Request) failed
[20240716-12:30:08] [ERROR] xrdp_sec_incoming: xrdp_iso_incoming failed
[20240716-12:30:08] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|HYBRID_EX|RDP], selected [SSL]
[20240716-12:30:08] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-12:30:08] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-12:30:08] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-12:30:08] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-12:30:08] [INFO ] Connected client computer name: xxx
[20240716-12:30:08] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
[20240716-12:30:08] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
[20240716-12:30:09] [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000419]
[20240716-12:30:09] [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [ru] options []
[20240716-12:30:09] [INFO ] TLS connection established from ::ffff:x.x.x.x port x: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384
[20240716-12:30:09] [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
[20240716-12:30:09] [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 5242880 MB cache entries 100
[20240716-12:30:09] [INFO ] xrdp_caps_process_codecs: nscodec, codec id 1, properties len 3
[20240716-12:30:09] [WARN ] xrdp_caps_process_codecs: unknown codec id 5
[20240716-12:30:09] [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
[20240716-12:30:09] [INFO ] Loading keymap file /etc/xrdp/km-00000419.ini
[20240716-12:30:09] [WARN ] local keymap file for 0x00000419 found and doesn't match built in keymap, using local keymap file
[20240716-12:30:16] [ERROR] xrdp_sec_recv: xrdp_mcs_recv failed
[20240716-12:30:16] [ERROR] xrdp_rdp_recv: xrdp_sec_recv failed
[20240716-12:30:16] [ERROR] libxrdp_process_data: xrdp_rdp_recv failed
[20240716-12:30:17] [ERROR] xrdp_process_data_in: xrdp_process_loop failed
[20240716-12:30:17] [ERROR] SSL_write: I/O error
[20240716-12:30:17] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-12:30:17] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-12:30:24] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:x.x.x.x port x
[20240716-12:30:24] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:x.x.x.x port x
[20240716-12:30:24] [ERROR] libxrdp_force_read: header read error
[20240716-12:30:24] [ERROR] [ITU-T X.224] Connection Sequence: CR-TPDU (Connection Request) failed
[20240716-12:30:24] [INFO ] Security protocol: configured [SSL], requested [SSL|HYBRID|HYBRID_EX|RDP], selected [SSL]
[20240716-12:30:24] [ERROR] xrdp_sec_incoming: xrdp_iso_incoming failed
[20240716-12:30:24] [ERROR] xrdp_rdp_incoming: xrdp_sec_incoming failed
[20240716-12:30:24] [ERROR] xrdp_process_main_loop: libxrdp_process_incoming failed
[20240716-12:30:24] [ERROR] xrdp_iso_send: trans_write_copy_s failed
[20240716-12:30:24] [ERROR] Sending [ITU T.125] DisconnectProviderUltimatum failed
[20240716-12:30:24] [INFO ] Connected client computer name: TOLIKPC
[20240716-12:30:24] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc006 is unknown (ignored)
[20240716-12:30:24] [WARN ] Received [MS-RDPBCGR] TS_UD_HEADER type 0xc00a is unknown (ignored)
[20240716-12:30:24] [INFO ] xrdp_load_keyboard_layout: Keyboard information sent by the RDP client, keyboard_type:[0x04], keyboard_subtype:[0x00], keylayout:[0x00000409]
[20240716-12:30:24] [INFO ] xrdp_load_keyboard_layout: model [] variant [] layout [us] options []
[20240716-12:30:24] [INFO ] TLS connection established from ::ffff:x.x.x.x port x: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384
[20240716-12:30:25] [INFO ] xrdp_caps_process_pointer: client supports new(color) cursor
[20240716-12:30:25] [INFO ] xrdp_process_offscreen_bmpcache: support level 1 cache size 5242880 MB cache entries 100
[20240716-12:30:25] [INFO ] xrdp_caps_process_codecs: nscodec, codec id 1, properties len 3
[20240716-12:30:25] [WARN ] xrdp_caps_process_codecs: unknown codec id 5
[20240716-12:30:25] [INFO ] xrdp_caps_process_codecs: RemoteFX, codec id 3, properties len 49
[20240716-12:30:25] [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
[20240716-12:30:25] [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
[20240716-12:30:31] [INFO ] connecting to sesman on 127.0.0.1:3350
[20240716-12:30:31] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20240716-12:30:31] [INFO ] sesman connect ok
[20240716-12:30:31] [INFO ] sending login info to session manager. Please wait...
[20240716-12:30:31] [INFO ] xrdp_wm_log_msg: login successful for user user on display 10
[20240716-12:30:31] [INFO ] login successful for user user on display 10
[20240716-12:30:31] [INFO ] loaded module 'libxup.so' ok, interface size 10296, version 4
[20240716-12:30:31] [INFO ] started connecting
[20240716-12:30:31] [INFO ] lib_mod_connect: connecting via UNIX socket
tolikd
() автор топика
Ответ на: комментарий от sigurd

xrdp-sesman.log

[20240716-12:30:31] [INFO ] Socket 12: AF_INET6 connection received from ::1 port 37948
[20240716-12:30:31] [INFO ] Terminal Server Users group is disabled, allowing authentication
[20240716-12:30:31] [INFO ] ++ created session (access granted): username user, ip ::ffff:x.x.x.x:x - socket: 12
[20240716-12:30:31] [INFO ] starting Xorg session...
[20240716-12:30:31] [INFO ] Starting session: session_pid 634, display :10.0, width 1364, height 768, bpp 24, client ip ::ffff:x.x.x.x:x - socket: 12, user name user
[20240716-12:30:31] [ERROR] sesman_data_in: scp_process_msg failed
[20240716-12:30:31] [INFO ] [session start] (display 10): calling auth_start_session from pid 634
[20240716-12:30:31] [ERROR] sesman_main_loop: trans_check_wait_objs failed, removing trans
[20240716-12:30:31] [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  
[20240716-12:30:41] [WARN ] Timed out waiting for X server on display 10 to startup
[20240716-12:30:41] [INFO ] Session started successfully for user user on display 10
[20240716-12:30:41] [INFO ] Session in progress on display 10, waiting until the window manager (pid 654) exits to end the session
[20240716-12:30:41] [INFO ] Starting the xrdp channel server for display 10
[20240716-12:30:41] [WARN ] Timed out waiting for X server on display 10 to startup
[20240716-12:30:41] [ERROR] There is no X server active on display 10
[20240716-12:30:41] [ERROR] A fatal error has occurred attempting to start the window manager on display 10, aborting connection
[20240716-12:30:41] [WARN ] Window manager (pid 654, display 10) exited quickly (0 secs). This could indicate a window manager config problem
[20240716-12:30:41] [INFO ] Calling auth_stop_session and auth_end from pid 634
[20240716-12:30:41] [INFO ] Terminating X server (pid 655) on display 10
[20240716-12:30:41] [INFO ] Terminating the xrdp channel server (pid 708) on display 10
[20240716-12:30:41] [INFO ] X server on display 10 (pid 655) returned exit code 1 and signal number 0
[20240716-12:30:41] [INFO ] xrdp channel server for display 10 (pid 708) exit code 0 and signal number 0
[20240716-12:30:41] [INFO ] cleanup_sockets:
[20240716-12:30:41] [INFO ] Process 634 has exited
[20240716-12:30:41] [INFO ] ++ terminated session:  username user, display :10.0, session_pid 634, ip ::ffff:x.x.x.x:x - socket: 12

tolikd
() автор топика