签到成功

知道了

CNDBA社区CNDBA社区

Centos 7.9安装redis

2021-12-27 22:56 2103 0 原创 redis
作者: hbhe0316

1.下载地址:
https://redis.io/download

http://www.cndba.cn/hbhe0316/article/99292
http://www.cndba.cn/hbhe0316/article/99292

2.编译安装redishttp://www.cndba.cn/hbhe0316/article/99292

http://www.cndba.cn/hbhe0316/article/99292
http://www.cndba.cn/hbhe0316/article/99292

[root@mysql57 ~]# tar xvf /tmp/redis-6.2.6.tar.gz -C /
[root@mysql57 ~]# mv /redis-6.2.6/ /redis
[root@mysql57 ~]# yum install gcc-c++ -y
[root@mysql57 redis]# cd /redis/
[root@mysql57 redis]# make
[root@mysql57 redis]# src/redis-server 
6402:C 27 Dec 2021 22:54:31.062 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
6402:C 27 Dec 2021 22:54:31.062 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=6402, just started
6402:C 27 Dec 2021 22:54:31.062 # Warning: no config file specified, using the default config. In order to specify a config file use src/redis-server /path/to/redis.conf
6402:M 27 Dec 2021 22:54:31.062 * Increased maximum number of open files to 10032 (it was originally set to 1024).
6402:M 27 Dec 2021 22:54:31.062 * monotonic clock: POSIX clock_gettime
                _._                                                  
           _.-``__ ''-._                                             
      _.-``    `.  `_.  ''-._           Redis 6.2.6 (00000000/0) 64 bit
  .-`` .-```.  ```//    _.,_ ''-._                                  
 (    '      ,       .-`  | `,    )     Running in standalone mode
 |`-._`-...-` __...-.``-._|'` _.-'|     Port: 6379
 |    `-._   `._    /     _.-'    |     PID: 6402
  `-._    `-._  `-./  _.-'    _.-'                                   
 |`-._`-._    `-.__.-'    _.-'_.-'|                                  
 |    `-._`-._        _.-'_.-'    |           https://redis.io       
  `-._    `-._`-.__.-'_.-'    _.-'                                   
 |`-._`-._    `-.__.-'    _.-'_.-'|                                  
 |    `-._`-._        _.-'_.-'    |                                  
  `-._    `-._`-.__.-'_.-'    _.-'                                   
      `-._    `-.__.-'    _.-'                                       
          `-._        _.-'                                           
              `-.__.-'                                               

6402:M 27 Dec 2021 22:54:31.063 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
6402:M 27 Dec 2021 22:54:31.063 # Server initialized
6402:M 27 Dec 2021 22:54:31.063 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
6402:M 27 Dec 2021 22:54:31.063 * Ready to accept connections

3.测试是否安装完成http://www.cndba.cn/hbhe0316/article/99292

http://www.cndba.cn/hbhe0316/article/99292
http://www.cndba.cn/hbhe0316/article/99292
http://www.cndba.cn/hbhe0316/article/99292http://www.cndba.cn/hbhe0316/article/99292

[root@mysql57 ~]# cd /redis/
[root@mysql57 redis]# src/
mkreleasehdr.sh  redis-check-aof  redis-sentinel   
modules/         redis-check-rdb  redis-server     
redis-benchmark  redis-cli        redis-trib.rb    
[root@mysql57 redis]# src/
mkreleasehdr.sh  redis-check-aof  redis-sentinel   
modules/         redis-check-rdb  redis-server     
redis-benchmark  redis-cli        redis-trib.rb    
[root@mysql57 redis]# src/redis-c
redis-check-aof  redis-check-rdb  redis-cli        
[root@mysql57 redis]# src/redis-cli 
127.0.0.1:6379> set foo bar
OK
127.0.0.1:6379> get foo
"bar"

版权声明:本文为博主原创文章,未经博主允许不得转载。

Redis

用户评论
* 以下用户言论只代表其个人观点,不代表CNDBA社区的观点或立场
hbhe0316

hbhe0316

关注

1.只有承认无知,才能装下新的东西; 2.进步来自一点点滴滴的积累; 3.广博让你更优秀,而专业让你无法替代; 4.挫折和失败能够转换为一种财富。

  • 889
    原创
  • 1
    翻译
  • 13
    转载
  • 24
    评论
  • 访问:2589781次
  • 积分:1523
  • 等级:核心会员
  • 排名:第6名
精华文章
    最新问题
    查看更多+
    热门文章
      热门用户
      推荐用户
        Copyright © 2016 All Rights Reserved. Powered by CNDBA · 皖ICP备2022006297号-1·

        QQ交流群

        注册联系QQ