linux yum明明已经安装lzszz上传文件提示命令零错误

1
2
3
4
5
6
7
遇到错误如下:
Loaded plugins: fastestmirror, refresh-packagekit, security
Determining fastest mirrors
YumRepo Error: All mirror URLs are not using ftp, http[s] or file.
Eg. Invalid release/repo/arch combination/
removing mirrorlist with no valid mirrors: /var/cache/yum/x86_64/6/base/mirrorlist.txt
Error: Cannot find a valid baseurl for repo: base

这里是显示yum/x89_64/6的错误,具体咱也不明白,反正是就是系统yum有问题,你想用你就得修复

 

1
2
3
4
5
6
7
8
正确的做法就是把原来的备份一下,以备不测就行恢复
解决办法:更换yum源
mv /etc/yum.repos.d/* /tmp/
备份源文件
 
cd /etc/yum.repos.d/
 
这里查看下自己的系统是Centos哪个版本哈,好像Centos8不给玩了,自己捣鼓哈

 

1
2
3
4
5
6
7
8
9
10
11
到系统下:
cd /etc/yum.repos.d/
下载
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
把baseurl里面的 mirrors.aliyun.com  mirrors.aliyuncs.com   mirrors.cloud.aliyuncs.com  都给换成  vault.centos.org<br>把gpgkey 里面的 http://vault.centos.org/centos换成  换成https://vault.centos.org/6.5/os/x86_64/<br>
清除缓存重新安装
 
sudo yum clean all && yum makecache
释放yum的缓存
 
yum -y install lrzsz yum就可以使用了

 

posted @   余生请多指教ANT  阅读(20)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 全程不用写代码,我用AI程序员写了一个飞机大战
· DeepSeek 开源周回顾「GitHub 热点速览」
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 记一次.NET内存居高不下排查解决与启示
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
历史上的今天:
2022-05-08 spring-Security《二》
2021-05-08 mysql索引基本介绍
点击右上角即可分享
微信分享提示