q16marvin
Goto Top

Plink cant send yes?

i want to use plink for a batch ssh like this:


plink -ssh -pw "xxxxx" admin@192.168.0.97 -m mac_auth_anschalten.cmd


mac_auth_anschalten.cmd:

_cmdline-mode on
Y
512900
system-view
mac-authentication

but it stops here:

http://i.imgur.com/sC8Dmrp.png

so how can i send "Y" to this ssh session?

Erik

Content-Key: 274100

Url: https://administrator.de/contentid/274100

Printed on: April 20, 2024 at 02:04 o'clock

Mitglied: 114757
114757 Jun 09, 2015 updated at 10:14:46 (UTC)
Goto Top
Hello Erik,
have you already tried the plink-Switch -batch ?

Regards
jodel32
Member: q16marvin
q16marvin Jun 09, 2015 at 10:18:38 (UTC)
Goto Top
you mean like:

plink -ssh -pw "xxxx" admin@192.168.0.97 -m mac_auth_anschalten.cmd -batch ???

the same, it stops by the question "Continue? [Y/N]"
Mitglied: 114757
114757 Jun 09, 2015 updated at 10:28:03 (UTC)
Goto Top
Zitat von @q16marvin:
you mean like:
plink -ssh -pw "xxxx" admin@192.168.0.97 -m mac_auth_anschalten.cmd -batch ???
yes
the same, it stops by the question "Continue? [Y/N]"
hmm don't now any other solution for plink, yet. Is it not possible to permanently activate this setting in the switch, so you don't have to call it in the script?

Have you tried to send the commands with Linux Tools (ssh) as an alternative?
Member: q16marvin
q16marvin Jun 09, 2015 at 11:44:18 (UTC)
Goto Top
mhh i have only windows clients, it seems that generaly only first line in this commands file will be executed, but i dont know why ...
Mitglied: 114757
Solution 114757 Jun 09, 2015, updated at Jun 11, 2015 at 06:59:56 (UTC)
Goto Top