From: Jeremy Bopp Date: 2012-05-16T05:27:52+09:00 Subject: Re: how do i find out if remote host is accepting ssh login? On 05/15/2012 12:15 PM, Brian Candler wrote: > Rick Tan wrote in post #1060837: >> Can someone suggest a reliable way to check if a remote host is >> accepting ssh login? > > Open TCP connection to remote host port 22. Read one line. Check you see > an SSH banner. It's possible that the above test may be enough to satisfy the OP, but the problem as stated is vague enough to leave some room for interpretation. If you really need to know that *login* is going to work, the only complete test is to actually perform a login via SSH with known-good credentials. The net-ssh gem will help in writing such a test pretty easily. :-) -Jeremy