[shepherd] Unloading a service renders shepherd unresponsive

  • Done
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Ludovic Courtès
Owner
unassigned
Submitted by
Ludovic Courtès
Severity
important
L
L
Ludovic Courtès wrote on 10 Jun 16:31 +0200
(address . bug-guix@gnu.org)
87jziwna3b.fsf@inria.fr
Seen with 0.10.4:

Toggle snippet (21 lines)
ludo@guix-hpc7 ~$ sudo herd status tor
Statut de tor :
It is running since sam. 01 juin 2024 15:58:57 (9 days ago).
Valeur d’exécution 453.
Activé.
Fournit (tor).
Requiert (user-processes loopback syslogd).
Sera relancé.
ludo@guix-hpc7 ~$ sudo herd unload root tor
Removing service 'tor'...
Done.
ludo@guix-hpc7 ~$ sudo herd status tor
^C
ludo@guix-hpc7 ~$ sudo herd status
^C
ludo@guix-hpc7 ~$ ps 453
PID TTY STAT TIME COMMAND
ludo@guix-hpc7 ~$ cat /proc/1/cmdline |xargs -0
/gnu/store/bhynhk0c6ssq3fqqc59fvhxjzwywsjbb-guile-3.0.9/bin/guile --no-auto-compile /gnu/store/39li5qpiaj1lx89xgahlbgvfnjhpcpwg-shepherd-0.10.4/bin/shepherd --config /gnu/store/2vynkp1zv8ybq513clrcp1ga1bi156wb-shepherd.conf

Inetd services such as sshd also become unavailable: shepherd accepts
connections but does not process them.

Excerpt of /var/log/messages:

Toggle snippet (8 lines)
Jun 10 16:20:29 localhost shepherd[1]: Removing service 'tor'...
Jun 10 16:20:29 localhost shepherd[1]: Stopping service tor...
Jun 10 16:20:29 localhost Tor[2]: Catching signal TERM, exiting cleanly.
Jun 10 16:20:29 localhost shepherd[1]: Service tor stopped.
Jun 10 16:20:29 localhost shepherd[1]: Service tor is now stopped.
Jun 10 16:20:29 localhost shepherd[1]: Done.

The workaround is to reboot the hard way:

sudo guile --no-auto-compile -L /gnu/store/39li5qpiaj1lx89xgahlbgvfnjhpcpwg-shepherd-0.10.4/share/guile/site/3.0/ -c '(use-modules (shepherd system)) (sync) (pk "bye!") (reboot)'

Ludo’.
L
L
Ludovic Courtès wrote on 10 Jun 18:55 +0200
control message for bug #71478
(address . control@debbugs.gnu.org)
87frtkn3es.fsf@gnu.org
severity 71478 important
quit
L
L
Ludovic Courtès wrote on 10 Jun 23:06 +0200
Re: bug#71478: [shepherd] Unloading a service renders shepherd unresponsive
(address . 71478@debbugs.gnu.org)
87bk48mrsn.fsf@gnu.org
Ludovic Courtès <ludovic.courtes@inria.fr> skribis:

Toggle quote (14 lines)
> ludo@guix-hpc7 ~$ sudo herd status tor
> Statut de tor :
> It is running since sam. 01 juin 2024 15:58:57 (9 days ago).
> Valeur d’exécution 453.
> Activé.
> Fournit (tor).
> Requiert (user-processes loopback syslogd).
> Sera relancé.
> ludo@guix-hpc7 ~$ sudo herd unload root tor
> Removing service 'tor'...
> Done.
> ludo@guix-hpc7 ~$ sudo herd status tor
> ^C

A simpler workaround is to do ‘herd stop SERVICE’ before
‘herd unload root SERVICE’.

Anyway, fixed in Shepherd commit
b81aa4d2554b9ddff683c33c0d1d7036842d2b76.

Ludo’.
L
L
Ludovic Courtès wrote on 10 Jun 23:06 +0200
control message for bug #71478
(address . control@debbugs.gnu.org)
87a5jsmrsd.fsf@gnu.org
close 71478
quit
?
Your comment

This issue is archived.

To comment on this conversation send an email to 71478@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 71478
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch