XFCE+XRDP闪退

张开发
2026/4/6 11:15:48 15 分钟阅读

分享文章

XFCE+XRDP闪退
ubuntu 24安装了输入法fcitx5 结果冲突一直进不去直接闪退。后来查看了xrdp.ini有几项设置。[Xorg]nameXorg liblibxup.so usernameask passwordask ip127.0.0.1port3389← 这是错的 code20[Xvnc]nameXvnc liblibvnc.so usernameask passwordask ip127.0.0.1port3389← 错误3389 是 RDP 远程连接端口Xorg 后台会话 不能用 3389必须用 port-1写错会直接导致输密码 → 黑屏 → 闪退同时可考虑crypt_levelmedium# 原来是 crypt_levelhigh覆盖后执行命令sudosystemctl restart xrdpsudosystemctl restart xrdp-sesman附一个完整的xrdp.ini配置[Globals];xrdp.inifileversion numberini_version1;fork a new processforeach incoming connectionforktrue;ports to listen on, number alone means listen on all interfaces;0.0.0.0 or ::ifipv6 is configured;space between multiple occurrences;ALL specified interfaces must be UP when xrdp starts, otherwise xrdp will fail to start;;Examples:;port3389;portunix://./tmp/xrdp.socket;porttcp://.:3389127.0.0.1:3389;porttcp://:3389 *:3389;porttcp://any ipv4formataddr:3389192.168.1.1:3389;porttcp6://.:3389 ::1:3389;porttcp6://:3389 *:3389;porttcp6://{any ipv6formataddr}:3389{FC00:0:0:0:0:0:0:1}:3389;portvsock://cid:portport3389;portabove should be connected to with vsock instead of tcp;use this only with number aloneinport above;prefer use vsock://cid:portaboveuse_vsockfalse;regulateifthe listening socket use socket option tcp_nodelay;no buffering will be performedinthe TCP stacktcp_nodelaytrue;regulateifthe listening socket use socket option keepalive;ifthe network connection disappear without close messages the connection will be closedtcp_keepalivetrue;settcp send/recv buffer(for experts)#tcp_send_buffer_bytes32768#tcp_recv_buffer_bytes32768;security layer can betls,rdpornegotiate;forclient compatible layersecurity_layernegotiate;minimum security level allowedforclientforclassic RDP encryption;use tls_ciphers to configure TLS encryption;can benone,low,medium,high,fipscrypt_levelmedium;X.509 certificate and private key;openssl req-x509-newkeyrsa:2048-nodes-keyoutkey.pem-outcert.pem-days365;note this needs the user xrdp to be a member of the ssl-cert group,dowith e.g.;$sudoadduser xrdp ssl-certcertificatekey_file;setSSL protocols;can be comma separated list ofSSLv3,TLSv1,TLSv1.1,TLSv1.2,TLSv1.3ssl_protocolsTLSv1.2, TLSv1.3;setTLS cipher suites#tls_ciphersHIGH;concats the domain name to the userifsetforauthentication with the separator;forexample when the server is multi homed with SSSd#domain_user_separator;The following options will override the keyboard layout settings.;These options areforDEBUG and are not recommendedforregular use.#xrdp.override_keyboard_type0x04#xrdp.override_keyboard_subtype0x01#xrdp.override_keylayout0x00000409;Section name to useforautomatic loginifthe client sends username;and password. If empty, the domain name sent by the client is used.;If empty and no domain name is given, the first suitable sectionin;thisfilewill be used.autorunallow_channelstrueallow_multimontruebitmap_cachetruebitmap_compressiontruebulk_compressiontrue#hidelogwindowtruemax_bpp32new_cursorstrue;fastpath - can beinput,output,both,noneuse_fastpathboth;when true, userid/password *must* be passed on cmd line#require_credentialstrue;when true, the userid will be used to try to authenticate#enable_token_logintrue;You cansetthe PAM error textina gateway setup(MAX256chars)#pamerrortxtchange your password according to policy at http://url;;colors used by windowsinRGBformat;blue009cb5greydedede#black000000#dark_grey808080#blue08246b#dark_blue08246b#whiteffffff#redff0000#green00ff00#background626c72;;configure loginscreen;;Login Screen Window Title#ls_titleMy Login Title;toplevel window background colorinRGBformatls_top_window_bg_color009cb5;width and height of loginscreen;;The default height allowsforabout5fields to be comfortably displayed;above the buttons at the bottom. To displaymorefields,makels_height;larger, and also increasels_btn_ok_y_posandls_btn_cancel_y_pos;below;ls_width350ls_height430;loginscreenbackground colorinRGBformatls_bg_colordedede;optional background image filename. BMPformatis always supported,;but other formats will be supportedifxrdp is build with imlib2;The transform can be one of the following:-;none:No transformation. Image is placedinbottom-right corner;of the screen.;scale:Image is scaled to thescreensize. The image aspect;ratio is not preserved.;zoom:Image is scaled to thescreensize. The image aspect;ratio is preserved by clipping the image.#ls_background_image#ls_background_transformnone;logo;full path tofileorfileinshared folder. BMPformatis always supported,;but other formats will be supportedifxrdp is build with imlib2;For transform values, seels_background_transform.The logo width and;logo height are ignoredfora transform ofnone.ls_logo_filename#ls_logo_transformnone#ls_logo_width240#ls_logo_height140ls_logo_x_pos55ls_logo_y_pos50;forpositioning labels such as username, password etcls_label_x_pos30ls_label_width65;forpositioning text and combo boxes next to above labelsls_input_x_pos110ls_input_width210;y posforfirst label and combo boxls_input_y_pos220;OK buttonls_btn_ok_x_pos142ls_btn_ok_y_pos370ls_btn_ok_width85ls_btn_ok_height30;Cancel buttonls_btn_cancel_x_pos237ls_btn_cancel_y_pos370ls_btn_cancel_width85ls_btn_cancel_height30[Logging];Note: Log levels can be any of: core, error, warning, info, debug, or traceLogFilexrdp.logLogLevelINFOEnableSyslogtrue#SyslogLevelINFO#EnableConsolefalse#ConsoleLevelINFO#EnableProcessIdfalse[LoggingPerLogger];Note: per logger configuration is only usedifxrdp is built with;--enable-devel-logging#xrdp.cINFO#main()INFO[Channels];Channel names not listed here will be blocked by XRDP.;You can block any channel by setting its value to false.;IMPORTANT!All channels are not supportedinall use;cases evenifyousetall values to true.;You can override these settings on each sessiontype;These settings are only usedifallow_channelstruerdpdrtruerdpsndtruedrdynvctruecliprdrtruerailtruexrdpvrtruetcutilstrue;fordebugging xrdp,insection xrdp1, changeport-1 to this:#port/tmp/.xrdp/xrdp_display_10;;Session types;;Some session types such as Xorg, X11rdp and Xvnc start a display server.;Startup command-line parametersforthe display server are configured;insesman.ini. See and configure also sesman.ini.[Xorg]nameXorgliblibxup.sousernameaskpasswordaskip127.0.0.1port-1code20[Xvnc]nameXvncliblibvnc.sousernameaskpasswordaskip127.0.0.1port-1#xserverbpp24#delay_ms2000;Disable requested encodings to support buggy VNC servers;(1ExtendedDesktopSize)#disabled_encodings_mask0;Use this to connect to a chansrv instance created outside of sesman;(e.g. as part of an x11vnc console session). Replace0with the;display number of the session#chansrvportDISPLAY(0);Generic VNC Proxy;Tailor this to specific hosts and VNC instances by specifying anip;and port and setting a suitable name.[vnc-any]namevnc-anyliblibvnc.soipaskportask5900usernamenapasswordask#pamusernameasksame#pampasswordasksame#pamsessionmng127.0.0.1#delay_ms2000;Generic RDP proxy using NeutrinoRDP;Tailor this to specific hosts by specifying anipand port and setting;a suitable name.[neutrinordp-any]nameneutrinordp-any;To use this section, you should build xrdp with configure option;--enable-neutrinordp.liblibxrdpneutrinordp.soipaskportask3389usernameaskpasswordask;Uncomment the following lines toenablePAM authenticationforproxy;connections.#pamusernameask#pampasswordask#pamsessionmng127.0.0.1;Currently NeutrinoRDP doesnt support dynamic resizing. Uncomment ; this line if youre using a clientwhichdoes.#enable_dynamic_resizingfalse;By default, performance settings requested by the RDP client are ignored;and chosen by NeutrinoRDP. Uncomment this line to allow the user to;selectperformance settingsinthe RDP client.#perf.allow_client_experiencesettingstrue;Override any experience setting by uncommenting one ormoreof the;following lines.#perf.wallpaperfalse#perf.font_smoothingfalse#perf.desktop_compositionfalse#perf.full_window_dragfalse#perf.menu_animsfalse#perf.themesfalse#perf.cursor_blinkfalse;By default NeutrinoRDP supports cursor shadows. If this is giving;you problems(e.g. cursor is a black rectangle)try disabling cursor;shadows by uncommenting the following line.#perf.cursor_shadowfalse;By default, NeutrinoRDP uses the keyboard layout of the remote RDP Server.;If you want to tell the remote the keyboard layout of the RDP Client,;by uncommenting the following line.#neutrinordp.allow_client_keyboardLayouttrue;The following options will override the remote keyboard layout settings.;These options areforDEBUG and are not recommendedforregular use.#neutrinordp.override_keyboardLayout_mask0x0000FFFF#neutrinordp.override_kbd_type0x04#neutrinordp.override_kbd_subtype0x01#neutrinordp.override_kbd_fn_keys12#neutrinordp.override_kbd_layout0x00000409;You can override the common channel settingsforeach sessiontype#channel.rdpdrtrue#channel.rdpsndtrue#channel.drdynvctrue#channel.cliprdrtrue#channel.railtrue#channel.xrdpvrtrue

更多文章