> On Tue, 5 May 2020 at 16:27, Mark Bannister <mbannister@xxxxxxxxxxxxxx> wrote: > > Perhaps I'm missing something or oversimplifying, but I tried to > > reproduce the problem as follows: I created a script that ignores INT, > > TERM and HUP and then loops indefinitely writing the time every second > > to a log file. I SSHed into the box, ran the script, and then from > > another terminal window killed the parent (bash) and also retried the > > experiment by killing the bash parent (sshd). In both cases the > > parent bash and sshd processes died (as expected), my script kept > > running but the parent PID of the script was changed to 1 (systemd). > > I did not receive any error messages in /var/log/messages. > > It has to be the last remaining session of the user, and you should > inspect with systemctl list-jobs if systemd is trying to stop the > scope and slice units, just to be sure, before attempting to login. > Otherwise, if you're logged in from two places on the machine for a > user, you won't hit the issue, obviously. I repeated the exact same test with a different user account, one set-up specifically for this test and nothing else, so there was only one SSH session. But 'systemctl list-jobs' always reported 'No jobs running' even after the SSH session was terminated. My script kept running with the parent PID of 1. Thanks for your help so far, but I have still been unable to reproduce the problem. What am I doing wrong? Thanks Mark _______________________________________________ systemd-devel mailing list systemd-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/systemd-devel