1、安装repo

rpm -Uvh  http://www.city-fan.org/ftp/contrib/yum-repo/rhel6/x86_64/city-fan.org-release-2-1.rhel6.noarch.rpm

2、查看该 repo 包含的 curl 版本

yum.repos.d]# yum --showduplicates list curl --disablerepo="*" --enablerepo="city*"

Loaded plugins: fastestmirror
city-fan.org | 3.0 kB 00:00:00
city-fan.org-debuginfo | 3.0 kB 00:00:00
city-fan.org-source | 3.0 kB 00:00:00
(1/3): city-fan.org-debuginfo/7/primary_db | 39 kB 00:00:02
(2/3): city-fan.org-source/7/primary_db | 344 kB 00:00:03
(3/3): city-fan.org/7/primary_db | 489 kB 00:00:03
Loading mirror speeds from cached hostfile
* city-fan.org: nervion.us.es
* city-fan.org-debuginfo: www.city-fan.org
* city-fan.org-source: nervion.us.es
Installed Packages
curl.x86_64 7.29.0-42.el7 @anaconda
Available Packages
curl.x86_64 7.62.0-1.0.cf.rhel7 city-fan.org

3、修改该repo的enable为1

vi /etc/yum.repos.d/city-fan.org.repo

[city-fan.org]

name=city-fan.org repository for Red Hat Enterprise Linux (and clones) $releasever ($basearch)

#baseurl=http://mirror.city-fan.org/ftp/contrib/yum-repo/rhel$releasever/$basearch

mirrorlist=http://mirror.city-fan.org/ftp/contrib/yum-repo/mirrorlist-rhel$releasever

enabled=1

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-city-fan.org

4、安装最新的curl

yum install curl

5、如果提示缺少依赖 libnghttp2.so.14()(64bit)

rpm -ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/Packages/l/libnghttp2-1.6.0-1.el6.1.x86_64.rpm

然后重复第4步即可

6、查看curl版本

curl -V

curl 7.61.1 (x86_64-redhat-linux-gnu) libcurl/7.61.1 OpenSSL/1.0.1e zlib/1.2.3 c-ares/1.14.0 libssh2/1.8.0 nghttp2/1.6.0

Release-Date: 2018-09-05

Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp scp sftp smb smbs smtp smtps telnet tftp 

Features: AsynchDNS IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz HTTP2 UnixSockets HTTPS-proxy Metalink 

【转】centos升级curl版本的更多相关文章

  1. centos 升级curl版本

    1.安装repo rpm -Uvh http://www.city-fan.org/ftp/contrib/yum-repo/rhel6/x86_64/city-fan.org-release-2-1 ...

  2. Centos 升级MySQL版本或者Yum安装Mysql5.6

    Centos 升级MySQL版本或者Yum安装Mysql5.6 1.从MySQL Yum仓库下载最新的rpm文件:http://dev.mysql.com/downloads/repo/yum/Cen ...

  3. liunx CentOS 升级Python版本

    CentOS python版本是V2.6.6,升级3.4.3. 1.下载 安装包:wget http://www.python.org/ftp/python/3.4.3/Python-3.4.3.tg ...

  4. Linux(CentOS)升级gcc版本

    本人使用的是CentOS 6.2 64位系统,由于在安装系统的时候并没有勾选安装gcc编译器,因此需要自行安装gcc编译器. 系统信息查看命令: cat /etc/redhat-release 使用y ...

  5. CentOS升级polkit版本,解决 Linux Polkit 存在权限提升的漏洞 (CVE-2021-4034)

    漏洞描述 受影响版本的 pkexec 无法正确处理调用参数计数,最终尝试将环境变量作为命令执行,攻击者可以通过修改环境变量来利用此漏洞,诱使 pkexec 执行任意代码,从而导致将本地权限提升为 ro ...

  6. centos升级openssh版本

    似乎升级就是简单的安装ssh包就行了,没进行其他修改,虚拟机24个中高低漏洞解决 安装最新包: 1.下载:https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/por ...

  7. Centos7升级Git版本

    centos 升级 Git 版本 问题描述 centos7 系统默认的 git 安装版本是 1.8,但是在项目构建中发现 git 版本过低,于是用源码编译的方式进行升级.同时该文章也适用于安装新的 g ...

  8. CentOS 7.4升级curl和git到最新版本

    升级curl和git到最新版本 [root@jenkins ~]# yum install -y curl-devel expat-devel gettext-devel openssl-devel ...

  9. CentOs 6.x 升级 Python 版本【转】

    在CentOS 6.X 上面安装 Python 2.7.X CentOS 6.X 自带的python版本是 2.6 , 由于工作需要,很多时候需要2.7版本.所以需要进行版本升级.由于一些系统工具和服 ...

随机推荐

  1. webpack配置的说明

    {devtool: 'source-map',//要启用source-map需加上此配置项,同时css或less的loader要加上参数?sourceMap,js的loader不用加 entry: e ...

  2. python 多线程,多进程,高效爬虫

    1.多线程from concurrent.futures import ThreadPoolExecutor import requests def fetch_async(url): respons ...

  3. .NTE Core Web API Example

    Source from :https://www.codeproject.com/Articles/1260600/Speed-up-ASP-NET-Core-WEB-API-application- ...

  4. Django Auth组件->扩展用户

    Auth用户 1.声明用户表 djangauth/settings.py..............................AUTH_USER_MODEL = 'app01.UserInfo' ...

  5. 更改mysql数据库默认的字符集(编码方式)

    mysql数据库的默认编码方式是latin1, 在mysql中存储和显示中文时会产生乱码,必须要更改默认的编码方式为utf8 或 gbk.(以下以gbk为例.) 更改服务器的编码方式,在终端输入以下命 ...

  6. 类型type:clusterip和service内部的关系

    类型type:clusterip和service内部的关系 待办 https://stackoverflow.com/questions/41509439/whats-the-difference-b ...

  7. 吴裕雄 python 机器学习——多项式贝叶斯分类器MultinomialNB模型

    import numpy as np import matplotlib.pyplot as plt from sklearn import datasets,naive_bayes from skl ...

  8. linux安装、使用优化、常用软件

    定制自己的ubuntu桌面系统 一.安装ubuntu 1.下载ubuntu镜像Iso文件 ubuntu官网下载:https://cn.ubuntu.com/download 2.u盘写入 (1)下载U ...

  9. Atcoder Beginner Contest152F(DFS+状压DP)

    二维状压写成一维状压,省略加上第i条边这一维 #define HAVE_STRUCT_TIMESPEC #include<bits/stdc++.h> using namespace st ...

  10. php的str_pad()函数

    实例 填充字符串的右侧,到30个字符的新长度 <?php $str = "Hello World"; echo str_pad($str,30,"."); ...