当前位置:   article > 正文

yum install net-tools安装报错could not resolve host: mirrorlist.centos.org

yum install net-tools
  1. Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was
  2. 14: curl#6 - "Could not resolve host: mirrorlist.centos.org; Unknown error"
  3. One of the configured repositories failed (Unknown),
  4. and yum doesn't have enough cached data to continue. At this point the only
  5. safe thing yum can do is fail. There are a few ways to work "fix" this:
  6. 1. Contact the upstream for the repository and get them to fix the problem.
  7. 2. Reconfigure the baseurl/etc. for the repository, to point to a working
  8. upstream. This is most often useful if you are using a newer
  9. distribution release than is supported by the repository (and the
  10. packages for the previous distribution release still work).
  11. 3. Disable the repository, so yum won't use it by default. Yum will then
  12. just ignore the repository until you permanently enable it again or use
  13. --enablerepo for temporary usage:
  14. yum-config-manager --disable <repoid>
  15. 4. Configure the failing repository to be skipped, if it is unavailable.
  16. Note that yum will try to contact the repo. when it runs most commands,
  17. so will have to try and fail each time (and thus. yum will be be much
  18. slower). If it is a very temporary problem though, this is often a nice
  19. compromise:
  20. yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true
  21. Cannot find a valid baseurl for repo: base/7/x86_64

报错原因:没有配置网卡。


解决方法:

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Cpp五条/article/detail/552367
推荐阅读
相关标签