Remote program doesn't terminate when ssh session ends

2021-02-25 Thread Grant Edwards
I have a small ash script that prints memory statistics once a second: #!/bin/sh while true do date cat /proc/[0-9]*/stat | awk '$23 > 0 {printf "%5d %20s %8d %5d\n", $1, $2, $23, $24}' | sort -n sleep 60 done When I run that

Re: Remote program doesn't terminate when ssh session ends

2021-02-25 Thread Catalin Patulea
Years ago, I attempted to fix an issue that sounds a lot like this: https://hg.ucc.asn.au/dropbear/rev/35183e8a7851 I believe the right way this works it that: - ssh client closes session - dropbear closes the read end of command's stdout pipe - next time command writes to pipe, it receives