zoukankan      html  css  js  c++  java
  • 常用的CentOS 7系统yum源集合

    常用的CentOS 7系统yum源集合

     
    yum源对于linux系统的安装有非常大的帮助了,下面小编为各位整理了常用的CentOS 7系统yum源集合了,希望这篇文章能够对各位有所帮助的哦。
     


    记录几个常用的CentOS 7下的yum源,包括PHP7,MariaDB,Redis,Nginx等,以及阿里云源,方便虚拟机或云主机上安装这些软件。

    1.PHP7 remi源

    使用remi源:

    $ sudo rpm --import http://rpms.famillecollet.com/RPM-GPG-KEY-remi
     
    $ sudo rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm

    2.MariaDB 10.1

    Here is your custom MariaDB YUM repository entry for CentOS. Copy and paste it into a file under /etc/yum.repos.d/ (we suggest naming the file MariaDB.repo or something similar).


    # MariaDB 10.1 CentOS repository list - created 2016-03-31 09:25 UTC
    # http://mariadb.org/mariadb/repositories/
    [mariadb]
    name = MariaDB
    baseurl = http://yum.mariadb.org/10.1/centos7-amd64
    gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
    gpgcheck=1

    执行安装命令:

    sudo yum install MariaDB-server MariaDB-client

    3.Redis


    wget http://download.redis.io/redis-stable.tar.gz
    tar xvzf redis-stable.tar.gz
    cd redis-stable
    make

    设置service方式启动,参见:quickstart和Redis生成环境自动启动

    4.Nginx 1.8

    To add NGINX yum repository, create a file named /etc/yum.repos.d/nginx.repo and paste one of the configurations below:

    CentOS:

    [nginx]
    name=nginx repo
    baseurl=http://nginx.org/packages/centos/$releasever/$basearch/
    gpgcheck=0
    enabled=1

    5.阿里云

    ① 备份


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

    ② 下载新的CentOS-Base.repo 到/etc/yum.repos.d/

    CentOS 7


    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

    ③ 之后运行yum makecache生成缓存

  • 相关阅读:
    window.location.href问题,点击,跳转到首页
    JS indexOf() lastIndexOf()与substring()截取字符串的区别
    原来的方法增加参数时,必须为新增的参数加个默认值
    Chrome不支持本地Ajax请求解决?
    Smarty中{literal}的使用详解
    windows不能在本地计算机启动apache
    Apache虚拟主机配置
    wamp环境网站根目录更改
    Java 读书笔记 (十三) for each 循环
    Java 读书笔记 (十二) Java Character 类
  • 原文地址:https://www.cnblogs.com/quxiuke/p/6135818.html
Copyright © 2011-2022 走看看