修改yum源为国内源,CentOS配置本地yum源

日期:2019-11-07编辑作者:服务器

CentOS配置本地yum源/Ali云yum源/163yuan源,并配置yum源的优先级,centos163yuan

1.概述

      YUM(全名为 Yellow dog Updater, Modified卡塔 尔(英语:State of Qatar)是三个在Fedora和RedHat以致CentOS中的Shell前端软件包微电脑。基于RPM包管理,能够从钦赐的服务器自动下载RPM包何况安装,能够自动处理看重性关系,而且一遍安装具有信任的软件包,无须繁杂地一次次下载、安装。

CentOS 校订yum源为国内源

风姿罗曼蒂克、用Centos镜像搭建本地yum源

由于设置centos后的暗许yum源为centos的官方地址,所以在国内应用相当的慢以致不能够访谈,所以经常的做法都以把暗许的yum源替换到aliyun的yum源恐怕163等国内的yum源(下文介绍怎么样安顿)。
唯独上述的不二等秘书诀都以索要网络的,当没有互联网的时候就无法接纳了,所以还会有三个常用的办法就是用Centos的iso镜像搭建本地yum源,那样设置软件的速度就能火速,劣势是唯恐某个包未有。

2.常用相关命令

  1 安装
    yum install 全体安装
    yum install package1 安装钦定的装置包package1
    yum groupinsall group1 安装程序组group1
    yum install yum-fastestmirror 自动搜索最快镜像插件
    yum install yumex 安装yum图形窗口插件
    yum grouplist

  2 改革和进级换代
    yum update 全体更新
    yum update package1 更新钦定程序包package1
    yum check-update 检查可更新的次序
    yum upgrade package1 升级钦点程序包package1
    yum groupupdate group1 升级程序组group1

  3 查找和展现
    yum info package1 显示安装包音信package1
    yum list 呈现全数曾经设置和能够安装的前后相继包
    yum list package1 显示钦点程序包安装景况package1
    yum groupinfo group1 显示程序组group1音信yum search string 依据主要字string查找安装包
    yum grouplist 查看可能批量装置的列表

  4 删除程序
    yum remove &$124; erase package1 删除程序包package1
    yum groupremove group1 删除程序组group1
    yum deplist package1 查看程序package1信赖意况

  5 消亡缓存
    yum clean packages 撤销缓存目录下的软件包
    yum clean headers 消灭缓存目录下的 headers
    yum clean oldheaders 消除缓存目录下旧的 headers
    yum clean, yum clean all (= yum clean packages; yum clean oldheaders) 解除缓存目录下的软件包及旧的headers
    yum clean all

CentOS 改革yum源为本国源

改善yum源的章程有三种,超级多相恋的人喜欢改过yum.repos.d这一个文件进行改换,deepvps认为这些法子不是太好,以下这一个办法就有助于多了。

在CentOS系统中,能够一贯通过yum来安装组件,但系统默许的yum源速度往往不尽人意,都接连国外的,为了在境内高达迅速安装的目标,将在须求修改yum源,能够应用

那2个国内源。

推行以下命令就足以了

cd /etc/yum.repos.d
mv CentOS-Base.repo CentOS-Base.repo.bak
wget


wget

运维yum makecache生成缓存

搞定。

1.设置Centos后暗许的yum源如下

[[email protected] ~]# ll /etc/yum.repos.d/
total 32
-rw-r--r--. 1 root root 1664 Dec  9  2015 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Dec  9  2015 CentOS-CR.repo
-rw-r--r--. 1 root root  649 Dec  9  2015 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 Dec  9  2015 CentOS-fasttrack.repo
-rw-r--r--. 1 root root  630 Dec  9  2015 CentOS-Media.repo
-rw-r--r--. 1 root root 1331 Dec  9  2015 CentOS-Sources.repo
-rw-r--r--. 1 root root 1952 Dec  9  2015 CentOS-Vault.repo

3.基于Centos镜像搭建本地yum仓库(仅本地利用)

1)将CentOS-6.8-x86_64-bin-DVD1.iso镜像挂载到/mnt/cdrom目录
    [root@hadoop102 /]# mkdir /mnt/cdrom
    [root@hadoop102 /]# mount -t iso9660 /dev/cdrom /mnt/cdrom

2)改正本机上的YUM源配置文件,将源指向和煦
    [root@hadoop102 /]# cd /etc/yum.repos.d/
    [root@hadoop102 yum.repos.d]# cp CentOS-Base.repo CentOS-Base.repo.bak
    [root@hadoop102 yum.repos.d]# vi CentOS-Base.repo

