阿里云YUM源配置

阿里云YUM源配置yum 阿里源的配置及 rpm 检查相关包是否安装

阿里云YUM源配置

1.备份原有yum源

2.根据自己系统下载yum源

使用wget命令即可完成下载。
为Centos6下载:
wget -P /etc/yum.repo.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
为Centos7下载:
wget -P /etc/yum.repo.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo








3.重新加载yum

yum clean all yum makecache 

0x00.

repo文件是yum源的配置文件,repo定义了从何处下载及安装,定义了多个软件仓库的细节内容。

rpm常用命令

rpm -aq httpd* //查询所有关于httpd的安装包 rpm -aqi httpd* //查询所有httpd安装包的相关详细信息 rpm -qf `which httpd` //查询某文件的安装包 ------------------------------------------------------------------- [root@Anu /]# rpm -aq httpd* httpd-2.4.6-93.el7.centos.x86_64 httpd-tools-2.4.6-93.el7.centos.x86_64 ------------------------------------------------------------------ [root@Anu /]# rpm -aqi httpd* Name : httpd Version : 2.4.6 Release : 93.el7.centos Architecture: x86_64 Install Date: 2020年08月26日 星期三 09时44分21秒 Group : XXX Size :  License :XXX Signature : XXXX Source RPM : httpd-2.4.6-93.el7.centos.src.rpm Build Date : XXXX Build Host : x86-01.bsys.centos.org Relocations : (not relocatable) Packager : CentOS BuildSystem 
  
    Vendor : CentOS URL : http://httpd.apache.org/ Summary : Apache HTTP Server Description : The Apache HTTP Server is a powerful, efficient, and extensible web server. ------------------------------------------------------------------ Name : httpd-tools Version : 2.4.6 Release : 93.el7.centos Architecture: x86_64 Install Date: XXXX Group :XXXXXX Size : License : ASL 2.0 Signature : XXXXXX Source RPM : httpd-2.4.6-93.el7.centos.src.rpm Build Date : XXXXXXXX Build Host : x86-01.bsys.centos.org Relocations : (not relocatable) Packager : CentOS BuildSystem 
   
     Vendor : CentOS URL : http://httpd.apache.org/ Summary : Tools for use with the Apache HTTP Server Description : The httpd-tools package contains tools which can be used with the Apache HTTP Server. [root@Anu /]# rpm -qf `which httpd` httpd-2.4.6-93.el7.centos.x86_64 
    
  

期间发现网络总是不通
解决方法将网卡删掉:

//centos7 安装后发现会多出来一个IP地址,网卡是virbr0 1.关闭: ifconfig virbr0 down 2.删除: brctl delbr virbr0 3.删除服务,virbr0是由libvirtd服务创建: systemctl disable libvirtd 
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/205602.html原文链接:https://javaforall.net

(0)
上一篇 2026年3月19日 下午5:38
下一篇 2026年3月19日 下午5:38


相关推荐

  • 为低端浏览器定义原型方法replaceAll

    为低端浏览器定义原型方法replaceAllString.prototype.replaceAll=function(regex,replacement){regex=regex.replace(‘!’,’\\!’).replace(‘@’,’\\@’).replace(‘#’,’\\#’).replace(‘$’,’\\$’)returnthis.replace(newRegExp(regex,’gm’),replacement);};

    2022年7月23日
    19
  • flex垂直居中,水平居中和其他布局方式

    flex垂直居中,水平居中和其他布局方式flex水平垂直居中<divclass=”content”><divclass=”item”>1</div><divclass=”item”>2</div><divclass=”item”>3</div></div>.content{display:flex;align-items:center;justify-content:center;bord

    2022年6月11日
    33
  • 海量图片存储解决方案

    海量图片存储解决方案当今世界,互联网、大数据应用迅猛发展,物联网、人工智能、云计算技术日新月异,随之而来的是各种企业和个人应用持续不断地产生亿级甚至是百亿级的海量小文件。这些小文件的元数据管理、存储性能以及访问效率等问题因而成为学术界和工业界公认的难题。例如,国内目前最大的电商网站淘宝存储的商品图片超过200亿张,这些文件的平均大小仅为15KB左右,国外著名的社交网站Facebook存储的图片总量更是超…

    2022年7月12日
    23
  • murmurhash2算法python3版本

    murmurhash2算法python3版本在翻译加密代码时遇到这个murmurhash2算法了,网上找了几个现成的加密结果对不上,自己手动对照原加密翻译了一般python3版本的。#-*-coding:utf-8-*-#@Time:2021/8/2614:40#@Note:Pleasedonotusethisprogramforillegaluses.importctypesdefunsigned_right_shitf(num,bit):returnctypes.c

    2022年10月18日
    6
  • Zookeeper windows安装

    Zookeeper windows安装百度网盘链接提取码:yg12拷贝zoo.cfg更改日志输出路径新建文件夹启动成功

    2022年8月9日
    8
  • 详解Modbus通信协议—清晰易懂

    详解Modbus通信协议—清晰易懂什么是协议在了解什么是 Modbus 之前 我们先来看下什么是协议协议是一个汉语词汇 读音为 xi y 意思是共同计议 协商 经过谈判 协商而制定的共同承认 共同遵守的文件 简单地说 在我们的单片机之间互相通信 以及单片机和上位机通信中 规定了不同的内容规范 这个规范是通信的双方都需要遵守的 这样就可以实现两者的通信 而这个协议规范可以有很多种 来适应不同的设备以及通信要求等 我们常见的就有 IICSPIUART 串口通信协议等等 而 Modbus 也是一个串行通信协议 什么是 RS 485RS 2

    2026年3月20日
    1

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号