Plink is not working

Hi,

I am executing below command from Windows run and it is not working

"C:\Program Files (x86)\PuTTY\pageant.exe" "D:\abc_key.ppk"  -c "C:\Program Files (x86)\PuTTY\plink.exe" -ssh 172.19.11.134 sh ~/touchfile.sh

I have created a .ppk file in the directory specified

The plink window opens , asks for username , password and closes.
The shell script is not executed. I have touched a file in the shell script which is not created. I am using Windows 7. Please Help.

Moved this thread about Windows programs to the Windows forum.

I suspect you just plain can't run multiple commands in start->run, which simply isn't a shell. Using adding & or && to separate commands is supposed to work in batch files for very modern Windows.

You can setup Pageant to load keys automatically during startup to avoid manually loading it every time. Here is a guide

After that open command prompt, try running plink and check if the shell script exists in home directory and has execute privileges:-

plink.exe -ssh 172.19.11.134 "ls -l ~/touchfile.sh"
1 Like