[base]
name=CentOS-Local
baseurl=file:///mnt/cdrom  # 指向本地挂载的 rpm库
gpgcheck=1
enabled=1   #增加改行,使能
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6

3)清除YUM缓冲
    [root@hadoop102 yum.repos.d]# yum clean all

4)列出可用的YUM源
    [root@hadoop102 yum.repos.d]# yum repolist

5)安装相应的软件实行测验
    [澳门金莎娱乐网站,root@hadoop102 yum.repos.d]# rpm -qa |grep createrepo
    [root@hadoop102 yum.repos.d]# yum install -y firefox

改过centos yum 成人中学华镜像加快yum速度

163的开源镜像地址
不等版本见

sohu的开源镜像地址
不等版本见

中国医科大学
昔不近期版本见)

假如运用上边YUM源的话,最佳把当中的mirrorlist注释掉,不然系统会运转fastesmirror插件自动物检疫查的,并不一定会接纳这一个yum源的.

小编用的是中国防戏剧大学的速度不错。

法大器晚成:直接下载源文件

CentOS USTC mirror 这些镜像不错,我们更新可用那些

#yum -y install wget
#cd /etc/yum.repos.d
#mv CentOS-Base.repo CentOS-Base.repo.save
#wget

专一:假若为第一遍安装的新系统的话,则须要先安装wget那几个下载软件,不然未有主意下载CentOS-Base.repo那些文件的。

法二:手动创制源文件

修正yum镜像站点为中中原人民共和国站点地址,推荐)

#cd /etc/yum.repos.d/

#mv CentOS-Base.repo CentOS-Base.repo.bak

#vi CentOS-Base.repo

修改/etc/yum.repos.d/CentOS-Base.repo如下:

2.把默认yum源备份(可选)

[root@kangvcar ~]# mkdir /opt/centos-yum.bak
[root@kangvcar ~]# mv /etc/yum.repos.d/* /opt/centos-yum.bak/

4.基于Centos镜像+Apache搭建公共yum仓库(外网可访谈)

1)安装相应的软件
    [root@hadoop102 yum.repos.d]#yum install -y httpd

2)开启httpd使用浏览器访谈http://hadoop102:80
(借使访谈不通,检查防火墙是还是不是张开了80端口或关闭防火墙卡塔尔国
    [root@hadoop102 yum.repos.d]#service httpd start

3)将YUM源配置到httpd(Apache Server卡塔 尔(英语:State of Qatar)中,内网别的节点可访问
    [root@hadoop102 html]# mkdir Packages
    [root@hadoop102 html]# chown admin:admin Packages/
    [root@hadoop102 html]# cp -r /mnt/cdrom/Packages/* /var/www/html/Packages/

4)撤销早前挂载的镜像
[root@hadoop102 yum.repos.d]#umount /mnt/cdrom

5)在浏览器中拜候http://hadoop102/Packages/ (暗中认可访问80端口卡塔尔

澳门金莎娱乐网站 1

图片.png

6)实践创设饭馆命令:createrepo 路线
    [root@hadoop102 Packages]# createrepo ./

7)让任何急需安装RPM包的服务器指向这一个YUM源
    [root@hadoop103 /]# cd /etc/yum.repos.d/
    [root@hadoop103 yum.repos.d]# cp CentOS-Base.repo CentOS-Base.repo.bak
    [root@hadoop103 yum.repos.d]# vim CentOS-Base.repo

[base]
name=CentOS-hadoop102
baseurl=http://hadoop102/Packages
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6

8)在这里台新的服务器上推行YUM的吩咐
    [root@hadoop103 yum.repos.d]# yum clean all
    [root@hadoop103 yum.repos.d]# yum repolist

9)测验内网中hadoop103 访谈hadoop102提供的yum仓库,安装使用
    [root@hadoop103 yum.repos.d]# yum install -y createrepo

Centos镜像使用支持

3.在设想机上挂载CentOS镜像文件

[root@kangvcar ~]# mount -t iso9660 /dev/sr0 /opt/centos
mount: /dev/sr0 is write-protected, mounting read-only

5.优化yum源,配置本国镜像

1)备份原有数据源配置
    mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

2)启用本国镜像(二选生机勃勃)
    curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.163.com/.help/CentOS6-Base-163.repo

    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.163.com/.help/CentOS6-Base-163.repo
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
[Centos5.x 7.x]
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

