Exactly my issue, I don't use millions of commands...but when I get to 10 channels...timeout....I'm happy to see another kindred spirit, I have come to the same conclusion (disconnect/reconnect sshClient). but my problem...I have to use an RSA key :-( I am working on corporate policy to get an alternate login situation.....anyway.
If you don't mind, I would appreciate seeing code on how you Re-Connect every minute or so. If I can solve my RSA key issue, i'll still need a way to clear/dispose the channels that stay open. It sounds like your method is good. Thank you!
If you don't mind, I would appreciate seeing code on how you Re-Connect every minute or so. If I can solve my RSA key issue, i'll still need a way to clear/dispose the channels that stay open. It sounds like your method is good. Thank you!