I am trying to translate the GUI settings in Putty for establishing SSH tunnel to command line in Windows batch script. The first batch script establishes the port forwarding and tunnel ...
start putty -ssh firstname.lastname@example.org -pw my_secure_pw -L 5555:10.54.22.104:5432 -L 2222:10.54.22.104:22
and the second batch script uses the tunnel ...
start putty -ssh localhost 5555
While the first script runs without error, I keep getting Putty Fatal Error: Server unexpectedly closed network connection for the second one.
However, if I establish the tunnel using GUI as per snapshot below, and run the second script, there was no error and I can run the application accordingly.
Is there any missing configuration or option from the first script, if compare to the GUI?