From: Zbigniew Jędrzejewski-Szmek Date: Tue, 13 Nov 2018 08:02:01 +0000 (+0100) Subject: nspawn: add a hint to the message we emit when a child dies X-Git-Tag: v240~323^2~5 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bd897e729a90516125802b8346474404f342c820;p=thirdparty%2Fsystemd.git nspawn: add a hint to the message we emit when a child dies From #10526: $ sudo systemd-nspawn -i image Spawning container image on /home/zbyszek/src/mkosi/image. Press ^] three times within 1s to kill container. Short read while reading cgroup mode. --- diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c index 9f69ee10a8d..621968ef8e5 100644 --- a/src/nspawn/nspawn.c +++ b/src/nspawn/nspawn.c @@ -3862,7 +3862,8 @@ static int run(int master, if (l < 0) return log_error_errno(errno, "Failed to read cgroup mode: %m"); if (l != sizeof(arg_unified_cgroup_hierarchy)) { - log_error("Short read while reading cgroup mode."); + log_error("Short read while reading cgroup mode (%zu bytes).%s", + l, l == 0 ? " The child is most likely dead." : ""); return -EIO; } }