I want to start a couple of jobs on different machines using ssh. If the user then interrupts the main script I want to shut down all the jobs gracefully.
Here is a shor
Try this:
ssh -tt host command
When you kill the local ssh process, the remote pty will close and SIGHUP will be sent to the remote process.