3卡塔 尔(阿拉伯语:قطر‎安装命令
    yum clean all
    yum makecache

4)测验通过yum命令使用本国镜像安装使用
    yum install mysql

录取架构

  • i386
  • x86_64

4.编写repo文件并指向镜像的挂载目录

[[email protected] ~]# vi /etc/yum.repos.d/local.repo  
[local]
name=local
baseurl=file:///opt/centos
enabled=1
gpgcheck=0

任用版本

  • 5
  • 6

5.肃清缓存

[root@kangvcar ~]# yum clean all
Loaded plugins: fastestmirror
Cleaning repos: local
Cleaning up everything
Cleaning up list of fastest mirrors
[root@kangvcar ~]# yum makecache        //把yum源缓存到本地,加快软件的搜索好安装速度
[root@kangvcar ~]# yum list        //列出了3780个包

利用验证

率先备份CentOS-Base.repo

mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

下载对应版本的CentOS-Base.repo, 放入/etc/yum.repos.d/

这是CentOS 5的:

CentOS-Base.repo

# CentOS-Base.repo## The mirror system uses the connecting IP address of the client and the# update status of each mirror to pick mirrors that are updated to and# geographically close to the client.  You should use this for CentOS updates# unless you are manually picking other mirrors.## If the mirrorlist= does not work for you, as a fall back you can try the # remarked out baseurl= line instead.##[base]name=CentOS-$releasever - Base - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/os/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=osgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5#released updates [updates]name=CentOS-$releasever - Updates - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/updates/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updatesgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5#additional packages that may be useful[extras]name=CentOS-$releasever - Extras - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/extras/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extrasgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5#packages used/produced in the build but not released[addons]name=CentOS-$releasever - Addons - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/addons/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addonsgpgcheck=1gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5#additional packages that extend functionality of existing packages[centosplus]name=CentOS-$releasever - Plus - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/centosplus/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplusgpgcheck=1enabled=0gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5#contrib - packages by Centos Users[contrib]name=CentOS-$releasever - Contrib - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/contrib/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contribgpgcheck=1enabled=0gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5

这是CentOS 6的:

CentOS-Base.repo

# CentOS-Base.repo## The mirror system uses the connecting IP address of the client and the# update status of each mirror to pick mirrors that are updated to and# geographically close to the client.  You should use this for CentOS updates# unless you are manually picking other mirrors.## If the mirrorlist= does not work for you, as a fall back you can try the # remarked out baseurl= line instead.##[base]name=CentOS-$releasever - Base - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/os/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=osgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-6#released updates [updates]name=CentOS-$releasever - Updates - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/updates/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updatesgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-6#additional packages that may be useful[extras]name=CentOS-$releasever - Extras - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/extras/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extrasgpgcheck=1gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-6#additional packages that extend functionality of existing packages[centosplus]name=CentOS-$releasever - Plus - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/centosplus/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplusgpgcheck=1enabled=0gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-6#contrib - packages by Centos Users[contrib]name=CentOS-$releasever - Contrib - mirrors.ustc.edu.cnbaseurl=http://mirrors.ustc.edu.cn/centos/$releasever/contrib/$basearch/#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contribgpgcheck=1enabled=0gpgkey=http://mirrors.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-6

运营yum makecache生成缓存

改正yum源为国内源 CentOS 改正yum源为国内源 修改yum源的秘籍有两种,非常多相爱的人赏识改善yum.repos.d这么些文件举行转移,deepvps以为那些方法...

二、把暗中认可的CentOS yum源改进成国内的aliyun yum源

Ali云官方教程:

1.设置Centos后暗中同意的yum源如下

[[email protected] ~]# ll /etc/yum.repos.d/
total 32
-rw-r--r--. 1 root root 1664 Dec  9  2015 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Dec  9  2015 CentOS-CR.repo
-rw-r--r--. 1 root root  649 Dec  9  2015 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 Dec  9  2015 CentOS-fasttrack.repo
-rw-r--r--. 1 root root  630 Dec  9  2015 CentOS-Media.repo
-rw-r--r--. 1 root root 1331 Dec  9  2015 CentOS-Sources.repo
-rw-r--r--. 1 root root 1952 Dec  9  2015 CentOS-Vault.repo

2.把默认yum源备份(可选)

