Closed mengsongshan closed 1 month ago
Thanks for raising this @mengsongshan
Can you post the chansrv log file when this happens? chansrv will generate better logs when it tries to start the ibus input method. If it can't start the method it signals to xrdp, which is where the this single line come from:-
8月 31 15:21:33 mycloud xrdp[1661]: [INFO ] [xrdp_mm_trans_process_unicode_ack(xrdp_mm.c:2496)] Chansrv reported an error starting the Unicode input method
Chansrv log is in ~/.local/share/xrdp/xrdp-chansrv.$D.log
where $D
is the display number.
@matt335672
I have a question. When using the ibus feature, only install the ibus? Do need some special settings? According to the logs, the interaction with the ibus is always faulty.
this is the xrdp-chansrv.$D.log
[2024-09-02T19:34:31.606+0800] [INFO ] [channel_thread_loop(chansrv.c:1533)] channel_thread_loop: trans_check_wait_objs error resetting
[2024-09-02T19:34:31.608+0800] [INFO ] [clipboard_deinit(clipboard.c:487)] clipboard_deinit:
[2024-09-02T19:34:31.623+0800] [INFO ] [scard_deinit(smartcard.c:335)] scard_deinit:
[2024-09-02T19:34:31.623+0800] [INFO ] [child_signal_handler(chansrv.c:1627)] child_signal_handler:
[2024-09-02T19:34:33.857+0800] [INFO ] [g_sck_accept(os_calls.c:1252)] Socket 15: connection accepted from AF_UNIX
[2024-09-02T19:34:33.859+0800] [INFO ] [clipboard_init(clipboard.c:343)] clipboard_init:
[2024-09-02T19:34:33.874+0800] [INFO ] [child_signal_handler(chansrv.c:1627)] child_signal_handler:
[2024-09-02T19:34:33.874+0800] [INFO ] [sound_init(sound.c:1276)] sound_init:
[2024-09-02T19:34:33.879+0800] [INFO ] [audin_init(audin.c:494)] audin_init:
[2024-09-02T19:34:33.881+0800] [INFO ] [xrdp_input_unicode_init(input_ibus.c:237)] xrdp_ibus_init: Initializing the iBus engine
[2024-09-02T19:34:33.884+0800] [ERROR] [xrdp_input_unicode_init(input_ibus.c:244)] xrdp_ibus_init: Connect to iBus failed
[2024-09-02T19:34:33.915+0800] [INFO ] [sound_process_output_format(sound.c:374)] sound_process_output_format:
[2024-09-02T19:34:33.918+0800] [INFO ] [sound_process_output_format(sound.c:375)] wFormatNo 0
[2024-09-02T19:34:33.919+0800] [INFO ] [sound_process_output_format(sound.c:376)] wFormatTag WAVE_FORMAT_PCM
[2024-09-02T19:34:33.921+0800] [INFO ] [sound_process_output_format(sound.c:377)] nChannels 2
[2024-09-02T19:34:33.923+0800] [INFO ] [sound_process_output_format(sound.c:378)] nSamplesPerSec 44100
[2024-09-02T19:34:33.924+0800] [INFO ] [sound_process_output_format(sound.c:379)] nAvgBytesPerSec 176400
[2024-09-02T19:34:33.926+0800] [INFO ] [sound_process_output_format(sound.c:380)] nBlockAlign 4
[2024-09-02T19:34:33.928+0800] [INFO ] [sound_process_output_format(sound.c:381)] wBitsPerSample 16
[2024-09-02T19:34:33.930+0800] [INFO ] [sound_process_output_format(sound.c:382)] cbSize 0
[2024-09-02T19:34:33.932+0800] [INFO ] [sound_process_output_format(sound.c:374)] sound_process_output_format:
[2024-09-02T19:34:33.933+0800] [INFO ] [sound_process_output_format(sound.c:375)] wFormatNo 1
[2024-09-02T19:34:33.935+0800] [INFO ] [sound_process_output_format(sound.c:376)] wFormatTag WAVE_FORMAT_PCM
[2024-09-02T19:34:33.937+0800] [INFO ] [sound_process_output_format(sound.c:377)] nChannels 2
[2024-09-02T19:34:33.939+0800] [INFO ] [sound_process_output_format(sound.c:378)] nSamplesPerSec 22050
[2024-09-02T19:34:33.941+0800] [INFO ] [sound_process_output_format(sound.c:379)] nAvgBytesPerSec 88200
[2024-09-02T19:34:33.945+0800] [INFO ] [sound_process_output_format(sound.c:380)] nBlockAlign 4
[2024-09-02T19:34:33.947+0800] [INFO ] [sound_process_output_format(sound.c:381)] wBitsPerSample 16
[2024-09-02T19:34:33.949+0800] [INFO ] [sound_process_output_format(sound.c:382)] cbSize 0
[2024-09-02T19:34:33.985+0800] [INFO ] [sound_process_training(sound.c:1044)] sound_process_training: round trip time 34
It looks like the ibus daemon for your session isn't running.
The ibus daemon isn't started by chansrv - it's started by the script /etc/X11/Xsession.d/70im-config_launch
when you start a session. Maybe that's not working.
Let's get a trace of that process.
Can you edit /etc/xrdp/startwm.sh
and add this line somewhere near the top:-
set -x
The next time you try to log in, you should have a lot of logging in ~/.xsession-errors
. Can you post that?
@matt335672
OKey, I add set -x at the top of the startwm.sh file. this is the content of the .xsession-errors file.
+++ date
++ echo 'Xsession: X session started for developer at 2024年 09月 03日 星期二 09:26:24 CST'
Xsession: X session started for developer at 2024年 09月 03日 星期二 09:26:24 CST
++ '[' '!' -d /etc/X11/Xsession.d ']'
+++ mktemp
++ WRITE_TEST=/tmp/tmp.GLKMmpYZ6g
++ echo '*'
++ rm -f /tmp/tmp.GLKMmpYZ6g
+++ run-parts --list /etc/X11/Xsession.d
++ SESSIONFILES='/etc/X11/Xsession.d/20dbus_xdg-runtime
/etc/X11/Xsession.d/20x11-common_process-args
/etc/X11/Xsession.d/30x11-common_xresources
/etc/X11/Xsession.d/35x11-common_xhost-local
/etc/X11/Xsession.d/40x11-common_xsessionrc
/etc/X11/Xsession.d/50x11-common_determine-startup
/etc/X11/Xsession.d/55gnome-session_gnomerc
/etc/X11/Xsession.d/60x11-common_xdg_path
/etc/X11/Xsession.d/70im-config_launch
/etc/X11/Xsession.d/75dbus_dbus-launch
/etc/X11/Xsession.d/90atk-adaptor
/etc/X11/Xsession.d/90gpg-agent
/etc/X11/Xsession.d/90qt-a11y
/etc/X11/Xsession.d/90x11-common_ssh-agent
/etc/X11/Xsession.d/90xbrlapi
/etc/X11/Xsession.d/95dbus_update-activation-env
/etc/X11/Xsession.d/99x11-common_start'
++ '[' -n '/etc/X11/Xsession.d/20dbus_xdg-runtime
/etc/X11/Xsession.d/20x11-common_process-args
/etc/X11/Xsession.d/30x11-common_xresources
/etc/X11/Xsession.d/35x11-common_xhost-local
/etc/X11/Xsession.d/40x11-common_xsessionrc
/etc/X11/Xsession.d/50x11-common_determine-startup
/etc/X11/Xsession.d/55gnome-session_gnomerc
/etc/X11/Xsession.d/60x11-common_xdg_path
/etc/X11/Xsession.d/70im-config_launch
/etc/X11/Xsession.d/75dbus_dbus-launch
/etc/X11/Xsession.d/90atk-adaptor
/etc/X11/Xsession.d/90gpg-agent
/etc/X11/Xsession.d/90qt-a11y
/etc/X11/Xsession.d/90x11-common_ssh-agent
/etc/X11/Xsession.d/90xbrlapi
/etc/X11/Xsession.d/95dbus_update-activation-env
/etc/X11/Xsession.d/99x11-common_start' ']'
++ set +e
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/20dbus_xdg-runtime
+++ '[' -z unix:path=/run/user/1000/bus ']'
+++ '[' -x /usr/bin/dbus-update-activation-environment ']'
+++ dbus-update-activation-environment --verbose --systemd DBUS_SESSION_BUS_ADDRESS DISPLAY XAUTHORITY
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting DISPLAY=:10.0
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/20x11-common_process-args
+++ case $# in
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/30x11-common_xresources
+++ '[' -d /etc/X11/Xresources ']'
+++ type xrdb
++++ run-parts --list /etc/X11/Xresources
+++ RESOURCEFILES=/etc/X11/Xresources/x11-common
+++ '[' -n /etc/X11/Xresources/x11-common ']'
+++ for RESOURCEFILE in $RESOURCEFILES
+++ xrdb -merge /etc/X11/Xresources/x11-common
+++ has_option allow-user-resources
++++ echo '# $Id: Xsession.options 189 2005-06-11 00:04:27Z branden $
#
# configuration options for /etc/X11/Xsession
# See Xsession.options(5) for an explanation of the available options.
allow-failsafe
allow-user-resources
allow-user-xsession
use-ssh-agent
use-session-dbus'
++++ tail -n 1
++++ grep -Eo '^(no-)?allow-user-resources\>'
+++ '[' allow-user-resources = allow-user-resources ']'
+++ return 0
+++ '[' -f /home/developer/.Xresources ']'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/35x11-common_xhost-local
+++ type xhost
++++ id -un
+++ xhost +si:localuser:developer
localuser:developer being added to access control list
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/40x11-common_xsessionrc
+++ '[' -r /home/developer/.xsessionrc ']'
+++ . /home/developer/.xsessionrc
++++ export GNOME_SHELL_SESSION_MODE=ubuntu
++++ GNOME_SHELL_SESSION_MODE=ubuntu
++++ export XDG_CURRENT_DESKTOP=ubuntu:GNOME
++++ XDG_CURRENT_DESKTOP=ubuntu:GNOME
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/50x11-common_determine-startup
+++ '[' -z '' ']'
+++ has_option allow-user-xsession
++++ echo '# $Id: Xsession.options 189 2005-06-11 00:04:27Z branden $
#
# configuration options for /etc/X11/Xsession
# See Xsession.options(5) for an explanation of the available options.
allow-failsafe
allow-user-resources
allow-user-xsession
use-ssh-agent
use-session-dbus'
++++ tail -n 1
++++ grep -Eo '^(no-)?allow-user-xsession\>'
+++ '[' allow-user-xsession = allow-user-xsession ']'
+++ return 0
+++ for STARTUPFILE in "$USERXSESSION" "$ALTUSERXSESSION"
+++ '[' -e /home/developer/.xsession ']'
+++ for STARTUPFILE in "$USERXSESSION" "$ALTUSERXSESSION"
+++ '[' -e /home/developer/.Xsession ']'
+++ '[' -z '' ']'
+++ '[' -x /usr/bin/x-session-manager ']'
+++ STARTUP=x-session-manager
+++ '[' -z x-session-manager ']'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/55gnome-session_gnomerc
+++ BASESTARTUP=x-session-manager
+++ BASESTARTUP=x-session-manager
+++ '[' x-session-manager = x-session-manager ']'
+++++ readlink /etc/alternatives/x-session-manager
++++ basename /usr/bin/gnome-session
+++ BASESTARTUP=gnome-session
+++ case "$BASESTARTUP" in
+++ GNOMERC=/home/developer/.gnomerc
+++ '[' -r /home/developer/.gnomerc ']'
+++ '[' -z /usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop ']'
+++ '[' -n '' ']'
+++ export XDG_DATA_DIRS
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/60x11-common_xdg_path
+++ DEFAULT_XDG_CONFIG_DIRS=/etc/xdg
+++ DEFAULT_XDG_DATA_DIRS=/usr/local/share/:/usr/share/
+++ '[' -n '' ']'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/70im-config_launch
+++ IMLAUNCH=/usr/bin/im-launch
+++ '[' '' = 1 ']'
+++ '[' -z '' ']'
+++ '[' -z '' ']'
+++ '[' -z '' ']'
+++ '[' -z '' ']'
+++ '[' -r /usr/share/im-config/xinputrc.common ']'
+++ IM_CONFIG_PHASE=1
+++ export IM_CONFIG_PHASE
+++ . /usr/share/im-config/xinputrc.common
++++ IM_CONFIG_VERSION=0.50-2ubuntu22.04.1
++++ IM_CONFIG_DATA=/usr/share/im-config/data
++++ IM_CONFIG_XINPUTRC_USR=/home/developer/.xinputrc
++++ IM_CONFIG_XINPUTRC_SYS=/etc/X11/xinit/xinputrc
++++ IM_CONFIG_DEFAULT=/etc/default/im-config
++++ IM_CONFIG_VERBOSE=false
++++ . gettext.sh
+++++ test 'X\t' = 'X\t'
+++++ echo=echo
+++++ test -z ''
+++++ case "$0" in
++++ TEXTDOMAIN=im-config
++++ export TEXTDOMAIN
++++ TEXTDOMAINDIR=/usr/share/locale/
++++ export TEXTDOMAINDIR
++++ IM_CONFIG_CURRENT_DESKTOP=ubuntu:GNOME
++++ '[' -z ubuntu:GNOME ']'
++++ '[' -r /etc/default/im-config ']'
++++ . /etc/default/im-config
+++++ IM_CONFIG_DEFAULT_MODE=auto
+++++ CJKV_DEFAULT_DESKTOP='*'
+++++ CJKV_LOCALES=zh_TW:zh_HK:zh_SG:zh_CN:ja_JP:ko_KR:vi_VN
+++++ IM_CONFIG_PREFERRED_RULE=zh_CN,fcitx5:zh_TW,fcitx5:zh_HK,fcitx5:zh_SG,fcitx5
+++++ DESKTOP_SETUP_IBUS=GNOME
+++++ sed -nr 's/LC_CTYPE=\"?([a-zA-Z_]*).*/\1/p'
+++++ locale
++++ IM_CONFIG_LC_CTYPE=zh_CN
+++++ echo zh_CN,fcitx5:zh_TW,fcitx5:zh_HK,fcitx5:zh_SG,fcitx5
+++++ sed -rn 's/(^|.*:)zh_CN,([^:]*)($|:.*$)/\2/p'
++++ IM_CONFIG_PREFERRED=fcitx5
+++ unset TEXTDOMAIN
+++ unset TEXTDOMAINDIR
+++ '[' -r /home/developer/.xinputrc ']'
+++ . /home/developer/.xinputrc
++++ run_im ibus
++++ IM_CONFIG_CODE=run_im
++++ '[' -r /usr/share/im-config/data/21_ibus.rc ']'
++++ . /usr/share/im-config/data/21_ibus.rc
+++++ find_match ubuntu:GNOME GNOME
+++++ local 'OLDIFS=
' R=1 X Y
+++++ IFS=:
+++++ '[' -n ubuntu:GNOME ']'
+++++ '[' -n GNOME ']'
+++++ for X in $1
+++++ for Y in $2
+++++ '[' '*' = GNOME ']'
+++++ '[' ubuntu = GNOME ']'
+++++ for X in $1
+++++ for Y in $2
+++++ '[' '*' = GNOME ']'
+++++ '[' GNOME = GNOME ']'
+++++ R=0
+++++ break 2
+++++ IFS='
'
+++++ return 0
+++++ '[' 1 = 1 ']'
+++++ '[' x11 = x11 ']'
+++++ GTK_IM_MODULE=ibus
+++++ return
++++ IM_CONFIG_NAME=ibus
++++ false
+++ export XMODIFIERS
+++ export GTK_IM_MODULE
+++ export QT_IM_MODULE
+++ export CLUTTER_IM_MODULE
+++ '[' -x /usr/bin/im-launch ']'
+++ STARTUP='/usr/bin/im-launch x-session-manager'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/75dbus_dbus-launch
+++ STARTDBUS=
+++ DBUSLAUNCH=/usr/bin/dbus-launch
+++ has_option use-session-dbus
++++ echo '# $Id: Xsession.options 189 2005-06-11 00:04:27Z branden $
#
# configuration options for /etc/X11/Xsession
# See Xsession.options(5) for an explanation of the available options.
allow-failsafe
allow-user-resources
allow-user-xsession
use-ssh-agent
use-session-dbus'
++++ tail -n 1
++++ grep -Eo '^(no-)?use-session-dbus\>'
+++ '[' use-session-dbus = use-session-dbus ']'
+++ return 0
+++ '[' -z unix:path=/run/user/1000/bus ']'
+++ '[' -n '' ']'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/90atk-adaptor
+++ add_module gail
+++ case :$GTK_MODULES: in
+++ '[' -z '' ']'
+++ GTK_MODULES=gail
+++ add_module atk-bridge
+++ case :$GTK_MODULES: in
+++ '[' -z gail ']'
+++ GTK_MODULES=gail:atk-bridge
+++ export GTK_MODULES
+++ '[' -x /usr/bin/dbus-update-activation-environment ']'
+++ dbus-update-activation-environment --verbose --systemd GTK_MODULES
dbus-update-activation-environment: setting GTK_MODULES=gail:atk-bridge
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/90gpg-agent
++++ gpgconf --list-dirs agent-socket
+++ agent_sock=/run/user/1000/gnupg/S.gpg-agent
+++ export GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
+++ GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
++++ gpgconf --list-options gpg-agent
++++ awk -F: '/^enable-ssh-support:/{ print $10 }'
+++ '[' -n '' ']'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/90qt-a11y
+++ QT_ACCESSIBILITY=1
+++ export QT_ACCESSIBILITY
+++ '[' -x /usr/bin/dbus-update-activation-environment ']'
+++ dbus-update-activation-environment --verbose --systemd QT_ACCESSIBILITY
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/90x11-common_ssh-agent
+++ STARTSSH=
+++ SSHAGENT=/usr/bin/ssh-agent
+++ SSHAGENTARGS=
+++ has_option use-ssh-agent
++++ echo '# $Id: Xsession.options 189 2005-06-11 00:04:27Z branden $
#
# configuration options for /etc/X11/Xsession
# See Xsession.options(5) for an explanation of the available options.
allow-failsafe
allow-user-resources
allow-user-xsession
use-ssh-agent
use-session-dbus'
++++ tail -n 1
++++ grep -Eo '^(no-)?use-ssh-agent\>'
+++ '[' use-ssh-agent = use-ssh-agent ']'
+++ return 0
+++ '[' -x /usr/bin/ssh-agent ']'
+++ '[' -z '' ']'
+++ STARTUP='/usr/bin/ssh-agent /usr/bin/im-launch x-session-manager'
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/90xbrlapi
+++ prefix=
+++ exec_prefix=
+++ program_directory=/bin
+++ xbrlapi=/bin/xbrlapi
+++ brltty=/bin/brltty
+++ '[' -x /bin/xbrlapi ']'
+++ /bin/xbrlapi
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/95dbus_update-activation-env
+++ '[' -n unix:path=/run/user/1000/bus ']'
+++ '[' -x /usr/bin/dbus-update-activation-environment ']'
+++ unset XDG_SEAT
+++ unset XDG_SESSION_ID
+++ unset XDG_VTNR
+++ dbus-update-activation-environment --verbose --systemd --all
dbus-update-activation-environment: setting SHELL=/bin/bash
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
dbus-update-activation-environment: setting GTK_IM_MODULE=ibus
dbus-update-activation-environment: setting HISTSIZE=10000
dbus-update-activation-environment: setting LANGUAGE=zh_CN:en
dbus-update-activation-environment: setting LC_ADDRESS=zh_CN.UTF-8
dbus-update-activation-environment: setting GNOME_SHELL_SESSION_MODE=ubuntu
dbus-update-activation-environment: setting LC_NAME=zh_CN.UTF-8
dbus-update-activation-environment: setting HISTTIMEFORMAT=%F %T developer
dbus-update-activation-environment: setting LC_MONETARY=zh_CN.UTF-8
dbus-update-activation-environment: setting GTK_MODULES=gail:atk-bridge
dbus-update-activation-environment: setting PWD=/home/developer
dbus-update-activation-environment: setting LOGNAME=developer
dbus-update-activation-environment: setting XDG_SESSION_TYPE=x11
dbus-update-activation-environment: setting GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
dbus-update-activation-environment: setting PULSE_SCRIPT=/etc/xrdp/pulse/default.pa
dbus-update-activation-environment: setting HOME=/home/developer
dbus-update-activation-environment: setting IM_CONFIG_PHASE=1
dbus-update-activation-environment: setting LC_PAPER=zh_CN.UTF-8
dbus-update-activation-environment: setting LANG=zh_CN.UTF-8
dbus-update-activation-environment: setting XDG_CURRENT_DESKTOP=ubuntu:GNOME
dbus-update-activation-environment: setting XRDP_SOCKET_PATH=/var/run/xrdp/1000
dbus-update-activation-environment: setting XRDP_PULSE_SOURCE_SOCKET=xrdp_chansrv_audio_in_socket_10
dbus-update-activation-environment: setting XDG_SESSION_CLASS=user
dbus-update-activation-environment: setting LC_IDENTIFICATION=zh_CN.UTF-8
dbus-update-activation-environment: setting USER=developer
dbus-update-activation-environment: setting XRDP_SESSION=1646
dbus-update-activation-environment: setting DISPLAY=:10.0
dbus-update-activation-environment: setting XRDP_PULSE_SINK_SOCKET=xrdp_chansrv_audio_out_socket_10
dbus-update-activation-environment: setting SHLVL=1
dbus-update-activation-environment: setting LC_TELEPHONE=zh_CN.UTF-8
dbus-update-activation-environment: setting LC_MEASUREMENT=zh_CN.UTF-8
dbus-update-activation-environment: setting XDG_RUNTIME_DIR=/run/user/1000
dbus-update-activation-environment: setting LC_TIME=zh_CN.UTF-8
dbus-update-activation-environment: setting XDG_DATA_DIRS=/usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop
dbus-update-activation-environment: setting PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting UID=1000
dbus-update-activation-environment: setting LC_NUMERIC=zh_CN.UTF-8
dbus-update-activation-environment: setting _=/usr/bin/dbus-update-activation-environment
++ for SESSIONFILE in $SESSIONFILES
++ . /etc/X11/Xsession.d/99x11-common_start
+++ exec /usr/bin/ssh-agent /usr/bin/im-launch x-session-manager
@matt335672
I found that two ibus processes were started on my system. I traced the startup processes and found that one was started by gnome-shell and the other by systemctl.
gdm 1544 1301 0 09:26 tty1 00:00:00 ibus-daemon --panel disable -r --xim
gdm 1557 1544 0 09:26 tty1 00:00:00 /usr/libexec/ibus-memconf
gdm 1563 1 0 09:26 tty1 00:00:00 /usr/libexec/ibus-x11 --kill-daemon
gdm 1568 1 0 09:26 tty1 00:00:00 /usr/libexec/ibus-portal
gdm 1581 1544 0 09:26 tty1 00:00:00 /usr/libexec/ibus-engine-simple
develop+ 1937 1648 0 09:26 ? 00:00:00 sh -c /usr/bin/ibus-daemon --panel disable $([ "$XDG_SESSION_TYPE" = "x11" ] && echo "--xim")
develop+ 1957 1937 0 09:26 ? 00:00:01 /usr/bin/ibus-daemon --panel disable --xim
develop+ 2039 1957 0 09:26 ? 00:00:00 /usr/libexec/ibus-memconf
develop+ 2041 1957 0 09:26 ? 00:00:01 /usr/libexec/ibus-extension-gtk3
develop+ 2053 1648 0 09:26 ? 00:00:00 /usr/libexec/ibus-x11 --kill-daemon
develop+ 2070 1648 0 09:26 ? 00:00:00 /usr/libexec/ibus-portal
develop+ 2143 1957 0 09:26 ? 00:00:00 /usr/libexec/ibus-engine-simple
develop+ 4171 3972 0 09:48 pts/1 00:00:00 vi 21_ibus.rc
develop+ 4203 4191 0 09:49 pts/2 00:00:00 grep --color=auto ibus
In addition, xrdp.log and syslog do not have logs in input_ibus.c. I suspect that xrdp_input_unicode_init is not called.
These are what I can think of, you see what else I can provide, and I'll provide you with the analysis of this problem.
I believe input_ibus.c only logs to the chansrv log.
The relevant ibus-daemon is the one owned by your user. That seems to be started OK.
We're starting to get out of my knowledge here. What happens when you run im-config
?
@mengsongshan - did you try running im-config
?
No further response - closing.
xrdp version
xrdp devel
Detailed xrdp version, build options
Operating system & version
Ubuntu 22.04 LTS Gnome 42.9 X11
Installation method
git clone & make install
Which backend do you use?
xorgxrdp
What desktop environment do you use?
Gnome
Environment xrdp running on
cloud ecs
What's your client?
guacamole
Area(s) with issue?
No response
Steps to reproduce
I use Guacamole as the client and XRDP as the server to access the ECS running the Ubuntu desktop system on my cloud.
Ubuntu installed the fcitx framework, uninstalled it, installed ibus, rebuilt the devel branch of xrdp, and enabled ibus. After installation is unstable, you need to refresh the guacamole page many times, that is, reconnect xrdp to enter Chinese normally, after a few days, I found that it was completely not good, refresh is useless.
Check the syslog to study the ibus-related code blocks in xrdp. It is found that the interaction between xrdp and ibus is abnormal. Once the problem was locked, I analyzed the detailed log, and sometimes "xrdp_ibus_init: Timed out waiting for iBus daemon" came up. After reading the code, I have checked the following problems: Check the ~/.config/ibus/bus/ directory. It is found that there are multiple files in the directory. The redundant files are deleted. The above error still occurs occasionally, so I adjusted the startup sequence of xrdp and ibus services so that ibus starts before xrdp. I found that it was much better. Later, I used ibus-setup to adjust the input method to Chinese input method. I found that it was much better and basically stable.
However, there is a small problem. Sometimes when you enter the system for the first time, you cannot enter Chinese. After you refresh the guacamole, you can enter the process.
This is the log when enter the system. You can enter ASCII characters , but can not Chinese characters.
✔️ Expected Behavior
Enter Chinese characters as you normally enter ASCII characters.
❌ Actual Behavior
Sometimes Chinese characters cannot be entered.
Anything else?
No response