Add the failonhang command to error out on remote hang

I am using this script to monitor if some line are working, I added a flag (so it doesn't change current behaviour) so it dies after the remote hang the call.