From a11807bcb9ce2368dc4f4119fa8849584308f011 Mon Sep 17 00:00:00 2001 From: ivuorinen Date: Fri, 17 May 2024 00:14:11 +0000 Subject: [PATCH] Update cheatsheets --- tldr/osx/netstat | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 tldr/osx/netstat diff --git a/tldr/osx/netstat b/tldr/osx/netstat new file mode 100644 index 00000000..07d71f32 --- /dev/null +++ b/tldr/osx/netstat @@ -0,0 +1,21 @@ +--- +syntax: markdown +tags: [tldr, osx] +source: https://github.com/tldr-pages/tldr.git +--- +# netstat + +> Display network-related information such as open connections, open socket ports, etc. +> More information: . + +- Display the PID and program name listening on a specific protocol: + +`netstat -p {{protocol}}` + +- Print the routing table and do not resolve IP addresses to hostnames: + +`netstat -nr` + +- Print the routing table of IPv4 addresses: + +`netstat -nr -f inet`