[root@kangvcar ~]# mkdir /opt/centos-yum.bak
[root@kangvcar ~]# mv /etc/yum.repos.d/* /opt/centos-yum.bak/

3.下载aliyun yum源repo文件(对应自身的种类版本下载就可以)

#各系统版本repo文件对应的下载操作
CentOS 5
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
CentOS 6
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
CentOS 7
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

[[email protected] ~]# cat /etc/redhat-release        //查看系统的版本
CentOS Linux release 7.2.1511 (Core)
[[email protected] ~]# wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
--2017-06-20 06:43:08--  http://mirrors.aliyun.com/repo/Centos-7.repo
Resolving mirrors.aliyun.com (mirrors.aliyun.com)... 112.124.140.210, 115.28.122.210
Connecting to mirrors.aliyun.com (mirrors.aliyun.com)|112.124.140.210|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2573 (2.5K) [application/octet-stream]
Saving to: ‘/etc/yum.repos.d/CentOS-Base.repo’
100%[=======================================================================================================>] 2,573       --.-K/s   in 0s      
2017-06-20 06:43:08 (118 MB/s) - ‘/etc/yum.repos.d/CentOS-Base.repo’ saved [2573/2573]

4.消逝缓存

[root@kangvcar ~]# yum clean all
Loaded plugins: fastestmirror
Cleaning repos: base extras updates
Cleaning up everything
Cleaning up list of fastest mirrors
[root@kangvcar ~]# yum makecache        //把yum源缓存到本地,加快软件的搜索好安装速度
[root@kangvcar ~]# yum list        //总共列出了9954个包

三、把暗中认可的CentOS yum源修正成我国的163源

163官方教程:

1.安装Centos后私下认可的yum源如下

[[email protected] ~]# ll /etc/yum.repos.d/
total 32
-rw-r--r--. 1 root root 1664 Dec  9  2015 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Dec  9  2015 CentOS-CR.repo
-rw-r--r--. 1 root root  649 Dec  9  2015 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 Dec  9  2015 CentOS-fasttrack.repo
-rw-r--r--. 1 root root  630 Dec  9  2015 CentOS-Media.repo
-rw-r--r--. 1 root root 1331 Dec  9  2015 CentOS-Sources.repo
-rw-r--r--. 1 root root 1952 Dec  9  2015 CentOS-Vault.repo

2.把默认yum源备份(可选)

[root@kangvcar ~]# mkdir /opt/centos-yum.bak
[root@kangvcar ~]# mv /etc/yum.repos.d/* /opt/centos-yum.bak/

3.下载163 yum源repo文件

#各系统版本repo文件对应的下载操作
CentOS 5
wget -O /etc/yum.repos.d/CentOS5-Base-163.repo http://mirrors.163.com/.help/CentOS5-Base-163.repo
CentOS 6
wget -O /etc/yum.repos.d/CentOS6-Base-163.repo http://mirrors.163.com/.help/CentOS6-Base-163.repo
CentOS 7
wget -O /etc/yum.repos.d/CentOS7-Base-163.repo http://mirrors.163.com/.help/CentOS7-Base-163.repo

[[email protected] ~]# cat /etc/redhat-release        //查看系统的版本
CentOS Linux release 7.2.1511 (Core)
[[email protected] ~]# wget -O /etc/yum.repos.d/CentOS7-Base-163.repo http://mirrors.163.com/.help/CentOS7-Base-163.repo
--2017-06-20 06:29:47--  http://mirrors.163.com/.help/CentOS7-Base-163.repo
Resolving mirrors.163.com (mirrors.163.com)... 123.58.173.185, 123.58.173.186
Connecting to mirrors.163.com (mirrors.163.com)|123.58.173.185|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1572 (1.5K) [application/octet-stream]
Saving to: ‘/etc/yum.repos.d/CentOS7-Base-163.repo’
100%[=======================================================================================================>] 1,572       --.-K/s   in 0s      
2017-06-20 06:29:47 (293 MB/s) - ‘/etc/yum.repos.d/CentOS7-Base-163.repo’ saved [1572/1572]

4.免除缓存

[root@kangvcar ~]# yum clean all
Loaded plugins: fastestmirror
Cleaning repos: base extras updates
Cleaning up everything
Cleaning up list of fastest mirrors
[root@kangvcar ~]# yum makecache        //把yum源缓存到本地,加快软件的搜索好安装速度
[root@kangvcar ~]# yum list        //总共列出了9951个包

四、矫正yum源的优先级

