下载好redis5.0后解压在/tmp目录

 cd /tmp/redis-5.0./
make

make过程中可能出现make[1]: *** [adlist.o] 错误 127,这是因为CentOS7默认没有安装gcc,所以安装gcc

 yum -y install gcc
make

make过程中又可能出现zmalloc.h:50:31: error: jemalloc/jemalloc.h: No such file or directory,zmalloc.h:55:2: error: #error "Newer version of jemalloc required",这样的错误,原因是jemalloc重载了Linux下的ANSI C的malloc和free函数,因此,make时添加参数

 make MALLOC=libc

make成功后我们看到提示:Hint: To run 'make test' is a good idea ;)

 make test

在进行测试的时候,我们有看到了错误:You need tcl 8.5 or newer in order to run the Redis test,make: ***[test] Error_1,解决办法是用yum安装tcl

 yum -y install tcl
make test

终于成功了!安装redis到指定目录

 make install PREFIX=/usr/local/redis
mkdir /usr/local/redis/etc
cp redis.conf /usr/local/redis/etc

配置redis为后台启动

 vim /usr/local/redis/etc/redis.conf #将daemonize no 改成daemonize yes

启动redis

 redis-server /usr/local/redis/etc/redis.conf

关闭redis

 pkill redis  

CentOS7安装redis5.0的更多相关文章

  1. Centos7安装redis5.0.7

    1. 安装依赖包 yum install -y gcc gcc-c++ 2. 下载最新版redis安装包并解压安装 cd /usr/local/src wget http://download.red ...

  2. centos7安装Redis5.0.5

    1.下载redismkdir /home/redis/cd /home/redis/wget http://download.redis.io/releases/redis-5.0.5.tar.gzt ...

  3. Centos7安装Redis5.0.5并加入Systemd服务

    1. 安装gcc-c++, tcl yum install gcc-c++ tcl 2. 解压缩, 编译, 测试 tar zxvf redis-5.0.5.tar.gz make make test ...

  4. Centos7安装Redis5.0.3

    1.切换目录 cd tmp 2.下载 wget http://download.redis.io/releases/redis-5.0.3.tar.gz 3.解压,删除压缩包 tar xzf redi ...

  5. CentOS7下编译安装redis-5.0.9

    CentOS7下编译安装redis-5.0.9 本文地址http://yangjianyong.cn/?p=171转载无需经过作者本人授权 下载redis #code start wget https ...

  6. CentOS7.6下安装Redis5.0.7

    此次安装是在CentOS7下安装Redis5.0.7 一.首先准备Redis安装包 这里下载的是 redis-5.0.7.tar.gz 安装包,并将其直接放在了 root ⽬录下 压缩包下载地址:ht ...

  7. CentOS7源码安装Redis5.0.4非关系型数据库

    源码安装redis-5.0.4 一. 下载redis 1. 需要连接网络 二. 案例(另一种安装方法) [root@localhost ~]# wget http://download.redis.i ...

  8. centos7安装redis3.0和phpredis扩展详细教程(图文)

    整理一下centos7安装redis3.0和phpredis扩展的过程,有需要的朋友可以拿去使用. 一.安装redis3.0 1.安装必要的包 yum install gcc 2.centos7安装r ...

  9. CentOS6.10安装redis5.0

    1.以安装redis5.0.0为例 下载安装包:http://redis.io 安装非常简单! [root@centos6 ~]#yum install gcc #需要先安装GCC,如果已安装请忽略 ...

随机推荐

  1. MyEclipse无法创建servers视图:Could not create the view: An unexpected exception was thrown

    今天上班刚打开MyEclipse,就发现servers视图无法打开了,显示:Could not create the view: An unexpected exception was thrown. ...

  2. UVA 11768 - Lattice Point or Not

    首先本题需要用到扩展欧几里得算法…… 关于exgcd算法的一点简略证明: 那么,对于函数exgcd(a,b)=(d,x,y),其中d满足d=gcd(a,b); (x,y)满足ax+by=d; 则exg ...

  3. CCCC L2-017. 人以群分 贪心

    https://www.patest.cn/contests/gplt/L2-017 题解:贪心,一点小数学 坑:XJB改下标改错了 #include <iostream> #includ ...

  4. mysqli_report

    MYSQLI_REPORT_OFF Turns reporting off MYSQLI_REPORT_ERROR Report errors from mysqli function calls M ...

  5. redis 数据迁移

    最近有个项目因为要搬迁服务器的原因,去找了服务器公司的运维,需要收费,于是果断决定自己实现这个功能.现在百度上已经一大把redis数据库迁移的教程,大部分是利用主从复制或者利用redis的RDB备份之 ...

  6. celery消息的编码和序列化(转)

    add by zhj: 原文讲的是序列化时的安全问题,不过,我关心的是怎样可以看到消息队列中的数据.下面是在broker中看到的消息,body是先用 body_encoding编码,然后用conten ...

  7. 【JMeter】集合点的设置

    [JMeter]集合点的设置 简单来理解一下,虽然我们的“性能测试”理解为“多用户并发测试”,但真正的并发是不存在的,为了更真实的实现并发这感念,我们可以在需要压力的地方设置集合点,每到输入用户名和密 ...

  8. 去掉UITableView多余的分割线

    UIView *v = [[UIView alloc] initWithFrame:CGRectZero]; [_tableView setTableFooterView:v];

  9. ffmpeg综合应用示例(三)——安卓手机摄像头编码

    本文的示例将实现:读取安卓手机摄像头数据并使用H.264编码格式实时编码保存为flv文件.示例包含了 1.编译适用于安卓平台的ffmpeg库 2.在java中通过JNI使用ffmpeg 3.读取安卓摄 ...

  10. HDU1010:Tempter of the Bone(dfs+剪枝)

    http://acm.hdu.edu.cn/showproblem.php?pid=1010   //题目链接 http://ycool.com/post/ymsvd2s//一个很好理解剪枝思想的博客 ...