Which command prints network connections, routing tables, and interface statistics?

Subh Singh
Invent the Future
The command is netstat, which is used to display network connections, routing tables, and interface statistics in Linux. It shows information about network activity on the computer.
Command:
netstat -a -r -i
Example:
If you want to check network connections, routing tables, and interface statistics in Linux, open the terminal and run the following command.
netstat -a -r -i
Output:
Active Internet connections
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
Kernel IP routing table
Destination Gateway Genmask Flags Iface
0.0.0.0 192.168.1.1 0.0.0.0 UG eth0
Kernel Interface table
Iface MTU RX-OK TX-OK
eth0 1500 1200 900
Here:
By using the netstat command, you can see network connections, routing tables, and interface statistics in the output.











