阿里云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
