PRIMARYINTERFACE statement

Restriction: The PRIMARYINTERFACE statement applies to IPv4 only.

Use the PRIMARYINTERFACE statement to specify which interface is to be designated as default local host for use by the GETHOSTID() function.

The PRIMARYINTERFACE statement's IP address is not used as the source IP address for any out-going datagrams, unless that same address is configured as the SOURCEVIPA address.

Start of changeIf no HOME statements are defined in the profile, PRIMARYINTERFACE defaults to the first IPv4 INTERFACE statement listed in the profile.End of change

Syntax

Read syntax diagramSkip visual syntax diagram
>>---PRImaryinterface --interface_name-------------------------><

Parameters

interface_name
The name of an interface that is to be the primary interface. This interface must have already been defined to TCP/IP. If you specify the name of a dynamic VIPA interface, the dynamic VIPA must have been defined in a VIPADYNAMIC block. You cannot specify a loopback interface name.

Steps for modifying

To modify parameters for the PRIMARYINTERFACE statement, you must respecify the statement with the new parameters.

Include the PRIMARYINTERFACE statement in a VARY TCPIP,,OBEYFILE command data set under the following conditions:
  • Your primary interface is defined by the DEVICE, LINK, and HOME profile statements.
  • The VARY TCPIP,,OBEYFILE command data set includes a HOME statement.
  • You want to preserve your primary interface settings.
If you do not include the PRIMARYINTERFACE statement under these conditions, the primary interface is reset to the first entry in the new HOME list. If your primary interface is defined by an INTERFACE profile statement, including a HOME statement in a VARY TCPIP,,OBEYFILE command data set does not affect the primary interface settings.

Examples

This example shows a PRIMARYINTERFACE statement specifying a token-ring:
PRIMARYINTERFACE TR1
You can verify which HOME entry is primary by using the Netstat HOME/-h command:
Home address list:
Address          Link             Flg
9.67.113.61      TR1              P
9.67.116.125     CTCD00
127.0.0.1        LOOPBACK

Usage notes

Related topic