Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
KDE system tray icons missing
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
orionbelt
Apprentice
Apprentice


Joined: 05 Apr 2006
Posts: 178

PostPosted: Sat Oct 01, 2022 9:47 pm    Post subject: KDE system tray icons missing Reply with quote

When i launch kmix from a konsole during a KDE session, i get the following error message after a waiting time of a few minutes:
Code:
kf.dbusaddons: Couldn't register name 'org.kde.kmix' with DBUS - another process owns it already!

and kmix is not launched. However, this is just one symptom among many that i think are related in that there is a "lack of communication" with system tray applications. For instance, switching keyboard layout via the keyboard shortcut that i defined (Alt+Space) does work, but the keyboard layout widget does not change its language indication. In fact, sometimes the keyboard widget does not display at all, along with other missing system tray icons. Similarly, some applications that normally place an icon in the system tray (such as an audio player, e.g. deadbeef) fail to do so.

My situation is very similar to the one described here: https://forum.manjaro.org/t/applications-icon-missing-in-system-tray/109433 . I tried their suggestions:

  • I deleted all KDE-, plasma- and Qt-related files and directories in $HOME/.cache
  • rm $HOME/.config/Trolltech.conf
  • rm -r .dbus/ and restarted dbus
  • rm $HOME/.config/plasma-org.kde.plasma.desktop-appletsrc
  • rm $HOME/.config/kwinrc
  • kbuildsycoca5 --noincremental
  • Created a new user

Unfortunately, none of the above worked for me.

This is a rather debilitating situation as the working environment is quite severely degraded. Suggestions are appreciated!
Back to top
View user's profile Send private message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3879

PostPosted: Sun Oct 02, 2022 11:27 am    Post subject: Reply with quote

What is the output of
Code:

echo $XDG_RUNTIME_DIR
 ps -ef | grep -i kmix | awk '{ print $1 }'

Quote:

When i launch kmix from a konsole during a KDE session, i get the following error message after a waiting time of a few minutes:


Are you launching it as root or as your ordinary user?
_________________
:)
Back to top
View user's profile Send private message
orionbelt
Apprentice
Apprentice


Joined: 05 Apr 2006
Posts: 178

PostPosted: Sun Oct 02, 2022 5:32 pm    Post subject: Reply with quote

alamahant wrote:
What is the output of
Code:

echo $XDG_RUNTIME_DIR


Funny that you asked because when i type "kmix" in the terminal, i get the following message twice:
Code:
 QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-<my_username>'

and then it hangs for a few minutes before reporting the DBUS error message that i mentioned above. So i guess the answer to your question is not surprising:
Code:
%  echo $XDG_RUNTIME_DIR
XDG_RUNTIME_DIR: Undefined variable.

I had looked into the origin of this message before, but at the time it seemed innocuous to me, since it seemed to be finding its own solution (creating the directory in /tmp). Now that you mentioned it i looked it up again, and the references that i found are all from systemd users, where XDG_RUNTIME_DIR should be set by pam_systemd using logind but was not. However, i use OpenRC and i am not sure how this information translates to this case (elogind?)

alamahant wrote:
What is the output of
Code:

ps -ef | grep -i kmix | awk '{ print $1 }'

Code:
% ps -ef | grep -i kmix | awk '{ print $1 }'
<my_username>
<my_username>
<my_username>

where <my_username> is my username (not root). Also, in case it helps any:
Code:
% ps x | grep -i kmix
 8824 pts/9    S+     0:00 grep --color=auto kmix
28728 ?        S      0:00 /usr/bin/kmixctrl --restore
29281 ?        Sl     0:00 /usr/bin/kmix --keepvisibility

% kill -QUIT 28728 29281
% ps x | grep -i kmix
13325 pts/9    S+     0:00 grep --color=auto -i kmix
% kmix
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-<my_username>'
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-<my_username>'
percent 5 -> divisor 20

This is the first time i see this "percent 5 -> divisor 20" line. And now kmix just hangs there. I CTRL-C'd it after 10 minutes or so, and "ps x | grep kmix" returned empty, so nothing was launched.

