Questions tagged [plink]

Plink (PuTTY link) is a command-line connection tool similar to UNIX ssh.

Filter by
Sorted by
Tagged with
0 votes
0 answers
28 views

PLink telnet from Excel VBA - avoid login delay, or maintain session for multiple queries

I have a Linux box which I'm testing, and I have an Excel workbook with tables of tests I'm running. (Don't get tied up on Linux, it's just a Telnet target for the purposes of this question.) The ...
Scott's user avatar
  • 11
0 votes
1 answer
99 views

Create Telnet connections to multiple servers and log the welcome messages

I need to remotely determine what FileZilla Server version is installed on a large number of computers . I know that if I initialise a Telnet connection to a FZ server, I will get a response that ...
Oddthetall's user avatar
0 votes
1 answer
78 views

plink bash -c skips arguments to first command

When I combine plink with bash -c, first command does not receive parameters. Command: plink -batch myuser@myhost bash -c 'echo one; echo two; echo three' Actual output <empty line> two three ...
IndustryUser1942's user avatar
1 vote
1 answer
82 views

How does Plink parse session names?

If Plink is invoked with an argument which could be a host name or a saved PuTTY session, how is it parsed? For example, suppose I have saved a PuTTY session named "192.168.4.4". Will the ...
kevin_o's user avatar
  • 21
0 votes
0 answers
118 views

I have a VB script that opens Plink to communicate to a Cognex Insight sensor via Telnet. How to prevent exit when I send two {Enter} in a row?

The Cognex Insight smart sensor has a built in Telnet over ethernet protocol. I am using PuTTY to configure the Telnet communication. When PuTTY is started, it establishes communication with the ...
Mat R's user avatar
  • 1
0 votes
0 answers
48 views

Running pod install through plink gives sh:1: command not found: pod

I want to run pod install on macOS 12.4 remotely from a windows 11 machine. Im currently using (option 1) plink -ssh -v 192.168.101.129 -l user1 -pw pw1 "pod install" However, this gives sh:...
ChrisC's user avatar
  • 223
-1 votes
1 answer
792 views

plink - Server refused our key - No supported authentication methods available

I am using a .ppk file with putty to connect to my AWS server. This works with no problems. However, if I try to use the same .ppk file with plink then I get an error: Attempt: "C:\Program Files (...
Black's user avatar
  • 7,529
0 votes
1 answer
2k views

How to disable StrictHostKeyChecking in Plink? (Using plink so I can specify password)

Yes, I know, it's insecure: I will be using this for my personal Raspberry Pi, on my personal computer, on my home wifi, and I will have nothing important on there. I'm just making a profile in the ...
someguywhoplaystoomuchmc's user avatar
0 votes
1 answer
447 views

windows cmd terminal or git bash or conEmu press up arrow key doesn't set 0x1b 0x5b 0x41 in subshell (using putty plink)

I'm using putty's plink command to login to serial console, when press up arrow key, 0x1b 0x5b 0x41 is expected to set to MCU and I can use the shell history. But it doesn't work, it's work in putty ...
Divlaker's user avatar
  • 111
-1 votes
1 answer
7k views

How to run a remote command in PuTTY after login in

in my Windows machine I try to login automatically to remote server (it works) and after then to run commands (i want to reboot it but it does not matter) I using bat file to log in and run commands: ...
Vaclav Blaha's user avatar
1 vote
1 answer
284 views

Sending data from .txt file to raw connection with Plink automatically?

I'm trying to create an automated excel script and I want that script to send the output data to another system through plink for example. I've succeeded with opening the plink and connecting to the ...
Nils's user avatar
  • 11
0 votes
1 answer
358 views

Can't insert correct "enable" secret password with Plink.exe for my Dell switch

I'm trying to use "Plink.exe" to connect throught SSH to my Dell switch N1548P and run "enable" command to enter EXEC mode. I'm using Plink with CMD in Windows 10. This is the ...
Elia Pirola's user avatar
0 votes
1 answer
744 views

Cannot enter password automatically in Terminal PuTTY plink command to connect CentOS 7 in Windows

I want to connect CentOS 7 in Windows Terminal, when I use command: ssh [email protected] The arrow keys works well, but ssh command can't enter password automatically. So, I use PuTTY plink ...
Guo's user avatar
  • 101
1 vote
3 answers
2k views

plink.exe - force timeout for remote operations

