Hi,
I am new to unix and plink in general. I want to run plink.exe on windows to execute alias command on unix. Is it possible? I can run simple unix commands from plink for ex:
It successfully creates the "filename" file on the hostip host.
But if I create an alias for it:
and I run from plink:
it returns: ksh: createfile: not found
I tried also:
result was: FATAL ERROR: Server refused to start a shell/command
So how can I run alias commands within plink?
Thanks,
Ivanhou
Moderator's Comments:
Please use CODE tags as required by forum rules!
Last edited by RudiC; 03-14-2017 at 07:35 AM..
Reason: Added CODE tags.
I have a program to scan the log files and I want to pipe the output to 'less'.
I want to create an alias such that following are equivalent
scanlog chunky.lst = /udd/n2man/utils/scanlog chunky.lst|less
where chunky is user supplied file which can change.
Is this possible as an alias or... (1 Reply)
Hi,
I have a simple windows batch file which connects to a UNIX server and runs a shell script in my home directory on the server.
It works perfectly, using plink + ssh keys in the background.
What I plan to do is expand this batch file to connect to multiple servers and execute one script... (2 Replies)
i have a cygwin unix and i would like to use alias to save a cd command.. however i lose this alias when i close out cygwin and log back in.. is there any way to save this command so that i can use it every time i log in? i am using cygwin on windows xp. thanks. (1 Reply)
Hi,
I want to set Unix prompt in C-Shell which required the break new line using alias.
Ex.
hostname : username :
%>
Now, it will be setup in .login file with alias
alias cd 'cd \!* | set prompt="`hostname` : $USER : %>"'
I'm unable to parse echo command or break which I can get %>... (1 Reply)
Hi,
I want to set Unix prompt in C-Shell which required the break new line using alias.
Ex.
hostname : username :
%>
Now, it will be setup in .login file with alias
alias cd 'cd \!* | set prompt="`hostname` : $USER : %>"'
I'm unable to parse echo command or break which I can get %>... (3 Replies)
I have a file named 'aliases' which contains a list of aliases like:
alias loc='locate'
alias h='history'
alias .='pwd'
alias ..='cd ..'
alias cd..='cd .. ; pwd'
..............................
Where should I put this file (alias) so when Terminal launches .bash and thus a shell at... (1 Reply)
If one:
$ find -name 'some expression' -type f > newfile
and then subsequently wants to create an alias file from each pathname the find command retrieved and the > placed within 'newfile', how would one do this? Ideally, the newly created alias files would all be in one directory.
I am... (3 Replies)
Defined a user alias in unix. Not able to use that alias in a ksh scritp. I dont want to change/source in the script to set the value. Need to set the user alias as a gloabal alias to use it in a new ksh shell window. Can you please help on this? (3 Replies)
Hi All,
Iam a newbie to the plink and need your assistance. I have referred some posts but it doesn't helps me much.
I have two steps to do.
1. I have a config file which has a list of servers,username and password.
2. I have a shell script in windows which accepts arguments and need to... (0 Replies)
Discussion started by: cskumar
0 Replies
LEARN ABOUT DEBIAN
plink
plink(1) PuTTY tool suite plink(1)NAME
plink - PuTTY link, command line network connection tool
SYNOPSIS
plink [options] [user@]host [command]
DESCRIPTION
plink is a network connection tool supporting several protocols.
OPTIONS
The command-line options supported by plink are:
-V Show version information and exit.
-pgpfp Display the fingerprints of the PuTTY PGP Master Keys and exit, to aid in verifying new files released by the PuTTY team.
-v Show verbose messages.
-load session
Load settings from saved session.
-ssh Force use of SSH protocol (default).
-telnet
Force use of Telnet protocol.
-rlogin
Force use of rlogin protocol.
-raw Force raw mode.
-serial
Force serial mode.
-P port
Connect to port port.
-l user
Set remote username to user.
-m path
Read remote command(s) from local file path.
-batch Disable interactive prompts.
-pw password
Set remote password to password. CAUTION: this will likely make the password visible to other users of the local machine (via com-
mands such as `w').
-L [srcaddr:]srcport:desthost:destport
Set up a local port forwarding: listen on srcport (or srcaddr:srcport if specified), and forward any connections over the SSH con-
nection to the destination address desthost:destport. Only works in SSH.
-R [srcaddr:]srcport:desthost:destport
Set up a remote port forwarding: ask the SSH server to listen on srcport (or srcaddr:srcport if specified), and to forward any con-
nections back over the SSH connection where the client will pass them on to the destination address desthost:destport. Only works in
SSH.
-D [srcaddr:]srcport
Set up dynamic port forwarding. The client listens on srcport (or srcaddr:srcport if specified), and implements a SOCKS server. So
you can point SOCKS-aware applications at this port and they will automatically use the SSH connection to tunnel all their connec-
tions. Only works in SSH.
-X Enable X11 forwarding.
-x Disable X11 forwarding (default).
-A Enable agent forwarding.
-a Disable agent forwarding (default).
-t Enable pty allocation (default if a command is NOT specified).
-T Disable pty allocation (default if a command is specified).
-1 Force use of SSH protocol version 1.
-2 Force use of SSH protocol version 2.
-C Enable SSH compression.
-i path
Private key file for authentication.
-s Remote command is SSH subsystem (SSH-2 only).
-N Don't start a remote command or shell at all (SSH-2 only).
-sercfg configuration-string
Specify the configuration parameters for the serial port, in -serial mode. configuration-string should be a comma-separated list of
configuration parameters as follows:
o Any single digit from 5 to 9 sets the number of data bits.
o `1', `1.5' or `2' sets the number of stop bits.
o Any other numeric string is interpreted as a baud rate.
o A single lower-case letter specifies the parity: `n' for none, `o' for odd, `e' for even, `m' for mark and `s' for space.
o A single upper-case letter specifies the flow control: `N' for none, `X' for XON/XOFF, `R' for RTS/CTS and `D' for DSR/DTR.
MORE INFORMATION
For more information on plink, it's probably best to go and look at the manual on the PuTTY web page:
http://www.chiark.greenend.org.uk/~sgtatham/putty/
BUGS
This man page isn't terribly complete. See the above web link for better documentation.
PuTTY tool suite 2004-03-24 plink(1)