ps:当既有地方yum源又有163源的时候,大家在装软件包的时候自然愿意先用本地的yum源去安装,本地找不到可用的包时再利用163源去安装软件,这里就关乎到了优先级的主题素材,yum提供的插件yum-plugin-priorities.noarch能够解决这一个难点

1.翻看系统是不是安装了刚开始阶段级的插件

[[email protected] ~]# rpm -qa | grep yum-plugin-
yum-plugin-fastestmirror-1.1.31-34.el7.noarch        
//这里看到没有安装yum-plugin-priorities.noarch这个插件
[[email protected] ~]# yum search yum-plugin-priorities        
//用search查看是否有此插件可用
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.aliyun.com
* extras: mirrors.aliyun.com
* updates: mirrors.aliyun.com
====================================================== N/S matched: yum-plugin-priorities =======================================================
yum-plugin-priorities.noarch : plugin to give priorities to packages from different repos

2.安装yum-plugin-priorities.noarch插件

[root@kangvcar ~]# yum -y install yum-plugin-priorities.noarch

3.查看插件是不是启用

[[email protected] ~]# cat /etc/yum/pluginconf.d/priorities.conf
[main]
enabled = 1
//1为启用;0为禁用

4.退换本地yum源优先选用

[[email protected] ~]# ll /etc/yum.repos.d/
total 8
-rw-r--r--. 1 root root 2573 May 15  2015 CentOS-Base.repo
-rw-r--r--. 1 root root   67 Jun 20 06:04 local.repo
//有两个repo文件
[[email protected] ~]# vi /etc/yum.repos.d/local.repo
[local]
name=local
baseurl=file:///opt/centos
enabled=1
gpgcheck=0
priority=1
//在原基础上加入priority=1 ;数字越小优先级越高
//可以继续修改其他源的priority值,经测试仅配置本地源的优先级为priority=1就会优先使用本地源了

5.测试

配置优先级前:(使用阿里云yum源)
[[email protected] ~]# yum -y install vim
Dependencies Resolved
=================================================================================================================================================
Package                            Arch                         Version                                     Repository                     Size
=================================================================================================================================================
Installing:
vim-enhanced                       x86_64                       2:7.4.160-1.el7_3.1                         updates                       1.0 M
Updating for dependencies:
vim-common                         x86_64                       2:7.4.160-1.el7_3.1                         updates                       5.9 M
省略···

配置优先级后:(使用本地yum源)
[[email protected] ~]# yum -y install vim
Dependencies Resolved
=================================================================================================================================================
Package                                     Arch                        Version                                Repository                  Size
=================================================================================================================================================
Installing:
vim-enhanced                                x86_64                      2:7.4.160-1.el7                        local                      1.0 M
Installing for dependencies:
gpm-libs                                    x86_64                      1.20.7-5.el7                           local                       32 k
perl                                        x86_64                      4:5.16.3-286.el7                       local                      8.0 M
perl-Carp                                   noarch                      1.26-244.el7                           local                       19 k
perl-Encode                                 x86_64                      2.51-7.el7                             local                      1.5 M
perl-Exporter                               noarch                      5.68-3.el7                             local                       28 k
perl-File-Path                              noarch                      2.09-2.el7                             local                       26 k
perl-File-Temp                              noarch                      0.23.01-3.el7                          local                       56 k
省略···

本文由澳门金莎娱乐网站发布于服务器,转载请注明出处:修改yum源为国内源,CentOS配置本地yum源

关键词:

Nextcloud搭建过程,Centos7的apache网站环境搭建wor

网盘不可信赖 那就自个儿搭建256TB的网盘呗 — Nextcloud搭建进度,256tbnextcloud 二零一四年网盘的日子倒霉过啊 一家家...

详细>>

shell变量总结回顾澳门金莎娱乐网站:,Linux正则

shell脚本(风华正茂卡塔 尔(阿拉伯语:قطر‎功底知识,shell脚本根基知识 shell 一、简介 1.成效:与基本进行交互...

详细>>

CentOS7网络配置澳门金莎娱乐网站,解决win下无法

查看 ifcfg-eno16777736 网卡配置文件(centos7改动了很多!!!跟书本教材的老版本有很多不一样的) 解决win下无法ping通V...

详细>>

应用发布前保障性能的十八种方式,SaaS云运维高

应用发布前保障性能的十八种方式(一) 被文艺青年奉为“爱情圣经”的《爱在三部曲》第一部为我们描述了这样一个...

详细>>