unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: 33592@debbugs.gnu.org
Subject: bug#33592: "herd restart term-tty2" caused *all* processes to be killed
Date: Sun, 02 Dec 2018 20:16:29 -0500	[thread overview]
Message-ID: <87tvjvmmt3.fsf@netris.org> (raw)

After killing a Wayland 'gnome-session' that I had launched from the
command-line on tty2, the login prompt did not return as it normally
does.

I decided to try "herd restart term-tty2" to see if that would help.
That turned out to be a serious mistake.  It caused TERM to be sent to
all processes, most filesystems to be unmounted, and many (all?) core
services to be stopped.  This left my system in a unusuable state,
besides being able to switch between otherwise unresponsive text virtual
terminals and issue SysRq commands.

I took a picture of the display before resetting the machine.
Fortunately I always use text virtual terminals for my root shells.
Here's a hand-typed approximation of what shepherd printed to the
console:

--8<---------------cut here---------------start------------->8---
root@jojen ~# herd restart term-tty2
[200060.46xxxx] shepherd[1]: Service term-tty4 has been stopped.
[200060.46xxxx] shepherd[1]: Service nscd has been stopped.
[200060.47xxxx] shepherd[1]: Service guix-daemon has been stopped.
[200060.47xxxx] shepherd[1]: Service term-tty2 has been stopped.
[200060.47xxxx] shepherd[1]: Service console-font-tty1 has been stopped.
[200060.48xxxx] shepherd[1]: Service term-tty1 has been stopped.
[200060.48xxxx] shepherd[1]: Service console-font-tty5 has been stopped.
[200060.48xxxx] shepherd[1]: Service term-tty5 has been stopped.
[200060.49xxxx] shepherd[1]: sending all processes the TERM signal
[200064.81xxxx] shepherd[1]: all processes have been terminated
[200064.81xxxx] shepherd[1]: Service user-processes has been stopped.
[200064.82xxxx] shepherd[1]: Service urandom-seed has been stopped.
[200064.82xxxx] shepherd[1]: Service file-systems has been stopped.
[200064.83xxxx] shepherd[1]: Service file-system-/dev/pts has been stopped.
[200064.84xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/blkio has been stopped.
[200064.86xxxx] shepherd[1]: Service file-system-/gnu/store has been stopped.
[200064.88xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/freezer has been stopped.
[200064.90xxxx] shepherd[1]: Service file-system-/run/systemd has been stopped.
[200064.91xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/cpuset has been stopped.
[200064.93xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/cpuacct has been stopped.
[200064.95xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/devices has been stopped.
[200064.96xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/perf_event has been stopped.
[200064.98xxxx] shepherd[1]: Service file-system-/run/user has been stopped.
[200065.00xxxx] shepherd[1]: Service file-system-/dev/shm has been stopped.
[200065.01xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/memory has been stopped.
[200065.03xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/elogind has been stopped.
[200065.05xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup/cpu has been stopped.
[200065.06xxxx] shepherd[1]: Service file-system-/sys/fs/cgroup has been stopped.
[200065.06xxxx] shepherd[1]: system-error("kill" "~A" ("No such process") (3))
[200065.06xxxx] shepherd[1]: Service udev has been stopped.
[200065.06xxxx] shepherd[1]: Service virtual-terminal has been stopped.
[200065.19xxxx] shepherd[1]: closing log
[200065.23xxxx] BTRFS info (device dm-0): disk space caching is enabled
--8<---------------cut here---------------end--------------->8---

The 'xxxx' are of course more digits that I was too lazy to type.

I would not have expected 'term-tty2' to have many dependents, except
possibly for 'console-font-tty2'.  It was a great surprise that
restarting it caused so many other core services to be stopped.

Any idea what went wrong here?

       Mark

             reply	other threads:[~2018-12-03  1:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-03  1:16 Mark H Weaver [this message]
2018-12-03  8:44 ` bug#33592: "herd restart term-tty2" caused *all* processes to be killed Ludovic Courtès
2018-12-04  2:10   ` Mark H Weaver

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87tvjvmmt3.fsf@netris.org \
    --to=mhw@netris.org \
    --cc=33592@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).