Operating System - OpenVMS
Showing results for 
Search instead for 
Did you mean: 

sftp on OpenVMS

Dane Rood
Occasional Visitor

sftp on OpenVMS

How do I specify a port using sftp on OpenVMS.

If I enter "sftp" i get to the sftp> prompt. However, if I enter any parm such as "sftp -P=nnn" Or "sftp -Pnnn" where nnn is the port of an ssh server on another node, I get the following response:

Usage: sftp2 [-D debug_level_spec] [-b batchfile] [-S path] [-h] [-V] [-P ssh2-port] host

if I just enter sftp, I get to the sftp> prompt. I can do a help at that point but I see no way to specify a port.

Dale A. Marcy
Trusted Contributor

Re: sftp on OpenVMS

I am guessing you use TCPIP from HP. We use Multinet, so I cannot test it, but my guess would be to try the following:

$ sftp "-P nnn"

The character " is the double quote character.
Dane Rood
Occasional Visitor

Re: sftp on OpenVMS

Dale, thx, that moved me along to:

>sftp "-P 998"
FATAL: Connecting to failed: Connection Timed Out

Warning: child process (/sys$system/tcpip$ssh_ssh2) exited with code 188.

%TCPIP-E-SSH_FC_ERROR, undetermined error within sshfilecopy

I know the ssh server is set up properly because I can connect using putty's psftp from DOS on my workstation. Perhaps there's another arg for the OpenVMS sftp program that i'm not specifying. thx again for your help.

Richard Whalen
Honored Contributor

Re: sftp on OpenVMS

sftp> open node#port

This works for MultiNet & TCPware, and I believe that TCP/IP Services uses the same code base.
Steven Schweda
Honored Contributor

Re: sftp on OpenVMS

How about:

"-P" 998


Quoting the pair as a unit could confuse it.
Dane Rood
Occasional Visitor

Re: sftp on OpenVMS

Getting closer, with: sftp> open node#port I get the error below.

Opening connection to node#998
warning: Error trying to access file /etc/ssh2/hostkeys/key_998_24_107_94_175.pub.
Host key not found from database.
Key fingerprint:
You can get a public key's fingerprint by running
$ ssh_keygen "-F" publickey.pub
on the keyfile.
Are you sure you want to continue connecting (yes/no)?
Host key saved to ssh2/hostkeys/key_port_node.pub
host key for node, accepted by userid Mon Oct 31 2005 15:41:14
warning: Authentication failed.
Disconnected; no more authentication methods available (No further authentication methods available.).
FATAL: ssh2 client failed to authenticate. (or you have too old ssh2 installed, check with ssh2 "-V")

It connects, brings down the necessary key after my reply but then bombs with the FATAL error.

I run ssh "-V" and get:

$1$dga924:[sys0.syscommon.][sysexe]tcpip$ssh_ssh2.exe;1: SSH Secure Shell OpenVM
S (V1.0) 2.4.1 on AlphaServer DS20 500 MHz - VMS V7.3-2

I run ssh "-V" and get:

It looks like perhaps my OpenVMS ssh2 is out of synch with my Linux version.
Steven Schweda
Honored Contributor

Re: sftp on OpenVMS

I don't know if it matters, but here:

alp $ ssh "-V"
alp$dka0:[sys0.syscommon.][sysexe]tcpip$ssh_ssh2.exe: SSH Secure Shell OpenVMS (V5.5) 3.2.0 on COMPAQ Professional Workstation - VMS V7.3-2

alp $ tcpip show version

HP TCP/IP Services for OpenVMS Alpha Version V5.4 - ECO 5
on a COMPAQ Professional Workstation XP1000 running OpenVMS V7.3-2

You seem to be an ECO or two behind current.
Ian Miller.
Honored Contributor

Re: sftp on OpenVMS

install the ECO kit - it contains many things including an updated ssh
Purely Personal Opinion
Dane Rood
Occasional Visitor

Re: sftp on OpenVMS

I have successfully connected to an SSH server from OpenVMS. It appears the problem I've been having has to do with firewall parms trying to get out of our company's network. When I connected to an SSH server on our network, it worked fine. Thanks to everyone for their help and comments.