5

Some of my Gtk apps (Virt-Manager, Nautilus & Easytag) are really slow to start when I start them as a normal user. However when they are started as root, they start instantly. How can I fix that?

I run on spectrwm windows manger on Debian 10 and I start X from console and here's a copy of my xinitrc:

xrdb -load "${XDG_CONFIG_HOME:-$HOME/.config}/x11/xresources"
compton -b --config "${XDG_CONFIG_HOME:-$HOME/.config}/compton/compton.conf"
fehbg &
unclutter &
exec spectrwm

2 Answers2

2

Restart your X session after attempting these.

Attempt 1 (worked for me recently)

dbus-update-activation-environment --systemd DBUS_SESSION_BUS_ADDRESS DISPLAY XAUTHORITY

in .xinitrc (or whatever you X session file may be) before the exec line.

Attempt 2 (worked for me in the past)

I found this line in Arch Wiki:

Note: At the very least, ensure that the last if block in /etc/X11/xinit/xinitrc is present in your ~/.xinitrc

The last block of the file was:

. /etc/X11/Xsession

Assuming the same is true for you, add it to your ~/.xinitrc before the exec and see if it helps. For example:

xrdb -load "${XDG_CONFIG_HOME:-$HOME/.config}/x11/xresources"
compton -b --config "${XDG_CONFIG_HOME:-$HOME/.config}/compton/compton.conf"
fehbg &
unclutter &
. /etc/X11/Xsession
exec spectrwm

Additional links

Quasímodo
  • 18,625
  • 3
  • 35
  • 72
  • 1
    It made the trick but I it looses my keyboard layout. Now Gtk apps show faster but my azerty layout is switched to a qwerty layout. –  Jun 23 '20 at 11:08
  • I tried to add `setxkbmap -layout fr -model pc105 -variant latin9` in my `xinitrc` before `. /etc/X11/Xsession` but it does'nt take effect. –  Jun 23 '20 at 11:10
  • Not working either. But when I `killall xinit` and log back in it takes effect. –  Jun 23 '20 at 11:14
  • 1
    Is your keyboard set in `/etc/default/keyboard`? If not, I'd highly recommend it. – Quasímodo Jun 23 '20 at 11:17
  • Yes my keyboard is properly defined in `/etc/default/keyboard`. –  Jun 23 '20 at 11:19
  • No it is not working –  Jun 23 '20 at 12:01
  • How did you solve the issue? I had a similar issue and found all these unanswered questions such as yours here. What solved the issue for me was to remove old manually installed libs from `/usr/local/lib` (also see here: https://bugs.launchpad.net/ubuntu/+source/gvfs/+bug/1877135) – Juve Jan 25 '21 at 12:07
0

Well idk if it helps or If it helps anyone but still,

I found out that the gtk application conflict between portals So basically i am using wm and have a desktop for backup purposes I had 2 desktop portals xdg-desktop-portal-gnome and xdg-desktop-portal-gtk when i journalctl the system I found that the "Gnome desktop portal " was crashing so i basically removed xdg-desktop-portal-gnome and everything started working well