GNU bug report logs -
#76998
Guix Home leaves user shepherd on logout, starts new instance on login
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your bug report
#76998: Guix Home leaves user shepherd on logout, starts new instance on login
which was filed against the guix package, has been closed.
The explanation is attached below, along with your original report.
If you require more details, please reply to 67863 <at> debbugs.gnu.org.
--
76998: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=76998
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
Hi,
Tomas Volf <~@wolfsden.cz> writes:
> Well, since you have mentioned the GnuPG as an example, we could just
> mirror what it does, and what I have suggested before.
>
> --8<---------------cut here---------------start------------->8---
> $ mkdir /tmp/xxx && cd /tmp/xxx
> $ guix shell -u test -C findutils gnupg coreutils bash procps -- env HOME=/tmp/xxx GNUPGHOME=/tmp/xxx bash
> test <at> xx ~ [env]$ gpg-agent --daemon
> gpg-agent[2]: directory '/tmp/xxx/private-keys-v1.d' created
> gpg-agent[3]: gpg-agent (GnuPG) 2.4.7 started
> test <at> xx ~ [env]$ find /run/user
> /run/user
> /run/user/1000
> /run/user/1000/gnupg
> /run/user/1000/gnupg/d.j1yiifhhjrep9xunazyff54c
> /run/user/1000/gnupg/d.j1yiifhhjrep9xunazyff54c/S.gpg-agent.ssh
> /run/user/1000/gnupg/d.j1yiifhhjrep9xunazyff54c/S.gpg-agent.browser
> /run/user/1000/gnupg/d.j1yiifhhjrep9xunazyff54c/S.gpg-agent.extra
> /run/user/1000/gnupg/d.j1yiifhhjrep9xunazyff54c/S.gpg-agent
> test <at> xx ~ [env]$ ps aux
> USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
> test 1 0.0 0.0 5136 4068 ? S 13:32 0:00 bash
> test 3 0.0 0.0 5516 2400 ? Ss 13:32 0:00 gpg-agent --daemon
> test 5 0.0 0.0 5224 3852 ? R+ 13:32 0:00 ps aux
> test <at> xx ~ [env]$ rm -r /run/user/1000/gnupg
> gpg-agent[3]: socket file has been removed - shutting down
> gpg-agent[3]: gpg-agent (GnuPG) 2.4.7 stopped
> test <at> xx ~ [env]$ find /run/user
> /run/user
> /run/user/1000
> test <at> xx ~ [env]$ ps aux
> USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
> test 1 0.0 0.0 5136 4068 ? S 13:32 0:00 bash
> test 8 0.0 0.0 5224 3776 ? R+ 13:33 0:00 ps aux
> --8<---------------cut here---------------end--------------->8---
>
> So my suggestion is that when the socket is deleted, the shepherd
> process stops itself.
Brilliant!
The only downside is that it’ll be a bit of work (using inotify on Linux
and some other method elsewhere, presumably polling) but it definitely
sounds like a good plan.
I can look into it later it nobody beats me at it.
Ludo’.
[Message part 3 (message/rfc822, inline)]
[Message part 4 (text/plain, inline)]
I am trying to use the awesome Guix Home Shepherd service for syncthing (home-syncthing-service-type).
Syncthing works fine but every time I log out of my last user session and log back in again, a new instance of the user shepherd is started (and tries to start syncthing again).
After logging out and in a few times, there are multiple user shepherd processes.
Suspected cause: Apparently the user shepherd process is not killed on last logout before elogind (correctly) removes XDG_RUNTIME_DIR.
So on next login, a new empty XDG_RUNTIME_DIR is created, causing a new user shepherd to be started while the old one is still running happily.
This seems to be a general issue and not particular to the syncthing home service.
System: Guix System on x86_64
Guix commit: ac61e9705fb8c450c6cd0c1731fbb1b909c1f944
--
Uli
[Message part 5 (text/html, inline)]
This bug report was last modified today.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.