#yyds干货盘点#解决 bash: telnet: command not found 问题
Posted liuzhen007
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了#yyds干货盘点#解决 bash: telnet: command not found 问题相关的知识,希望对你有一定的参考价值。
目录
问题
解决
问题
执行命令 telnet 命令时,遇到了如下提示信息:
-bash: telnet: command not found
确切的说,这不能算是报错。上网查了一下解决方法,都太麻烦了。于是,自己把解决方法记录一下,方便下次查阅。
解决
执行安装命令:
yum install telnet.x86_64
结果又遇到如下报错:
Loaded plugins: fastestmirror
You need to be root to perform this command.
原来是需要切换到 root 用户,切换后再执行上述命令,搞定。
输出如下信息表示安装成功:
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
baijiayun | 2.9 kB 00:00:00
base | 3.6 kB 00:00:00
docker-ce-stable | 3.5 kB 00:00:00
epel | 4.7 kB 00:00:00
extras | 2.9 kB 00:00:00
updates | 2.9 kB 00:00:00
Resolving Dependencies
--> Running transaction check
---> Package telnet.x86_64 1:0.17-66.el7 will be installed
--> Finished Dependency ResolutionDependencies Resolved
==================================================================================================================================================================================
Package Arch Version Repository Size
==================================================================================================================================================================================
Installing:
telnet x86_64 1:0.17-66.el7 updates 64 kTransaction Summary
==================================================================================================================================================================================
Install 1 PackageTotal download size: 64 k
Installed size: 113 k
Is this ok [y/d/N]: y
Downloading packages:
telnet-0.17-66.el7.x86_64.rpm | 64 kB 00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : 1:telnet-0.17-66.el7.x86_64 1/1
Verifying : 1:telnet-0.17-66.el7.x86_64 1/1Installed:
telnet.x86_64 1:0.17-66.el7Complete!
接下来,测试一下 telnet 命令是否好用,执行如下命令:
telnet www.baidu.com 443
输出如下信息表示命令执行成功:
Trying 220.181.38.150...
Connected to www.baidu.com.
Escape character is ^].
好了,至此,telnet 工具就安装成功了,是不是非常 easy ?
作者简介:
以上是关于#yyds干货盘点#解决 bash: telnet: command not found 问题的主要内容,如果未能解决你的问题,请参考以下文章