当前位置:网站首页 / Linux / 正文

-bash: xx: command not found在有yum源情况下处理方法

时间:2020年04月07日 | 作者 : liuhui | 分类 : Linux | 浏览: 4011次 | 评论 0

阿里云限量代金券 | 此广告位出租25元/月

如果我们在centos里输入nmap命令时遇到-bash: nmap: command not found这样的错误时,在有yum源的情况下应该这样处理:

yum provides "nmap"

或者用yum provides "*bin/nmap"

使用后会出现如下信息

Loaded plugins: fastestmirror
Repodata is over 2 weeks old. Install yum-cron? Or run: yum makecache fast
Determining fastest mirrors
 * base: mirror.genesishosting.com
 * epel: mirror.prgmr.com
 * extras: sjc.edge.kernel.org
 * updates: mirrors.usc.edu
2:nmap-6.40-19.el7.x86_64 : Network exploration tool and security
                          : scanner
Repo        : base

根据上面查询出来的信息,我们使用yum命令安装nmap

yum -y install nmap-6.40-19.el7.x86_64


如果我们遇到类似找不到命令的错误时,也可以采用同样方法,前提时yum源里有这个工具。

推荐您阅读更多有关于“”的文章

猜你喜欢

网站分类
关注电脑博士
友情链接

分享:

支付宝

微信