how to check whether the ssh tunnel is up

Vincent Lin vintobe at gmail.com
Fri Apr 26 19:06:36 EST 2013


Hi all,

I use the command below to set up a ssh tunnel. And I run it as a daemon
process to keep the ssh tunnel work all the time. And I should wait for the
ssh tunnel to be up and notify the tunnel is OK before sending any command
to the remote port on the remote server. But the question is I don't know
how to check the ssh tunnel status. Is there a way to show whether the ssh
tunnel is up?  Thank you for your help.

*"ssh -i /root/ah_rsa -oUserKnownHostsFile=/root/hosts
-oStrictHostKeyChecking=yes -oNumberOfPasswordPrompts=0 -oBatchMode=yes
-oHostKeyAlgorithms=ssh-rsa -R 20001:localhost:22 user at xxx.xxx.xxx.xxx -p
13422 -Nyv"*


Best Regard,
Vincent


More information about the openssh-unix-dev mailing list