1 | Qualified user space name | Input | Char(20) |
2 | Format name | Input | Char(8) |
3 | Error Code | I/O | Char(*) |
The List Network Routes (QtocLstNetRte) API returns a detailed list of all routes. This API returns all IPv4 routes using one output format name, and all IPv6 routes using a different output format name.
TCP/IP must be active on this system; otherwise, a message will be issued.
The user space that is to receive the created list. The first 10 characters contain the user space name, and the second 10 characters contain the name of the library where the user space is located. You can use these special values for the library name:
*CURLIB | The job's current library |
*LIBL | The library list |
The format of the route information to be returned. The format names supported are:
NRTE0100 | Detailed information about each TCP/IPv4 route. Refer to NRTE0100 Format for details on the format. |
NRTE0200 | Detailed information about each TCP/IPv6 route. Refer to NRTE0200 Format for details on the format. |
The structure in which to return error information. For the format of the structure, see Error Code Parameter.
To request a list of all routes, use format NRTE0100.
The route description list consists of:
For details about the user area and generic header, see User Space Format for List APIs. For details about the remaining items, see the following sections.
When you retrieve list entry information from a user space, you must use the entry size returned in the generic header. The size of each entry may be padded at the end. If you do not use the entry size, the result may not be valid. For examples of how to process lists, see API Examples.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | CHAR(10) | User space name specified |
10 | A | CHAR(10) | User space library name specified |
20 | 14 | CHAR(8) | Format name specified |
28 | 1C |
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | CHAR(10) | User space name used |
10 | A | CHAR(10) | User space library name used |
20 | 14 |
To retrieve the list of TCP/IPv4 routes, request format NRTE0100, and you will get a repeating list of NRTE0100 tables, each one returning information about a single IPv4 route. To retrieve the list of TCP/IPv6 routes, request format NRTE0200, and you will get a repeating list of NRTE0200 tables, each one returning information about a single IPv6 route.
The following information about each TCP/IPv4 route is returned for the NRTE0100 format. For detailed descriptions of the fields in the table, see Field Descriptions.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | CHAR(15) | Route destination |
15 | F | CHAR(1) | Reserved |
16 | 10 | BINARY(4) | Route destination binary |
20 | 14 | CHAR(15) | Subnet mask |
35 | 23 | CHAR(1) | Reserved |
36 | 24 | BINARY(4) | Subnet mask binary |
40 | 28 | CHAR(15) | Next hop |
55 | 37 | CHAR(1) | Reserved |
56 | 38 | BINARY(4) | Next hop binary |
60 | 3C | BINARY(4) | Route status |
64 | 40 | BINARY(4) | Type of service |
68 | 44 | BINARY(4) | Route MTU |
72 | 48 | BINARY(4) | Route type |
76 | 4C | BINARY(4) | Route source |
80 | 50 | BINARY(4) | Route precedence |
84 | 54 | BINARY(4) | Local binding interface status |
88 | 58 | BINARY(4) | Local binding type |
92 | 5C | BINARY(4) | Local binding line type |
96 | 60 | CHAR(15) | Local binding interface |
111 | 6F | CHAR(1) | Reserved |
112 | 70 | BINARY(4) | Local binding interface binary |
116 | 74 | CHAR(15) | Local binding subnet mask |
131 | 83 | CHAR(1) | Reserved |
132 | 84 | BINARY(4) | Local binding subnet mask binary |
136 | 88 | CHAR(15) | Local binding network address |
151 | 97 | CHAR(1) | Reserved |
152 | 98 | BINARY(4) | Local binding network address binary |
156 | 9C | CHAR(10) | Local binding line description |
166 | A6 | CHAR(8) | Change date |
174 | AE | CHAR(6) | Change time |
180 | B4 |
Change date.The date of the most recent change to this route in the dynamic tables used by the TCP/IP protocol stack. It is returned as 8 characters in the form YYYYMMDD, where:
YYYY | Year |
MM | Month |
DD | Day |
Change time.The time of the most recent change to this route in the dynamic tables used by the TCP/IP protocol stack. It is returned as 6 characters in the form HHMMSS, where:
HH | Hour |
MM | Minute |
SS | Second |
Local binding interface. The IP interface to bind to this route.
Local binding interface binary. Binary representation of the local binding interface.
Local binding interface status. The current status of this logical interface.
The possible values are:
0 | Inactive - The interface has not been started. The interface is not active. |
1 | Active - The interface has been started and and is running. |
2 | Starting - The system is processing the request to start this interface. |
3 | Ending - The system is processing the request to end this interface. |
4 | RCYPND - An error with the physical line associated with this interface was detected by the system. The line description associated with this interface is in the recovery pending (RCYPND) state. |
5 | RCYCNL - A hardware failure has occurred and the line description associated with this interface is in the recovery canceled (RCYCNL) state. |
6 | Failed - The line description associated with this interface has entered the failed state. |
7 | Failed (TCP) - An error was detected in the IBM TCP/IP Vertical Licensed Internal Code. |
8 | DOD - Point-to-Point (PPP) Dial-on-Demand. |
9 | Active Duplicate IP Address Conflict - Another host on the LAN responded to a packet destined for this logical interface. |
Local binding line description. Each TCP/IP interface is associated with a network. This field displays the name of the communications line description or virtual line (L2TP) that identifies the network associated with an interface. The following are special values:
*IPI | This interface is used by Internet Protocol (IP)
over Internetwork Packet Exchange (IPX)
Note: As of V5R2, IP over IPX is no longer supported. |
This interface is used by Internet Protocol (IP) over SNA. | |
*LOOPBACK | This is a loopback interface. Processing associated with a loopback interface does not extend to a physical line. |
*VIRTUALIP | The virtual interface is a circuitless interface. It is used in conjunction with the associated local interface (LCLIFC) when adding standard interfaces. |
*OPC | This interface is attached to the optical bus (OptiConnect). |
Local binding line type. Indicates the type of line used by an interface. The following link protocols are supported:
-1 | OTHER -
Note: As of V5R2, IP over IPX is no longer supported. |
-2 | NONE - Line is not defined. This is used for the following interfaces: *LOOPBACK, *VIRTUALIP, *OPC. There is no line type value for these interfaces. |
-3 | ERROR - This value is displayed if any system errrors other than those for *NOTFND are received while trying to determine the link type for an interface. |
-4 | NOTFND - Not found. This value is displayed if the line description object for this interface cannot be found. |
1 | ELAN - Ethernet local area network protocol. |
2 | TRLAN - Token-ring local area network protocol. |
3 | FR - Frame relay network protocol. |
4 | ASYNC - Asynchronous communications protocol. |
5 | PPP - Point-to-point Protocol. |
6 | WLS - Wireless local area network protocol. |
7 | X.25 - X.25 protocol. |
8 | DDI - Distributed Data Interface protocol. |
9 | TDLC - Twinaxial Datalink Control. Used for TCP/IP over Twinax. |
Local binding network address. The internet address, in dotted decimal notation, of the IP network or subnetwork that the interface is attached to.
Local binding network address binary. Binary representation of the local binding network address.
Local binding subnet mask. The subnet mask for the network, subnet, and host address fields of the internet address, in dotted decimal notation, that defines the subnetwork for an interface.
Local binding subnet mask binary. Binary representation of the local binding subnet mask.
Local binding type. The possible values are:
0 | Dynamic |
1 | Static |
Next hop. The internet address of the first system on the path from your system to the route destination in dotted decimal notation. The following are special values:
*DIRECT
This is the next hop value of a route that is automatically created. When an interface is added to this system, a route to the network the interface attaches to is also created.
Next hop binary. The binary represenation of the next hop. For *DIRECT this will be the local binding network address.
Reserved. An ignored field.
Route destination. The Internet Protocol (IP) address, in dotted decimal notation, of the ultimate destination reached by this route. When used in combination with the subnet mask and the type of service values, the route destination identifies a route to a network or system.
Route destination binary. The binary representation of the route destination.
Route MTU. A number representing the maximum transmission unit (MTU) value for this route in bytes. The following are special values:
-1 | OTHER -
Note: As of V5R2, IP over IPX is no longer supported. |
0 | IFC - The route is not currently active and the MTU was specified as *IFC. |
Route precedence. Identify priority of route, range 1-10. Lowest priority being 1.
Route source. Specifies how this route was added to the IP routing tables. The possible values are:
-1 | OTHER - The route was added by a sockets input/output control (IOCtl) or other mechanism. |
0 | CFG - The route was added with system configuration commands. |
1 | ICMP - The route was added by the Internet Control Message Protocol (ICMP) redirect mechanism. |
2 | SNMP - The route was added by the Simple Network Management Protocol (SNMP). |
3 | RIP - The route was added by the Routing Information Protocol (RIP). |
Route status. Indicated whether this route is available.
1 | YES - The router specified by the next hop value for this interface is available for use. This route is included amoung the routes considered when datagram routing is performed by TCP/IP. |
2 | NO - The router specified by the next hop value for this interface is not available for use, interface is not active. This route is not included amoung the routes considered when datagram routing is performed. |
3 | DOD - This route is used for Point-to-Point (PPP) Dial-on-Demand. Currently, this Dial-on-Demand route is not available. The route will become available when a Dial-on-Demand session is initiated for the interface this route is associated with. |
4 | NO GATEWAY - The router specified by the next hop value for this interface is not available for use, the router may be experiencing a problem. |
Route type. The route types are:
0 | DFTROUTE - A default route. |
1 | DIRECT - A route to a network or subnetwork to which this system has a direct physical connection. |
2 | HOST - A route to a specific remote host. |
3 | SUBNET - An indirect route to a remote subnetwork. |
4 | NET - An indirect route to a remote network. |
Subnet mask. The actual value of the subnet mask in dotted decimal notation.
Subnet mask binary. The binary representation of the subnet mask.
Type of service. Defines how the internet hosts and routers should make trade-offs between throughput, delay, reliability and cost. The following are special values:
-1 | OTHER -
Note: As of V5R2, IP over IPX is no longer supported. |
1 | NORMAL - Used for delivery of datagrams. |
2 | MINDELAY - Prompt delivery of datagrams with the minimize delay indication. |
3 | MAXTHRPUT - Datagrams with maximize throughput indication. |
4 | MAXRLB - Datagrams with maximize reliability indication. |
5 | MINCOST - Datagrams with minimize monetary cost indication. |
The following information about each TCP/IPv6 route is returned for the NRTE0200 format. For detailed descriptions of the fields in the table, see Field Descriptions.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | CHAR(45) | Route destination |
45 | 2D | CHAR(3) | Reserved |
48 | 30 | CHAR(16) | Route destination binary |
64 | 40 | CHAR(3) | Prefix length |
67 | 43 | CHAR(5) | Reserved |
72 | 48 | BINARY(4) | Prefix length binary |
76 | 4C | BINARY(4) | Next hop address family |
80 | 50 | CHAR(45) | Next hop IPv6 |
125 | 7D | CHAR(3) | Reserved |
128 | 80 | CHAR(16) | Next hop IPv6 binary |
144 | 90 | CHAR(15) | Next hop IPv4 |
159 | 9F | CHAR(1) | Reserved |
160 | A0 | BINARY(4) | Next hop IPv4 binary |
164 | A4 | CHAR(10) | Local binding line name |
174 | AE | CHAR(2) | Reserved |
176 | B0 | BINARY(4) | Local binding line type |
180 | B4 | BINARY(4) | Local binding line status |
184 | B8 | BINARY(4) | Route status |
188 | BC | BINARY(8) | Route lifetime remaining |
196 | C4 | BINARY(4) | Route lifetime at creation |
200 | C8 | BINARY(4) | Route source |
204 | CC | BINARY(4) | Route type |
208 | D0 | BINARY(4) | Configured route MTU |
212 | D4 | BINARY(4) | Actual route MTU |
216 | D8 | BINARY(4) | Is on-link |
220 | DC | BINARY(4) | Duplicate indicator |
224 | E0 | CHAR(8) | Change date |
232 | E8 | CHAR(6) | Change time |
238 | EE | CHAR(8) | Expiration date |
246 | F6 | CHAR(6) | Expiration time |
252 | FC | CHAR(50) | Text description |
302 | 12E | CHAR(2) | Reserved |
304 | 130 | BINARY(4) | Text description CCSID |
308 | 134 |
Actual route MTU. A number representing the maximum transmission unit (MTU) value for this route in bytes.
The following is a special value:
0 | *IP6LINMTU - The route is not currently active and the MTU was specified as *IP6LINMTU, the MTU value of the line to which this route is bound. |
Change date. The date of the most recent change to this route in the dynamic tables used by the TCP/IPv6 protocol stack. It is returned as 8 characters in the form YYYYMMDD, where:
YYYY | Year |
MM | Month |
DD | Day |
Change time. The time of the most recent change to this route in the dynamic tables used by the TCP/IPv6 protocol stack. It is returned as 6 characters in the form HHMMSS, where:
HH | Hour |
MM | Minute |
SS | Second |
Configured route MTU. A number representing the configured maximum transmission unit (MTU) value for this route in bytes.
The following is a special value:
0 | *IP6LINMTU - The route MTU was specified as *IP6LINMTU, the MTU value of the line to which this route is bound. |
Duplicate indicator. Indicates whether this route is a duplicate of another route in the routing table or not, and also whether there are any routes which are duplicates of this route. Use the Route status field to determine whether the route is in use or not.
Possible values are:
1 | This route is not a duplicate of another route and it does not have any duplicates. |
2 | This route is not a duplicate of another route but it does have duplicates. |
3 | This route is a duplicate of another route. |
Expiration date. The date when this route will expire or did expire. If the Expiration date and time are in the future, the route has not expired yet. If the Expiration date and time are in the past, then this route has expired and is still being returned for a short period of time to indicate that the route ceased to function because its lifetime expired. The Expiration date is returned as 8 characters in the form YYYYMMDD.
The meaning of the characters is as follows:
YYYY | Year |
MM | Month |
DD | Day |
The following is a special value:
00000000 | Infinite - this route has an infinite lifetime which never expires. |
Expiration time. The time when this route will expire or has expired. If the Expiration date and time are in the future, the route has not expired yet. If the Expiration date and time are in the past, then this route has expired and is still being returned for a short period of time to indicate that the route ceased to function because its lifetime expired. The Expiration time is returned as 6 characters in the form HHMMSS.
The meaning of the characters is as follows:
HH | Hour |
MM | Minute |
SS | Second |
The following is a special value:
000000 | Infinite - this route has an infinite lifetime which never expires. |
Is on-link. Indicates whether this route is for a directly attached prefix (network) or not.
Possible values are:
0 | Unknown, the on-link status of this route is undetermined. |
1 | Yes, this is a route to a directly attached prefix. |
Note: As of V5R4, this field is no longer available and is always set to 0.
Local binding line name. The name of the communications line description to which this route is bound. This field is NULL padded.
The following are special values:
*LOOPBACK | This route is bound to the loopback interface. Processing associated with the loopback interface does not extend to a physical line. |
*VIRTUALIP | The virtual interface is a circuitless interface.
It is used in conjunction with the associated local interface (LCLIFC) when
adding standard interfaces.
Note: As of V5R4, this value is no longer supported. |
*OPC | This interface is attached to the optical bus
(OptiConnect).
Note: As of V5R4, this value is no longer supported. |
*TNLCFG64 | This interface is bound to a configured 6-4
tunneling line.
Note: As of V5R4, this value is no longer supported. |
Local binding line status. The current operational status of the communications line to which this route is bound.
Possible values are:
1 | Active - The line is operational. |
2 | Inactive - The line is not operational. |
3 | Failed - The desired state of the line is Active, but it is currently in the Inactive state. |
Local binding line type. Indicates the type of line to which this route is bound.
Possible values are:
-1 | OTHER |
-2 | NONE - Line is not defined. This value is used for the following interface: *LOOPBACK. There is no line type value for this interface. |
-3 | ERROR - This value is displayed if any system errrors other than those for *NOTFND are received while trying to determine the link type for an interface. |
-4 | NOTFND - Not found. This value is displayed if the line description object for this interface cannot be found. |
1 | ELAN - Ethernet local area network protocol. |
2 | TRLAN - Token-ring local area network protocol. |
3 | FR - Frame relay network protocol. |
4 | ASYNC - Asynchronous communications protocol. |
5 | PPP - Point-to-point Protocol. |
6 | WLS - Wireless local area network protocol. |
7 | X.25 - X.25 protocol. |
8 | DDI - Distributed Data Interface protocol. |
9 | TDLC - Twinaxial Datalink Control. Used for TCP/IP over Twinax. |
10 | L2TP (Virtual PPP) - Layer Two Tunneling Protocol. |
11 | IPv6 Tunneling Line - Any kind of IPv6 over IPv4
tunnel.
Note: As of V5R4, TRLAN, FR, ASYNC, PPP, WLS, X.25, DDI, TDLC, L2TP and IPv6 Tunneling Line values are no longer supported. |
Next hop address family. The address family of the Next Hop address for this route. Use this field to determine whether the IPv4 or IPv6 Next Hop field contains the value of the next hop.
Possible values are:
1 | AF_INET - The next hop is an IPv4 address. Use the Next hop IPv4 fields. |
2 | AF_INET6 - The next hop is an IPv6 address. Use the Next hop IPv6 fields. |
Note: As of V5R4, AF_INET is no longer supported for next hop address family.
Next hop IPv4. The IPv4 internet address of the first system on the path from this system to the route destination in dotted-decimal format. The next hop will only be an IPv4 address when the route uses an IPv6 over IPv4 tunnel. This field is only valid when the value of the Next hop address family field is AF_INET. This field is NULL padded
Note: As of V5R4, this field is no longer available and is always set to 0.
Next hop IPv4 binary. The binary representation of the Next hop IPv4 field. This field is only valid when the value of the Next hop address family field is AF_INET.
Note: As of V5R4, AF_INET is no longer supported for a next hop address family. As a result, the value in this field is no longer valid.
Next hop IPv6. The IPv6 internet address of the first system on the path from your system to the route destination in IPv6 address format. This field is only valid when the value of the Next hop address family field is AF_INET6. This field is NULL padded.
The following special value may be returned:
*DIRECT | This is the next hop value of a route that is automatically created. When an interface is added to this system, a route to the network the interface attaches to is also created. |
Next hop IPv6 binary. The binary representation of the Next hop IPv6 field. Even though this field is defined as a character field, a binary IPv6 address is returned in it except when the following special character values are returned. This field is only valid when the value of the Next hop address family field is AF_INET6.
The following special value may be returned:
*DIRECT | This is the next hop value of a route that is automatically created. When an interface is added to this system, a route to the network the interface attaches to is also created. |
Prefix length. The prefix length defines how many bits of the route destination IPv6 address are in the prefix. It is a zoned decimal number which specifies how many of the left-most bits of the address make up the prefix. The prefix length is used to generate network and host addresses. This field is NULL padded.
Prefix length binary. Binary representation of the prefix length.
Reserved. An ignored field.
Route destination. The Internet Protocol version 6 (IPv6) address, in IPv6 address format, of the ultimate destination reached by this route. When used in combination with the prefix length the route destination identifies a route to a network or system. This field is NULL padded.
Route destination binary. The binary representation of the route destination. Even though this field is defined as a character field, a binary IPv6 address is returned in it.
Route lifetime at creation. The route lifetime value which this route had when it was first created, either automatically or by manual configuration. The route lifetime value is the length of time, in seconds, that a route remains in the route table. Only routes which are discovered on the network will have route lifetimes shorter than infinite. Valid values range from 1 through 4294967295 seconds.
The following is a special value:
0 | Infinite - this route had an infinite lifetime when it was created. |
Note: As of V5R4, the route lifetime at creation field is always set to infinite.
Route lifetime remaining. The length of time, in seconds, that a route remains in the route table. Only routes which are discovered on the network will have route lifetimes shorter than infinite. Valid values range from -31536000 through 4294967295 seconds. Negative values indicate that the route has expired, but it is being retained for a short period of time to show why the route ceased to function.
The following is a special value:
-1000000000 | Infinite - this route has an infinite lifetime. |
Note: As of V5R4, the route lifetime remaining field is always set to infinite.
Route source. Specifies how this route was added to the IPv6 routing table.
The possible values are:
0 | Unknown |
1 | ICMPv6 Redirect - This route was added by the ICMPv6 redirect mechanism. |
2 | ICMPv6 Router Advertisement Router Lifetime - This route was added because of the presence of a non-zero value in the Router Lifetime field in a Router Advertisement packet received by the system. |
3 | ICMPv6 Router Advertisement Prefix Information Option - This route was added because of the presence of a Prefix Information Option on a Router Advertisement packet received by the system. |
4 | CFG RTE - This route was manually configured. |
5 | CFG IFC - This route was added when because of a manually configured interface. |
6 | Autoconfigured Interface - This route was added when because of an interface added by stateless autoconfiguration. |
7 | RIP - This route was added by the Routing Information Protocol (RIP). |
8 | OSPF - This route was added by the Open Shortest Path First (OSPF) routing protocol. |
9 | ROUTING - This route was determined to be necessary and added by the TCP/IP stack on this system. |
Route status. The current state of the route.
Possible values are:
0 | Unknown |
1 | Active - This route is currently active and is in the current route search path. |
3 | Inactive - This route is not in the current route search path, and is not being used. |
Route type. The type of route that this route is.
Possible values are:
0 | Unknown |
1 | DFTROUTE - A default route. |
2 | DIRECT - A route to a network to which this system has a direct physical connection. |
3 | HOST - A route to a specific remote host. |
4 | NET - An indirect route to a remote network. |
Text description. User added text description associated with the route.
Text description CCSID. Coded character set ID for the text description.
Message ID | Error Message Text |
---|---|
TCP84C0 E | TCP/IP stack not active. |
TCP84C5 E | API error providing TCP/IP Network Status list information. |
TCP84C6 E | Internal operations error - RESULT &1 CC &2 RC &3 ERRNO &4. |
TCP84C9 I | Information returned incomplete. |
CPF0F03 E | Error in retrieving the user space that was created by the caller. |
CPF24B4 E | Severe error while addressing parameter list. |
CPF3C1E E | Required parameter &1 omitted. |
CPF3C21 E | Format name &1 is not valid. |
CPF3CF1 E | Error code parameter not valid. |
CPF3CF2 E | API contains a problem. See prior messages to determine why the failure occurred. |
CPF8100 E | All CPF81xx messages could be returned. xx is from 01 to FF. |
CPF9801 E | Object &2 in library &3 not found. |
CPF9802 E | Not authorized to object &2 in &3. |
CPF9803 E | Cannot allocate object &2 in library &3. |
CPF9807 E | One or more libraries in library list deleted. |
CPF9808 E | Cannot allocate one or more libraries on library list. |
CPF9810 E | Library &1 not found. |
CPF9820 E | Not authorized to use library &1. |
CPF9830 E | Cannot assign library &1. |
CPF9872 E | Program or service program &1 in library &2 ended. Reason code &3. |
Top | Communications APIs | APIs by category |