Solved Will modifying .xinitrc fix my gnome-keyring cannot access control socket error?

If I enter the below command to determine my runtime directory, I receive the below information.
Code:
Simon@Asus:~ $ echo $XDG_RUNTIME_DIR
var/run/user/1001

Also, if I look in my /var/log/messages, I find the below lines stating that the gnome-keyring-daemon cannot access /var/run/user/1001/keyring/control.
Code:
Feb 24 11:21:46 Asus gnome-keyring-daemon[3270]: couldn't access control socket: /var/run/user/1001/keyring/control: No such file or directory
Feb 24 11:21:46 Asus gnome-keyring-daemon[3270]: discover_other_daemon: 0
Feb 24 11:21:46 Asus gnome-keyring-daemon[3272]: couldn't access control socket: /var/run/user/1001/keyring/control: No such file or directory
Feb 24 11:21:46 Asus gnome-keyring-daemon[3272]: discover_other_daemon: 0
Feb 24 11:21:46 Asus gnome-keyring-daemon[3271]: couldn't access control socket: /var/run/user/1001/keyring/control: No such file or directory
Feb 24 11:21:46 Asus gnome-keyring-daemon[3271]: discover_other_daemon: 0

Also, if I navigate to the /var/run/user/1001/keyring directory, I see that the control file seems to exist at this location, and that it's listed properties are as shown in the below screen capture.

control_properties.jpg



So, now I'm wondering if I were to add the below lines to the top of my, /usr/local/etc/X11/xinit/xinitrc file, would the above error messages related to gnome-keyring-daemon likely go away? Or am I completely all wet here?

Code:
# Start the gnome-keyring as a daemon service
eval $(gnome-keyring-daemon --start --components=pkc11,secrets,ssh)
export XDG_RUNTIME_DIR=var/run/user/1001

I should probably also add that I started out with Xfce, but then I decided to install Cinnamon, and that is when the fun started.
 
Don't edit /usr/local/etc/X11/xinit/xinitrc
That is a system level file.

There may be a .xinitrc or .xsession in your user home directory

I don't think you should need that, but what happens if run the gnome-keyring-daemon command from a terminal window after the GUI starts?
If that works, then it's likely a timing issue of of when XDG_RUNTIME_DIR actually gets set vs when the command runs.
I'm guessing there is an autostart thing actually starting the daemon, I would start with disabling that and manually starting to verify that it does work correctly.
If there is not an autostart there are a bunch of examples that show how to correctly put it into a shell init file
 
but what happens if run the gnome-keyring-daemon command from a terminal window after the GUI starts
I got an empty return after I hit enter, as if it wasn't running.

Well, I kept experimenting with different files with /etc/pam.d, but then after too much playing around, I ended up with system that wouldn't allow me back into the desktop environment. I don't know what I did, but I really screwed the pooch on that one, but luckily I was able to do a reinstall, and then rsync my directories back into place, and then I was back to where I was before I started playing around with Cinnamon. Too bad, I really wanted that to work, but the time being at least I have a functional xfce desktop to use for the time being.
 
Don't set XDG_RUNTIME_DIR yourself. It's done with pam_xdg(8) nowadays.
Below is what I have within the Session area of my /etc/pam.d/system file, so it looks like the last line is taking care of that for me?
Code:
# session
#session    optional    pam_ssh.so        want_agent
session        required    pam_lastlog.so        no_fail
session         required        pam_xdg.so
I think that I may have foolishly commented this line out earlier, and I tried to replace it with something like the below, and that is about the time I got locked out.

Code:
session required pam_xdg.so runtime_dir=/var/run/user/1001

Well, I guess I need to break my habit of blindly modifying configuration files until I know more about how things work. Thank you for the advice.
 
autostart thing actually starting the daemon
I'm using lightdm along with xfce, and the best I could figure out is that is was supposed to be launched by one of the configuration files located within /etc/pam.d/ but I didn't know enough to figure it out.
 
I guess I need to break my habit of blindly modifying configuration files until I know more about how things work.
Yeah, that's generally a bad idea, intentionally breaking something can give you some great insights though 😁
 
Don't edit /usr/local/etc/X11/xinit/xinitrc
That is a system level file.

There may be a .xinitrc or .xsession in your user home directory

I don't think you should need that, but what happens if run the gnome-keyring-daemon command from a terminal window after the GUI starts?
If that works, then it's likely a timing issue of of when XDG_RUNTIME_DIR actually gets set vs when the command runs.
I'm guessing there is an autostart thing actually starting the daemon, I would start with disabling that and manually starting to verify that it does work correctly.
If there is not an autostart there are a bunch of examples that show how to correctly put it into a shell init file
I use lxde and always used to have a ~/.config/lxsession which contained an autostart file, but when upgrading to 15.0 lxsession no longer appears automatically.

Could this be related to some changes in XDG?
 
balanga I don't think so. maybe it moved to a different directory under ~/.config? I think lxsession is basically the "save session" when you exit lxde, so maybe you need to save session again?
 
Back
Top