You are not logged in.
Failed to open private bus connection: Failed to connect to socket /run/user/0/dbus/user_bus_socket: No such file or directory
This issue has been existing for a while. After few upgrades, it still remains unresolved. There are few posts in forum talking about similar problems, but it's not exactly the same as this issue.
After 'touch /run/user/0/dbus/user_bus_socket && systemctl restart user@0.service', I got
Failed to open private bus connection: Failed to connect to socket /run/user/0/dbus/user_bus_socket: Connection refused
*I followed instuctions from https://wiki.archlinux.org/index.php/Systemd/User, but the message still exists.
*This issue is also discussed here: http://comments.gmane.org/gmane.comp.sy … evel/13439, but no conclusion in the end.
Actually the directory /run/user/0/dbus does not exist in this case, so I took a look into dbus code, and I think if the directory does not exist at time dbus starts, dbus should create it rather than throw exception and stop.
Anyone any ideas?
Thanks.
Last edited by enihcam (2013-11-24 02:31:51)
Offline
Add this to /etc/systemd/system/user@.service.d/env.conf:
[Service]
Environment=XDG_RUNTIME_DIR=/run/user/%I
Offline
Add this to /etc/systemd/system/user@.service.d/env.conf:
[Service] Environment=XDG_RUNTIME_DIR=/run/user/%I
Done, but after reboot the issue still exists.:(
btw, I don't have X system. It is my server box.
Last edited by enihcam (2013-11-24 02:13:33)
Offline
Are you sure you didn't misspell anything? This is from my Pi (also without X installed):
# cat /etc/systemd/system/user@.service.d/*.conf
cat: /etc/systemd/system/user@.service.d/*.conf: No such file or directory
# systemctl --user
Failed to get D-Bus connection: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
# cat >/etc/systemd/system/user@.service.d/env.conf <<EOF
> [Service]
> Environment=XDG_RUNTIME_DIR=/run/user/%I
> EOF
# cat /etc/systemd/system/user@.service.d/*.conf
[Service]
Environment=XDG_RUNTIME_DIR=/run/user/%I
# systemctl daemon-reload
# systemctl restart user@0.service
# systemctl --user
UNIT LOAD ACTIVE SUB DESCRIPTION
sys-devices-dev:f1-tty-ttyAMA0.device loaded active plugged /sys/devices/dev:f1/tty/ttyAMA0
sys-devices-p...d1.1:1.0-net-eth0.device loaded active plugged SMSC9512/9514 Fast Ethernet Adapter
...
Oh, you edited the first post and removed the message talking about "$DISPLAY"… Now it makes less sense without the context.
The problem was running "systemctl --user", which failed with message "Unable to autolaunch a dbus-daemon without a $DISPLAY for X11". This is solved by specifying XDG_RUNTIME_DIR in the user@.service.
Another thing is the message "Failed to open private bus connection", and this is completely normal. You said you read another posts about this — the conclusion is exactly like that, this error message will be there and you can do nothing about it.
Offline
It seems like DBUS team is addressing this issue.
https://bugs.freedesktop.org/show_bug.cgi?id=61301
https://bugs.freedesktop.org/show_bug.cgi?id=61303
Offline