alamahant wrote:
Quote:

When i launch kmix from a konsole during a KDE session, i get the following error message after a waiting time of a few minutes:


Are you launching it as root or as your ordinary user?

As my ordinary user. The entire KDE session is also launched from my ordinary user, of course.
Back to top
View user's profile Send private message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3879

PostPosted: Sun Oct 02, 2022 5:59 pm    Post subject: Reply with quote

Do you have a
Code:

ls /run/user/$UID

directory?
For some reason your kde is not exporting XDG_RUNTIME_DIR.
This is done via /etc/pam.d/elogind-user
Is elogind running?
Try
Code:

cat /etc/pam.d/elogind-user

Are you using systemd or openrc
What happens if in ~/.bashrc
you include
Code:

export XDG_RUNTIME_DIR="/run/user/$UID"

?
_________________
:)
Back to top
View user's profile Send private message
orionbelt
Apprentice
Apprentice


Joined: 05 Apr 2006
Posts: 178

PostPosted: Sun Oct 02, 2022 8:29 pm    Post subject: Reply with quote

You were spot on about elogind, something went wrong with it for some reason:
Code:
# rc-service elogind status
 * status: stopped
# rc-service elogind start
 * Starting elogind ...
 * start-stop-daemon: /lib64/elogind/elogind is already running           [ !! ]
 * ERROR: elogind failed to start
# rc-service elogind stop
 * WARNING: elogind is already stopped
# rc-service elogind zap
 * Manually resetting elogind to stopped state
(orb:~) # /etc/init.d/elogind status
 * status: stopped
(orb:~) # /etc/init.d/elogind start
 * Starting elogind ...
 * start-stop-daemon: /lib64/elogind/elogind is already running           [ !! ]
 * ERROR: elogind failed to start

# ps ax | grep elogind
 3384 ?        S      0:00 elogind-daemon
# kill -QUIT 3384
# ps ax | grep elogind
# rc-service elogind start
 * Starting elogind ...                                                   [ ok ]
# rc-service elogind status
 * status: started


At that point i logged off the KDE session to SDDM, and logged back in again. Now the problems you mentioned are fixed:
Code:
% echo $XDG_RUNTIME_DIR
/run/user/1000
% ls /run/user/
1000


However, my original problem is still not fixed. kmix does not hang forever and does not produce the "XDG_RUNTIME_DIR not set" anymore, but after a couple of minutes of waiting it issues the same error message:
Code:
% kmix
kf.dbusaddons: Couldn't register name 'org.kde.kmix' with DBUS - another process owns it already!
Back to top
View user's profile Send private message
orionbelt
Apprentice
Apprentice


Joined: 05 Apr 2006
Posts: 178

PostPosted: Fri Oct 07, 2022 10:39 pm    Post subject: Reply with quote

Code:
% kmix
kf.dbusaddons: Couldn't register name 'org.kde.kmix' with DBUS - another process owns it already!

% ps x|grep kmix
 3662 ?        S      0:00 /usr/bin/kmixctrl --restore
 4006 ?        Sl     0:00 /usr/bin/kmix --keepvisibility

% kill -QUIT 3662 4006
% ps x|grep kmix
% kmix
percent 5 -> divisor 20
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: Cannot load profile "PulseAudio.Playback_Devices.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Capture_Devices.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Playback_Streams.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Capture_Streams.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Playback_Devices.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Capture_Devices.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Playback_Streams.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Capture_Streams.1.default"
kf.notifications: env says KDE is running but SNI unavailable -- check KDE_FULL_SESSION and XDG_CURRENT_DESKTOP

<kmix hangs at this point, no output for several minutes>

% ps x|grep pulse
 4570 ?        Sl     0:00 pulseaudio -D
 4574 ?        Sl     0:00 /usr/libexec/pulse/gsettings-helper

% echo $KDE_FULL_SESSION
true

% echo $XDG_CURRENT_DESKTOP
KDE

Any suggestions about how to proceed from this point?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum