I\'m executing a script connecting via password-less SSH on a remote host. I want to set a timeout, so that if the remote host is taking an infinite time to run, I want to c
ssh -o ConnectTimeout=10
Where 10 is time in seconds. This Timeout applies only to the creation of the connection.