dconf-WARNING **: failed to commit changes to dconf: The connection is closed

Whenever I open any software through Terminal I get following errors and eventually the software opens

dconf-WARNING **: failed to commit changes to dconf: The connection is closed

(gedit:3609): dconf-WARNING **: failed to commit changes to dconf: The connection is closed

(gedit:3609): dconf-WARNING **: failed to commit changes to dconf: The connection is closed
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)

What can be the possible issue?

Asked By: Pawan Chauhan

||

I had the same problem, in my case I was running "sudo gedit" from a user account; therefore when it tried to save dconf changes it realized that the user was not root, and thus it raised those errors. I solved it by running gedit as a “root”:

sudo -i

gedit &

where sudo -i will login into a user acount.

Answered By: XAVI

This has got on my nerves for a long time. I finally solved it using gksudo -l <command>, which runs the command in a login shell – similarly to XAVI’s answer but without the need to type in the command after sudo.

Answered By: yosoy

You may want to check if the following folders are owned by root:

~/.cache/dconf
~/.dbus

If they are, try deleting them. According to other sources I found, they should be owned by yourself, but if you have run graphical programs with sudo they might have been created by root instead. Deleting them is apparently safe, as they are automatically recreated as necessary, but maybe back them up first.

Answered By: sp00n

So I had this problem also. I did not have the patience to work through the various tedious and/or ineffective solutions that I found on the interwebs. The following worked for me:

$ emacs foo.py 2>/dev/null &   # (assuming you have an Xserver running)

No, it’s not elegant. But it works. I haven’t run into any bona fide emacs stderr’s for years (if ever) so how bad can this be? And you can stick in an ‘alias’ in your .bashrc file.

Answered By: Alex Rudnicky
Categories: Answers Tags:
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.