<div dir="ltr"><div><div>Hello!</div><div><br></div><div>I have written a script that establishes an SSH Tunnel and does Port Forwarding from a local CYGWIN Shell ....<br></div><div><br></div><div>When I try to kill the tunnel by the PID, I get nothing ...</div><div><br></div><div>Does anyone know how CYGWIN handles PIDs in a local Shell?</div><div><br></div><div>ssh -NTf -L 6111:<a href="http://remote.server.org:8080">remote.server.org:8080</a> -L 6112:<a href="http://remote.server.org:8080">remote.server.org:8080</a> <a href="mailto:me@tunnel.server.org">me@tunnel.server.org</a><br></div><div>PIDOF=$!</div><div><div>echo -e "Local Port 6111 is now resolving content from \"<a href="http://remote.server.org:8080">remote.server.org:8080</a>\""</div><div>echo -e "Local Port 6112 is now resolving content from \"<a href="http://remote.server.org:8080">remote.server.org:8080</a>\""<br></div><div>echo -e ""</div><div>echo -e "Port Forwarding ${red_back}${yellow_text}Active${norm_text}${norm_back}:"</div><div> while true</div><div> do</div><div> echo -e "Press Any Key to ${red_text}STOP${norm_text} Port Forwarding ..."</div><div> read kill</div><div> case $kill in</div><div> *) kill $PIDOF ;;</div><div> esac</div><div> done</div><div> ;;</div><div>esac</div></div><div><br></div><div>I'm just getting an empty variable (kill has nothing to kill) .... since this is just a local shell and not a full fledged system, I was wondering if anyone knew how CYGWIN handles PIDs.</div></div><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr">--<br>Thanks,<br>--:: Alexander J. Snyder ::--<br>--:: <a href="http://thisguyshouldworkfor.us" target="_blank">ThisGuyShouldWorkFor.Us</a> ::--<br>--:: "Never trust a computer you can't throw out a window. --Steve Wozniak" ::--<br>--</div></div></div></div></div></div></div>
</div>