Whenever you cannot find executables on a Red Hat based distro and you know their names, you should do 1 of the following 2 things.
You can search the YUM repositories that are available to your system by using the command
repoquery. If it isn't installed, then do a
yum install yum-utils.
$ repoquery -qf */nmap
From here you can see which packages have an executable with those names. Here's all of them at once.
$ repoquery -qf */netstat */lsof */nmap
Now just do a
sudo yum install lsof or
sudo yum install nmap to install these missing packages.
Use yum search
You can also do a similar search using
yum search <executable>.
$ yum search netstat
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.advancedhosters.com
* extras: mirror.cisp.com
* updates: centos-mirror.jchost.net
================================================================== Matched: netstat ==================================================================
dstat.noarch : Versatile resource statistics tool
net-snmp.x86_64 : A collection of SNMP protocol tools and libraries
net-tools.x86_64 : Basic networking tools
With this approach you'll need to do a bit of digging to confirm that the resulting packages include the executable you're looking for. I typically look in there lit of files for what I want, but for that you'll have to use
$ repoquery -ql net-tools.x86_64 | grep netstat
So using my first approach saves you the extra steps.
Apparently in CentOS 7
netstat, which is part of the package
net-tools has been officially deprecated, so you should be using
ss (part of the package iproute2), going forward.