1751805 Members
5504 Online
108781 Solutions
New Discussion юеВ

Re: SSH Hangs

 
jim lake
Occasional Advisor

SSH Hangs

Hi,

I'm using ssh to connect to anouther vms node and execute a .com file. The command that I am using is as follows

ssh xxx.xxx.xxx.xxx -o "batchmode yes" @sys$sysdevice:[users.frank]script.com;

after the script runs it just hangs. I attempted to add line that reads exit in the COM file that it's executing. This never helped.

Thanks
3 REPLIES 3
Steven Schweda
Honored Contributor

Re: SSH Hangs

John Travell
Valued Contributor

Re: SSH Hangs

Does it still hang if you put
$ logout
at the end of the command procedure ?

You could make that
$ if f$mode() .eqs. "BATCH" then logout
but I have not yet checked what mode an SSH remote batchmode runs as, so you will probably need to amend it accordingly.

I have never needed to try this before, and I get:-
warning: Authentication failed.
Disconnected; no more authentication methods available (No further authentication methods available.).

I guess I need to setup proxies or something, no time now to read up on what's needed.
JT:
Steven Schweda
Honored Contributor

Re: SSH Hangs

> Does it still hang if you put
> $ logout
> at the end of the command procedure ?

Locally, the SSH command hangs. Anything
after that doesn't matter. On the remote
side, it doesn't matter.

> I have never needed to try this before
> [...]

I'd suggest getting SSH to work
interactively, then worrying about the fancy
stuff. (After reading the instructions, if
it still fails, try "ssh -v [...]".)

> [...] I have not yet checked what mode an
> SSH remote batchmode runs as, [...]

NETWORK, same as without "batchmode yes".
This "batchmode" is unrelated to VMS BATCH
mode.

Returning to the real world, so far, I
haven't found anything to beat the "define
/user sys$command nl:" method already
suggested.