CentOS 安装 Redis & 配置

  • 下载 Stable (稳定版)
    • https://redis.io/download
  • 解压
    • tar -zxvf redis-5.0.8.tar.gz
  • 移动解压出来的文件到
    • /usr/local/
  • 进入文件
    • cd /usr/local/redis-5.0.8/
  • 安装gcc依赖
    • yum install -y gcc
  • 编译
    • make
  • 安装(这里可以指定安装目录:PREFIX=/usr/local/redis)
    • make install
  • 启动
    • redis-server

配置

  • 配置后台运行
    • 修改配置文件:redis.conf
    • daemonize no修改为:daemonize yes
    • 后台启动:./redis-server /usr/local/redis-5.0.7/redis.conf
posted @ 2020-03-30 18:07  Mr-Lim  阅读(130)  评论(0编辑  收藏  举报