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

Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

 
SOLVED
Go to solution
Highlighted
charlie watkins
Occasional Advisor

Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

I need to get the host name informatin from an SSH connection. With a telnet connection, I can do this with the lexical function F$GETJPI("","TT_PHYDEVNAM"), but that returns null on an SSH connection. Is there a way to get this information on SSH connections similar to the lexical function?
11 REPLIES 11
Phillip Thayer
Esteemed Contributor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

Wouldn't the host name be the same as the node name of the system?

Try using the F$GETSYI("NODENAME") instead.

Phil
Once it's in production it's all bugs after that.
charlie watkins
Occasional Advisor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

The lexical function F$GETJPI("","TT_PHYDEVNAM") returns the node name of the connecting node (remote node) for a telnet connections, which is the information I need to obtain for an SSH connection.

Thanks.
charlie watkins
Occasional Advisor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

And, of course, I cut-and-pasted the wrong argument into the body of my message. The argument should be TT_ACCPORNAM. The message should read:

I need to get the host name information from an SSH connection. With a telnet connection, I can do this with the lexical function F$GETJPI("","TT_ACCPORNAM"), but that returns null on an SSH connection. Is there a way to get this information on SSH connections similar to the lexical function?

Sorry for the confusion.
Peter Weaver_1
Frequent Advisor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

Check SYS$REM_NODE and/or SYS$REM_NODE_FULLNAME in the JOB table.
Richard Whalen
Honored Contributor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

Process Software's SSH product (and the SSH included with MultiNet and TCPware) support this.
Petr Spisek
Regular Advisor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

Hi,
it looks that this argument of lexical-function works only for TNA terminal device. Terminal device for SSH connection is FTA.

Try to find it by the help some procedure, for exmple via command TCPIP SHOW DEVICE/SERVICE=SSH

Petr
Steven Schweda
Honored Contributor
Solution

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

> Check SYS$REM_NODE and/or
> SYS$REM_NODE_FULLNAME in the JOB table.

These seem to work well for me.

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

Typical results from "show logical SYS$REM_NODE*":

(LNM$JOB_81AF6C80)

"SYS$REM_NODE" = "urtx.antinode.org::"
"SYS$REM_NODE_FULLNAME" = "urtx.antinode.org::"

(LNM$JOB_81601C00)

"SYS$REM_NODE" = "isis.visi.com::"
"SYS$REM_NODE_FULLNAME" = "isis.visi.com::"


The colons are annoying, but less so than
F$GETJPI("","TT_ACCPORNAM") not working.
charlie watkins
Occasional Advisor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

The SYS$REM_NODE and SYS$REM_NODE_FULLNAME logicals provide the information I needed. I just stripped the colons with an f$extract/f$locate statement.

Thanks for your responses.
Ian Miller.
Honored Contributor

Re: Getting F$GETJPI("","TT_ACCPORNAM") info on SSH connection

Charlie,
if you can find the time
http://forums1.itrc.hp.com/service/forums/helptips.do?#33
____________________
Purely Personal Opinion