If IPv4 only, just do an INITAPI, GETHOSTID, TERMAPI. This will return
the primary address of the TCP/IP stack that your job is associated with.
But, if you already have a connection to another host, that host can get
your address easily.
Tony Thigpen
Stan Weyman wrote on 4/29/19 8:00 AM:
Is there an accessible control block that holds the IP address (or
addresses) for the current LPAR I'm running on? I have need to pass back this
address to another remote application and would prefer to interrogate a control
block rather than issue commands to obtain same a la D TCPIP,,NETSTAT,HOME
(although this would be my alternative). A sample snippet of code would be
great but the location should let me get there.
Is there any other option that getting the @ from a control block or using
D TCPIP,,NETSTAT,HOME?
Thanks ahead of time
Regards
Stan
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN