13

I use GNU/Linux Mint 18.2 (based on Ubuntu 16.04). Very recently, I've started seeing the following error message, repeated many times, when I start some GUI apps (e.g. meld):

unable to create file '/run/user/1000/dconf/user': Permission denied.  dconf will not work properly.

Now, I'm able to work around this by manually changing the ownership of /run/user/1000/dconf/user, but that's kind of a lame hack and certainly not robust.

Why have I been seeing this error and what's the "right way" to avoid it (if any)?

einpoklum
  • 9,515
  • 1
    I think it's caused by running certain GUI programs as superser: I get this same problem when running ktsu to open a terminal app (called terminator) as a root window. Apparently terminator is using my UID instead of root's in /run/user/UID/user, and that can change the owner of the file to root causing "permission denied" when I run terminator as myself. – frayser Sep 06 '18 at 00:35

3 Answers3

4

chown 1000:1000 /run/user/1000/dconf/user

4

The issue can be caused by running a GUI after changing user using su command. Certain environmental variables are not changed causing the error. See

https://bugzilla.redhat.com/show_bug.cgi?id=753882

Try running the program by logging in as that user directly.

awct
  • 141
1
#!/bin/bash
# rmdconfuser - remove dconf user

if [ -e "/run/user/1000/dconf/user" ] 
then
    rm -f /run/user/1000/dconf/user
fi

# Uncomment the next line if mate-settings-daemon is eating up too much memory
# killall -9 mate-settings-daemon

then execute chmod +x rmdconfuser and place rmdconfuser into your ~/bin/ or /usr/local/bin as root and sudo rmdconfuser to stop the problem. You can also make rmdconfuser set its own uid to root, so you can run it without being root yourself.

Unfortunatelly this is only a work around. The problem may appear again & again.

einpoklum
  • 9,515
  • Interesting user name you have there. Why would I have the mate-settings-daemon running, though? – einpoklum Oct 21 '17 at 10:54
  • sorry - because it caused the problem of eating the ram on my machine running mate on mint. If you have no mate then simply forget the last line. – Work Around Oct 21 '17 at 14:26