You are not logged in.

#1 2017-06-15 08:40:59

scippio
Member
Registered: 2007-01-02
Posts: 74

[SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Everthing is more slower and some applications cannot start and throw this error (for example terminator):

dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NotSupported: Using X11 for dbus-daemon autolaunch was disabled at compile time, set your DBUS_SESSION_BUS_ADDRESS instead

Last edited by scippio (2017-06-22 13:22:27)


Sorry for my English...

Offline

#2 2017-06-15 08:50:59

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

More information required: version numbers, what DE/WM, how you start X/Wayland, what is in your logs/journal, etc.

Please read How To Ask Questions The Smart Way.



Moving to NC...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2017-06-15 09:21:59

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

I starting by:

startx

and using fluxbox.
My .xinitrc:

#!/bin/sh

# ...

dbus-launch startfluxbox

My ~/fluxbox/startup:

!/bin/sh
#
# fluxbox startup-script:
#
# Lines starting with a '#' are ignored.

# Change your keymap:
#xmodmap "/home/scippio/.Xmodmap"

# Applications you want to run with fluxbox.
# MAKE SURE THAT APPS THAT KEEP RUNNING HAVE AN ''&'' AT THE END.
#
# unclutter -idle 2 &
# wmnd &
# wmsmixer -w &
# idesk &

dbus-launch nm-applet &
dbus-launch pasystray &
dbus-launch blueman-applet &
dropbox &

# And last but not least we start fluxbox.
# Because it is the last app you have to run it with ''exec'' before it.

exec dbus-launch fluxbox
# or if you want to keep a log:
# exec fluxbox -log "/home/scippio/.fluxbox/log"

versions:

fluxbox --version
Fluxbox 1.3.7 : (c) 2001-2015 Fluxbox Team

pacman -Qn | grep xorg
xorg-appres 1.0.4-1
xorg-bdftopcf 1.0.5-1
xorg-font-util 1.3.1-1
xorg-font-utils 7.6-4
xorg-fonts-alias 1.0.3-1
xorg-fonts-encodings 1.0.4-4
xorg-fonts-misc 1.0.3-5
xorg-luit 1.1.1-2
xorg-mkfontdir 1.0.7-8
xorg-mkfontscale 1.1.2-1
xorg-server 1.19.3-2
xorg-server-common 1.19.3-2
xorg-server-xephyr 1.19.3-2
xorg-server-xvfb 1.19.3-2
xorg-server-xwayland 1.19.3-2
xorg-setxkbmap 1.3.1-1
xorg-xauth 1.0.10-1
xorg-xbacklight 1.2.1-1
xorg-xev 1.2.2-1
xorg-xhost 1.0.7-1
xorg-xinit 1.3.4-4
xorg-xinput 1.6.2-1
xorg-xkbcomp 1.4.0-1
xorg-xmessage 1.0.4-2
xorg-xmodmap 1.0.9-1
xorg-xrandr 1.5.0-1
xorg-xrdb 1.1.0-2
xorg-xset 1.2.3-1

Applet Network Manager: 1.8.2

I discover that dbus-launch <app> helps with many apps (you can seen dbus-launch in many places now). And I use

dbus-launch startx

now.

There's still a one problem: nm-applet starts and I don't have a permissions to on/off wifi/network now sad
660504ee1e79a88b920272911155a326.png

Last edited by scippio (2017-06-15 09:25:00)


Sorry for my English...

Offline

#4 2017-06-15 09:32:01

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,756

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Don't use dbus-launch to just randomly start stuff it breaks your session bus (remove it everywhere you manually added it), post your whole .xinitrc not just a truncated part (hint: it has to look like /etc/X11/xinit/xinitrc as that will correctly setup dbus without the need of 100 dbus-launches,, except for the last few lines where you can replace the clock and the terminals with

exec fluxbox #or your script you have there

your last problem is a direct consequence of creating a new dbus-sessions for everything. Don't use dbus-launch like that . The scripts you aren't sourcing from xinitrc will set up your session correctly, by using dbus-launch you are directly contradicting the correct setup that would happen if you were doing that.

Last edited by V1del (2017-06-15 09:37:01)

Offline

#5 2017-06-15 09:34:57

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

My full .xinitrc

#!/bin/sh
#
# ~/.xinitrc
#

# Executed by startx (run your window manager from here)

# if [ -d /etc/X11/xinit/xinitrc.d ]; then
#  for f in /etc/X11/xinit/xinitrc.d/*; do
#    [ -x "$f" ] && . "$f"
#  done
#  unset f
# fi

# Executed by startx (run your window manager from here)
# export PATH="/usr/lib/icecream/bin:$PATH"

dbus-launch startfluxbox

My /etc/X11/xinit/xinitrc

#!/bin/sh

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap

# merge in defaults and keymaps

if [ -f $sysresources ]; then







    xrdb -merge $sysresources

fi

if [ -f $sysmodmap ]; then
    xmodmap $sysmodmap
fi

if [ -f "$userresources" ]; then







    xrdb -merge "$userresources"

fi

if [ -f "$usermodmap" ]; then
    xmodmap "$usermodmap"
fi

# start some nice programs

if [ -d /etc/X11/xinit/xinitrc.d ] ; then
 for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
  [ -x "$f" ] && . "$f"
 done
 unset f
fi

twm &
xclock -geometry 50x50-1+1 &
xterm -geometry 80x50+494+51 &
xterm -geometry 80x20+494-0 &
exec xterm -geometry 80x66+0+0 -name login

Sorry for my English...

Offline

#6 2017-06-15 09:39:10

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,756

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

And as mentioned, and as evident

# if [ -d /etc/X11/xinit/xinitrc.d ]; then
#  for f in /etc/X11/xinit/xinitrc.d/*; do
#    [ -x "$f" ] && . "$f"
#  done
#  unset f
# fi

Why are these commented out? they are essential to be ran and they will obsolete every invocation of dbus-launch you are using so far.

Last edited by V1del (2017-06-15 09:39:45)

Offline

#7 2017-06-15 09:46:51

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Ok... thanks all for help. I removed all dbus-launch and uncommented that ~/.xinitrc part....  I starting my X by: dbus-launch startx now. Everything looks fine but still have the last problem with nm-applet. Options in nm-applet are enabled when I start it with root permissions...

Last edited by scippio (2017-06-15 09:47:40)


Sorry for my English...

Offline

#8 2017-06-15 10:39:59

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,756

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

no, run startx with startx do not use dbus-launch  and do not run nm-applet as root (and if you haven't done so already, enable the NetworkManager.service instead)

Last edited by V1del (2017-06-15 10:42:29)

Offline

#9 2017-06-15 11:06:41

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

My NetworkManager is running.
But if I startx without dbus-launch I have same errors from my first post...


Sorry for my English...

Offline

#10 2017-06-15 11:57:27

loqs
Member
Registered: 2014-03-06
Posts: 17,417

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

What is the output of

$ printenv DBUS_SESSION_BUS_ADDRESS

Can you also check the user session is valid see General_troubleshooting#Session_permissions.

Offline

#11 2017-06-15 22:02:37

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

unix:abstract=/tmp/dbus-Ba38MvcaTu,guid=b68eb19d2a131c67935d218559426a91
loginctl show-session $XDG_SESSION_ID

EnableWallMessages=no
NAutoVTs=6
KillUserProcesses=no
RebootToFirmwareSetup=no
IdleHint=yes
IdleSinceHint=1497524880800667
IdleSinceHintMonotonic=6574866527
DelayInhibited=sleep
InhibitDelayMaxUSec=5s
HandlePowerKey=poweroff
HandleSuspendKey=suspend
HandleHibernateKey=hibernate
HandleLidSwitch=hibernate
HandleLidSwitchDocked=ignore
HoldoffTimeoutUSec=30s
IdleAction=ignore
IdleActionUSec=30min
PreparingForShutdown=no
PreparingForSleep=no
Docked=no
RemoveIPC=yes
RuntimeDirectorySize=816230400
InhibitorsMax=8192
NCurrentInhibitors=1
SessionsMax=8192
NCurrentSessions=1
UserTasksMax=10813

Sorry for my English...

Offline

#12 2017-06-15 22:10:13

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,593

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

"unix:abstract=/tmp/dbus-Ba38MvcaTu,guid=b68eb19d2a131c67935d218559426a91" means that you're STILL using dbus-launch.

Online

#13 2017-06-15 22:16:16

loqs
Member
Registered: 2014-03-06
Posts: 17,417

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

DBUS_SESSION_BUS_ADDRESS should be of the form unix:path=/run/user/####/bus where #### is the users UID.
loginctl show-session $XDG_SESSION_ID is lacking output entries Remote=no and Active=Yes indicating the user session is broken possibly connected to the other issue.
Were the outputs of these commands taken from a graphical terminal run from a startx launched with dbus-launch?  If so please run the commands again after logging directly into a terminal and see if the outputs change.
If not how do you login?  Is there any use of dbus-launch in any of your startup files?

Offline

#14 2017-06-15 22:53:28

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,593

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Shot in the dark here, do you have anything gnupg related in ~/.config/systemd/user/*?

Online

#15 2017-06-16 07:43:21

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Scimmia wrote:

"unix:abstract=/tmp/dbus-Ba38MvcaTu,guid=b68eb19d2a131c67935d218559426a91" means that you're STILL using dbus-launch.

Yes, because I wrote: " if I startx without dbus-launch I have same errors from my first post..." ... so I still using: dbus-launch startx ...

Scimmia wrote:

Shot in the dark here, do you have anything gnupg related in ~/.config/systemd/user/*?

yes:

ls ~/.config/systemd/user/
default.target.wants  gpg-agent.service
loqs wrote:

DBUS_SESSION_BUS_ADDRESS should be of the form unix:path=/run/user/####/bus where #### is the users UID.
loginctl show-session $XDG_SESSION_ID is lacking output entries Remote=no and Active=Yes indicating the user session is broken possibly connected to the other issue.
Were the outputs of these commands taken from a graphical terminal run from a startx launched with dbus-launch?  If so please run the commands again after logging directly into a terminal and see if the outputs change.
If not how do you login?  Is there any use of dbus-launch in any of your startup files?

Yes, it's from graphical terminal (from dbus-launch startx). So before I started X I have DBUS_SESSION_BUS_ADDRESS empty. (my dbus service running...)

Last edited by scippio (2017-06-16 08:10:45)


Sorry for my English...

Offline

#16 2017-06-16 08:56:04

seth
Member
Registered: 2012-09-03
Posts: 51,567

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

scippio wrote:
Scimmia wrote:

"unix:abstract=/tmp/dbus-Ba38MvcaTu,guid=b68eb19d2a131c67935d218559426a91" means that you're STILL using dbus-launch.

Yes, because I wrote: " if I startx without dbus-launch I have same errors from my first post..." ... so I still using: dbus-launch startx ...

You will *never* get it running this way - abort that approach and focus on the actual problem.

scippio wrote:
Scimmia wrote:

Shot in the dark here, do you have anything gnupg related in ~/.config/systemd/user/*?

yes:

ls ~/.config/systemd/user/
default.target.wants  gpg-agent.service

And their content is ...?

scippio wrote:

So before I started X I have DBUS_SESSION_BUS_ADDRESS empty. (my dbus service running...)

And there's your problem to begin with.

Online

#17 2017-06-16 13:08:32

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,593

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

scippio wrote:
Scimmia wrote:

Shot in the dark here, do you have anything gnupg related in ~/.config/systemd/user/*?

yes:

ls ~/.config/systemd/user/
default.target.wants  gpg-agent.service

Get rid of it.

https://bugs.archlinux.org/task/54396

Online

#18 2017-06-21 21:22:06

scippio
Member
Registered: 2007-01-02
Posts: 74

Re: [SOLVED] Problem with many apps after restart(upgrade?) [dbus]

Scimmia wrote:
scippio wrote:
Scimmia wrote:

Shot in the dark here, do you have anything gnupg related in ~/.config/systemd/user/*?

yes:

ls ~/.config/systemd/user/
default.target.wants  gpg-agent.service

Get rid of it.

https://bugs.archlinux.org/task/54396

YES! Everything is back in normal... thank you.


Sorry for my English...

Offline

Board footer

Powered by FluxBB