Background
If you run into a situation where you want to use netstat
on CentOS or Redhat but you encouter:
-bash: netstat: command not found
the following will help you obtain the correct library to install netstat
:
On CentOS 7
yum whatprovides */netstat
On CentOS 8
dnf whatprovides */netstat
Reference
Linux Troubleshooting – netstat command not found in CentOS 7/8 And RHEL 7/8