编程知识 cdmana.com

Redisx installation

1. install Redis 6.x

  • First download the new version of redis6 And upload it to centos7:
    -w1094

  • install redis need gcc Environment , It's different from the old version , there gcc Need a higher version .

    yum install gcc-c++ 
    

    -w835

  • Then upgrade gcc edition

yum -y install centos-release-scl
yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++ devtoolset-9-binutils
scl enable devtoolset-9 bash

  • Permanent configuration gcc9 Environment
echo -e "\nsource /opt/rh/devtoolset-9/enable" >>/etc/profile
  • Look again ,gcc The version of has been updated
    -w864

  • gcc After installation , Next you can follow redis 了 , decompression redis6 Installation package

    tar -zxvf redis-6.0.9.tar.gz 
    

-w1074

  • Go to the unzipped folder , Compile and install redis

    make
    make install PREFIX=/usr/local/redis
    
  • It needs to be configured after installation , First copy the configuration file to the installation directory :
    -w1327

  • then vim Modify this file

    • Background start
      -w1141
    • whatever ip Can even
      -w1087
    • Change Password
      -w1185
    • redis Running in the background image , Generally define a log , Easy to view
      -w1072
  • function redis

    ./redis-server redis.conf
    
  • Check the log , Indicates successful operation

    vim /usr/local/redis/redis.log
    

-w1724

  • Turn on redis Client tools , And test it
    -w625

  • Use RDS Tools connect and view :
    -w589
    -w653

thus ,Redis6 Installation successful , Actually sum 5.x It's the same , It's just gcc The version needs to be upgraded , All of the partners will compile when they install it .

Click to see more

版权声明
本文为[osc_ vqbasmql]所创,转载请带上原文链接,感谢
https://cdmana.com/2020/12/20201225112343211F.html

Scroll to Top