Command reference / sys

NETSTAT

Work with TCP/IP Network Sts

Gets status information about TCP/IP network routes, interfaces, TCP connections, and UDP ports on the local system. It can also end TCP/IP connections and start or end TCP/IP interfaces. If IP over SNA is enabled, it also shows and can control IP over SNA interfaces, routes, and connections. The QSYS2.NETSTAT_INFO, QSYS2.NETSTAT_INTERFACE_INFO, QSYS2.NETSTAT_JOB_INFO, and QSYS2.NETSTAT_ROUTE_INFO views return status information.

Allowed environments: *INTERACT, *IPGM, *IREXX, *EXEC. Positional parameters: 1.

Parameters

OPTION Option

Specifies which TCP/IP status information you want to work with.

Type
*CHAR
Required
No
Default
*SELECT
Length
7
Case
Uppercase

Allowed values: *SELECT, *IFC, *RTE, *CNN, *IFC6, *RTE6, *CNN6, *STATUS

*SELECT
Displays the Work with TCP/IP Network Status menu.
*IFC
Displays the Work with IPv4 Interface Status list.
*RTE
Displays the Display IPv4 Route Information list.
*CNN
Displays the Work with IPv4 Connection Status list.
*IFC6
Displays the Work with IPv6 Interface Status list.
*RTE6
Displays the Display IPv6 Route Information list.
*CNN6
Displays the Work with IPv6 Connection Status list.
*STATUS
Displays the Display TCP/IP Stack Status information.

Examples

NETSTAT OPTION(*IFC)

Displays the Work with IPv4 Interface Status panel.

NETSTAT *STATUS

OPTION is positional, so the keyword can be omitted; this starts NETSTAT and shows the Display TCP/IP Stack Status panel.

IBM command documentation

Generated from os/cl/catalog/NETSTAT.json and os/cl/help/NETSTAT.json.