in reply to channel blocking

Howdy gopalreddy, welcome to the Monastery!

We'll need some more information to be able to help you. In particular, what problem are you experiencing? ("some tough time" could mean anything.) Also, what do you expect the script to do? If the remote SSH host goes down, then naturally your SSH connection will go down as well.

Here's some helpful nodes on how to ask question:

Help us help you!