zoukankan      html  css  js  c++  java
  • 阿里云Redis 配置

    查看路径whereis redis

    1.修改配置文件

    vim /etc/redis.conf

    这三个配置是必须的

    修改内容,把 daemonize no 修改为:daemonize yes

     requirepass 123456 // 这个用来修改密码

     bind 0.0.0.0  // 这个用来绑定ip 原来是127.0.0.1

     

    1.这是因为配置文件中,以守护进程方式启动,默认是关闭的,这是设置为允许以守护进程方式启动服务

    2.启redis-server /etc/redis.conf看redis服务是否启动 另一种启动方式 ./redis-server /etc/redis.conf 

    ps aux | grep redis

    [root@localhost ~]# ps aux | grep redis
    root 3339 0.1 0.5 139524 5208 ? Ssl 18:41 0:00 redis-server 127.0.0.1:6379
    root 3343 0.0 0.0 103324 848 pts/0 S+ 18:41 0:00 grep redis

    3.这时候再用命令

    redis-cli

  • 相关阅读:
    Jzoj4765 Crisis
    Jzoj4764 Brothers
    Jzoj4764 Brothers
    Jzoj4756 幻象
    Jzoj4756 幻象
    Jzoj4755 快速荷叶叶变换
    Jzoj4755 快速荷叶叶变换
    力扣算法题—059螺旋矩阵
    力扣算法题—058最后一个单词长度
    力扣算法题—057插入区间
  • 原文地址:https://www.cnblogs.com/wupeng88/p/12030537.html
Copyright © 2011-2022 走看看