编译安装redis 5.05

1. 官网现在redis的源码包,并解压

[root@node0 ~]# wget http://download.redis.io/releases/redis-5.0.5.tar.gz

[root@node0 ~]# tar -zxvf redis-5.0.5.tar.gz

2. 对响应的目录添加执行权限,不然会报 : jemalloc/jemalloc.h Not Found  等问题,

[root@node0 ~]# cd redis-5.0.5

[root@node0 redis-5.0.5]# ls -ltr
total 264
drwxrwxr-x  8 root root   4096 May 16 00:07 utils
drwxrwxr-x 11 root root    182 May 16 00:07 tests
drwxrwxr-x  3 root root   4096 May 16 00:07 src
-rw-rw-r--  1 root root   9710 May 16 00:07 sentinel.conf
-rwxrwxr-x  1 root root    281 May 16 00:07 runtest-sentinel
-rwxrwxr-x  1 root root    341 May 16 00:07 runtest-moduleapi
-rwxrwxr-x  1 root root    280 May 16 00:07 runtest-cluster
-rwxrwxr-x  1 root root    275 May 16 00:07 runtest
-rw-rw-r--  1 root root  61797 May 16 00:07 redis.conf
-rw-rw-r--  1 root root  20555 May 16 00:07 README.md
-rw-rw-r--  1 root root   6888 May 16 00:07 MANIFESTO
-rw-rw-r--  1 root root    151 May 16 00:07 Makefile
-rw-rw-r--  1 root root     11 May 16 00:07 INSTALL
drwxrwxr-x  6 root root    124 May 16 00:07 deps
-rw-rw-r--  1 root root   1487 May 16 00:07 COPYING
-rw-rw-r--  1 root root   2381 May 16 00:07 CONTRIBUTING
-rw-rw-r--  1 root root     53 May 16 00:07 BUGS
-rw-rw-r--  1 root root 106874 May 16 00:07 00-RELEASENOTES

[root@node0 redis-5.0.5]# chmod -R +x  tests  src   utils deps

3. 编译并安装

[root@node0 redis-5.0.5]# make MALLOC=libc  && make install

.....


Hint: It's a good idea to run 'make test' ;)

make[1]: Leaving directory `/root/redis-5.0.5/src'
cd src && make install
make[1]: Entering directory `/root/redis-5.0.5/src'
    CC Makefile.dep
make[1]: Leaving directory `/root/redis-5.0.5/src'
make[1]: Entering directory `/root/redis-5.0.5/src'

Hint: It's a good idea to run 'make test' ;)

    INSTALL install
    INSTALL install
    INSTALL install
    INSTALL install
    INSTALL install
make[1]: Leaving directory `/root/redis-5.0.5/src'

[root@node0 redis-5.0.5]# which redis-server
/usr/local/bin/redis-server

[root@node0 redis-5.0.5]# redis-server --version
Redis server v=5.0.5 sha=00000000:0 malloc=jemalloc-5.1.0 bits=64 build=51b214f16cfd9bb7

 

PS: 允许方式 redis-server redis.conf ,配置的详解参考如下文档

https://redis.io/topics/config

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值