Have script which daily reading configs from bunch of network devices utilizing plink.exe. Time by time, some device have stucked internal process which provide backup data and plink instance (and ...
user2956477's user avatar
2 votes
1 answer
407 views

Plink using PuTTY colour scheme

I'm trying to open plink from a *.bat on Windows 10, with the colour scheme defined from an existing session in PuTTY, and while the commands are correctly executing, and the right results displayed, ...
Lolo Irie's user avatar
1 vote
2 answers
7k views

PuTTY / plink - How to execute command AND keep shell alive

I'm remote connecting to a linux machine from windows using PLINK and would like to execute some commands in a batch script right after connecting, but it seems I cannot keep the terminal alive. After ...
Comfort Eagle's user avatar
1 vote
0 answers
483 views

CMD echo working with PLINK>exe

good day, I tried to use the format below for my plink and when I went to login with the username I changed the password on it didn't accept the new password. so my question is, when using "(...
Thomas Bonar's user avatar
2 votes
1 answer
3k views

Tunneling using Plink to localhost on Windows

Currently im using following command (in cmd) to tunnel using PuTTY, and it's working fine: putty.exe [email protected] -P 22 -L 10.24.0.200:2022:localhost:22 10.24.0.5 = my application server (...
Teddybugs's user avatar
  • 123
1 vote
1 answer
82 views

How do I change this Unix command to run in PuTTY or Plink on Windows

ssh -L 5432:anRDSDATABASE.rAndomLe34.eu-west-2.rds.amazonaws.com:5432 -o ProxyCommand="ssh -W %h:%p [email protected]" [email protected] I am struggling to work out how transform the ...
Lawrence's user avatar
3 votes
2 answers
2k views

What is the priority between ssh key types on a ssh connection?

While developing a ssh tool that connects to a sever I have seen the following: In Windows(with plink), it uses the ssh-ed25519 server key type to make the handshake and confirm it's fingerprint. In ...
Roger Coll's user avatar
1 vote
1 answer
6k views

Automate command execution on switch using Plink

Periodically my IT team and I need to turn off the WiFi to everyone in the workplace for maintenance. Currently we log into the switch using PuTTY and enter the commands to shut off the WiFi, this ...
Zuhan's user avatar
  • 13
0 votes
0 answers
518 views

plink not echoing stderr

I am using plink to run commands on a windows server running openssh. It appears that plink doesn't echo output that is on stderr. For example, where bork.exe prints "stdout" to stdout and "stderr" to ...
Shawken X's user avatar
0 votes
0 answers
421 views

How would I replicate these ssh commands using Putty or plink for a windows computer?

I am trying to understand the connection flow of the following setup, so that I may replicate the remote commands using windows putty or plink. I have 3 computers: local - intermediate - remote On ...
TryHarder's user avatar
0 votes
1 answer
584 views

Plink occasionally stalls on error, but does not exit until user presses key

I am working on a batch script to automatically remote port forward. The batch script is as follows: start cmd.exe /k "FOR /L %%N IN () DO plink.exe -v -ssh -batch -C -T -N -R 3389:127.0.0.1:3389 ...
SweetFeet's user avatar
  • 101
0 votes
0 answers
521 views

Cannot SSH from WSL1 (but from PS it works)

Does anyone know what could be the reason behind WSL not being able to SSH to a remote host, even though when using PUTTY, MobaXterm, XShell or even just Windows Powershell, the connection is clearly ...
Martin Ledermann's user avatar
1 vote
1 answer
3k views

Plink reverse ssh tunnel not working

I am trying to connect to a windows host (destination) behind a firewall via a reverse ssh tunnel. On the remote server I have edited /etc/ssh/ssh_config to enable AllowTcpForwarding yes ...
kiatra's user avatar
  • 11
1 vote
1 answer
1k views

How to provide two input lines to command executed with Plink

I have a issue like my script prompts to type Yes or No after sudo password prompt. So my question is if we have some way to pass two echo back to back? How can I do it? plink -ssh -no-antispoof ...
Prashant Gupta's user avatar
0 votes
0 answers
1k views

Plink is not accepting sudo password with dollar sign using echo

My Plink command is connecting successfully to the server using below command plink -ssh -no-antispoof USERNAME@SERVERNAME -pw HQ$tbHuvlk -t but when uses below command foe sudo its not working. ...
Prashant Gupta's user avatar
0 votes
1 answer
3k views

Why does plink or bash not recognize command on first line of remote commands file?

I am using plink and pageant in PowerShell to connect to and run commands on a linux machine via ssh. Within the PS script I am attempting to provide a unix script file to plink as follows. test.ps1: ...
Attila the Fun's user avatar
2 votes
1 answer
2k views

command line plink remote target capture traffic via jumphost [duplicate]

I am trying to capture remote host traffic via jumphost from a Windows machine and display in Wireshark. When PUTTY GUI is used and configured as below Created and saved SSH session (bastion-host) ...
rawat's user avatar
  • 43
1 vote
0 answers
5k views

plink - how to exit SSH session?

I have one linux machine with ssh enabled. I used plink on another machine (windows) to connect to my linux machine. After successfully connecting, I just exited power shell console and now I don't ...
Marin Leontenko's user avatar
1 vote
1 answer
931 views

Using Plink.exe to remotely logon to remote RedHat Linux server to run local Perl script

Long time member, first time poster. I have researched this issue thoroughly but I have not found a solution to this particular issue. I work in a NOC and I am responsible for monitoring servers. ...
HempKnight's user avatar
0 votes
1 answer
4k views

Does `-m` argument in `plink.exe` execute local or remote files?

I was trying to execute this remote file, but I keep getting error as "unable to open command file". plink.exe [email protected] -m //localfile/file.txt Will setting argument as -m execute the file ...
senor elanza's user avatar
0 votes
1 answer
2k views

plink - Password change required but no TTY available

I have 1000 servers to work with, but today all the server passwords expired.  I regularly use plink (PuTTY) to connect with 1000 servers.  Today I got error “Password change required but no TTY ...
Python Spark's user avatar
1 vote
2 answers
9k views

Executing multiple commands over serial port with PuTTY with a .bat file with a delay between individual commands

send.bat: plink -load test < commands.txt (test is a saved session in putty) commands.txt echo set_zero timeout /t 3 /nobreak >nul 2>&1 pause >nul 2>&1 echo set_a 65535 ...
yong.cheng's user avatar
1 vote
1 answer
1k views

Plink does not work with commands file for git in sudo

I use plink.exe for automatisation of git commands and this works fine. But i need to use this with servers with login of sudo plink.exe -ssh argenti[email protected] -m commands.txt my commands....
Eugen Gedroyc's user avatar
1 vote
0 answers
629 views

Unexpected behavior in VBScript with SendKeys

I'm attempting to create a VBScript I can run from a scheduled task to restart our SonicWall firewall. The firewall is a "lower-end" business model (TZ400), and I periodically have to reboot it ...
G_Hosa_Phat's user avatar
0 votes
1 answer
255 views

How to access a serial device from VM Server

I have a serial device that is physically connected to my Window PC. From my window, I can use "PUTTY" to set up the connection to access this device and do some extra work after login this device. ...
user3595231's user avatar
2 votes
0 answers
1k views

Why is an SSH socks5 proxy performing better than a normal socks5 proxy?

I've been trying to setup a proxy tunnel for gaming for the past month and have encountered (To me) a very strange issue. Currently I'm using a socksifier to redirect/edit the connect() command on a ...
VirtualSmile's user avatar
2 votes
1 answer
3k views

Is it possible to create a SOCKS chain using PLink on Windows?

I've been trying to create a chain of SOCKS proxies using the Dynamic Port parameter of PLink/PuTTy, but to no success. I'm currently trying to chain from my Windows machine using PLink/PuTTy > Linux ...
VirtualSmile's user avatar
0 votes
1 answer
647 views

Putty manual session and Plink session behave differently

HI I'm connecting to a remote Linux server using putty from a win PC and executing certain commands there. I wish to automate the tasks using plink as follows: plink serveradress -l userid -pwd pass -...
Abhi's user avatar
  • 13
0 votes
2 answers
2k views

How to pipe input to Wireshark in Windows Power Shell?

I am trying to run the following command in Power Shell: C:\Users\mne\Desktop\plink.exe -ssh -pw abc root@myhost "tcpdump -w - -U -i vethf90673c 'port 5000'" | &"C:\Program Files\Wireshark\...
Mohammed Noureldin's user avatar
0 votes
0 answers
3k views

How to escape password in plink sudo command?

When trying to login with plink to a server I don't know how to pass the sudo password in the command correctly. I use something like this: plink -ssh -t <user>@<server> -pw <password&...
user2718671's user avatar
2 votes
1 answer
3k views

How to catch “Access denied” using plink from powershell script

I have a powershell script that calls the following command: plink -batch -ssh $defUser@$srv -pw $defPassword -m $executeCommandFile The problem that $defPassword is not always the same/correct. How ...
igor's user avatar
  • 433
2 votes
1 answer
2k views

Properly escape awk command from powershell over plink

After (Powershell: Properly escape apostrophes) I still haven't figured out how to get those escapes right when executing a command over plink, coming from powershell. What I am trying to execute at ...
Bowi's user avatar
  • 1,457
2 votes
1 answer
1k views

ConEmu and console SSH clients that produce raw output (no ANSI escapes processed)

I use PuTTY daily and I use ConEmu heavily too (the latter mostly for Far Manager). A week ago I stopped using MTPuTTY in order to put PuTTY directly into ConEmu (because MTPuTTY grabs focus too ...
Lyubomyr Shaydariv's user avatar
1 vote
1 answer
3k views

Plink is not switching user using su command

I am connecting to a server via plink as follows: plink -ssh -l username -pw password example.host.com -m C:\Putty\input.txt > C:\Putty\output.txt input.txt contains whoami su - newsuser whoami ...
Gopi Krishnan's user avatar
2 votes
1 answer
815 views

Powershell: Properly escape apostrophes

I want to execute a command from powershell, which in turn executes a command on a foreign server, using plink. But this only works if I do not have ' or " in the command, otherwise Powershell jumps ...
Bowi's user avatar
  • 1,457
0 votes
1 answer
10k views

Make a reverse dynamic port forward using only Plink

A lot of tuto online give an explanation about how to configure ssh to make a dynamic port forwarding server. In my case, using only Plink, I have some trouble. The context is as follow : I want all ...
Duke Nukem's user avatar
3 votes
1 answer
11k views

Tunneling Using Plink: Command Line Option for "Local ports accept connections from other hosts"

I am trying to forward port from A:1234 to B:5678. Now, C will connect to A:1234 and will get forwarded to B:5678. I could get this to work using PuTTY using this configuration: PuTTY Tunnels ...
user avatar