当前位置: 代码迷 >> 综合 >> 使用yum安装wget时报出:Loaded plugins: fastestmirror No such command: instal. Please use /usr/bin/yum --help
  详细解决方案

使用yum安装wget时报出:Loaded plugins: fastestmirror No such command: instal. Please use /usr/bin/yum --help

热度:116   发布时间:2023-10-25 19:14:23.0

Centos7 使用yum安装wget时报出以下错误:

[root@192-168-0-1 network-scripts]# yum -y instal wget
Loaded plugins: fastestmirror
No such command: instal. Please use /usr/bin/yum --help

解决办法:
在终端运行:

curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

再次运行:yum -y instal wget

[root@192-168-0-1 network-scripts]# yum -y install wget
Loaded plugins: fastestmirror
Determining fastest mirrors* base: mirrors.aliyun.com* extras: mirrors.aliyun.com* updates: mirrors.aliyun.com
base                                                                                                                                                | 3.6 kB  00:00:00     
extras                                                                                                                                              | 2.9 kB  00:00:00     
updates                                                                                                                                             | 2.9 kB  00:00:00     
(1/4): base/7/x86_64/group_gz                                                                                                                       | 165 kB  00:00:00     
(2/4): extras/7/x86_64/primary_db                                                                                                                   | 153 kB  00:00:00     
(3/4): updates/7/x86_64/primary_db                                                                                                                  | 5.8 MB  00:00:01     
base/7/x86_64/primary_db       FAILED                                          
http://mirrors.aliyuncs.com/centos/7/os/x86_64/repodata/04efe80d41ea3d94d36294f7107709d1c8f70db11e152d6ef562da344748581a-primary.sqlite.bz2: [Errno 12] Timeout on http://mirrors.aliyuncs.com/centos/7/os/x86_64/repodata/04efe80d41ea3d94d36294f7107709d1c8f70db11e152d6ef562da344748581a-primary.sqlite.bz2: (28, 'Connection timed out after 30000 milliseconds')
Trying other mirror.
(4/4): base/7/x86_64/primary_db                                                                                                                     | 6.0 MB  00:00:00     
Resolving Dependencies
--> Running transaction check
---> Package wget.x86_64 0:1.14-18.el7_6.1 will be installed
--> Finished Dependency ResolutionDependencies Resolved===========================================================================================================================================================================Package                              Arch                                   Version                                            Repository                            Size
===========================================================================================================================================================================
Installing:wget                                 x86_64                                 1.14-18.el7_6.1                                    base                                 547 kTransaction Summary
===========================================================================================================================================================================
Install  1 PackageTotal download size: 547 k
Installed size: 2.0 M
Downloading packages:
wget-1.14-18.el7_6.1.x86_64.rpm                                                                                                                     | 547 kB  00:00:00     
Running transaction check
Running transaction test
Transaction test succeeded
Running transactionInstalling : wget-1.14-18.el7_6.1.x86_64                                                                                                                             1/1 Verifying  : wget-1.14-18.el7_6.1.x86_64                                                                                                                             1/1 Installed:wget.x86_64 0:1.14-18.el7_6.1                                                                                                                                            Complete!

执行成功!

  相关解决方案