I would like to create ssh tunnel by a command such as: ssh -l root -p 1035 -L 11016:127.0.0.1:5432 -N -g -f X.X.X.X but after that I will get prompted to input pwd or 'YES/NO' confirmaton, how to wait for output back and based on the output content, type subsequent command, pwd or 'Yes' ?
Hi Welcome to Talend Community! Why don't you use tSSH component? Then you will get return values ((String)globalMap.get("tSSH_1_STDOUT")). Regards, Pedro
Hi
Thanks for your quick reply.
I had been using that. Let me clarify it.
I firstly logon on the Host A by the tSSH component, then executed the command 'ssh -l root -p 1035 -L 11016:127.0.0.1:5432 -N -g -f X.X.X.X' to create ssh port tunnel, after that, it was expected that I would get prompted to type pwd or others, anyway, I need know when it gets returned and what content.
make such question generic:
how to execute interactive commands in tSSH component?