zoukankan      html  css  js  c++  java
  • 2、修改国内yum源1

    1、清华源

    [base]
    name=CentOS-$releasever - Base
    baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/os/$basearch/
    #mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
    
    #released updates
    [updates]
    name=CentOS-$releasever - Updates
    baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/updates/$basearch/
    #mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
    
    #additional packages that may be useful
    [extras]
    name=CentOS-$releasever - Extras
    baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/extras/$basearch/
    #mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
    
    #additional packages that extend functionality of existing packages
    [centosplus]
    name=CentOS-$releasever - Plus
    baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/centosplus/$basearch/
    #mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus
    gpgcheck=1
    enabled=0
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

     2、将上面的配置替换替换到下面配置中

    vi /etc/yum.repo.d/Centos-Base.repo

    3、生效

    yum clean all
    yum makecache
  • 相关阅读:
    解释DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci
    MySQL性能优化
    MySQL中的binlog相关命令和恢复技巧
    保障MySQL安全的14个最佳方法
    MySQL忘记root密码的解决方案
    MySQL利用binlog来恢复数据库
    MySQL命令mysqldump参数大全
    MySQL REPLACE替换输出
    MySQL -A不预读数据库信息(use dbname 更快)
    MySQL 慢查询配置
  • 原文地址:https://www.cnblogs.com/whxiao/p/13236000.html
Copyright © 2011-2022 走看看