Installing Redis under Linux

Source: Internet
Author: User
Tags download redis

1, First officer network Download Redis compressed package, address: Http://redis.io/download Download stable version 4.0.10 can

2. Through the remote management tool, copy the compressed package to the Linux server and perform the decompression operation:

# tar zxvf redis-4.0.10.tar.gz-c/usr/local//usr/local/
#ln-SV Redis-4.0.10/redis

3, into the Redis directory, execute make command, after compiling, you can see the extracted files Redis will have the corresponding SRC, conf and other folders

4, after the successful compilation, enter the SRC folder, execute make install for Redis installation

5, in order to facilitate management, the Redis file in the Conf configuration files and common commands to move to the unified file

A. Creating bin and etc folders

Go to the Redis directory and execute the following command

mkdir-p ECT

  B. Execute the Linux file Move command:

# mv Redis.conf etc/# cd src/# mv mkreleasehdr.sh redis-benchmark redis-check-aof redis-cli redis-serve R/usr/local/redis/bin

6, the above installed Redis foreground, if you want to change to background boot, you need to modify the redis.conf file, change the Daemonize property to Yes (indicating that the need to run in the background)

7. If you need to access this Redis service on another computer, you also need to note the bind attribute in the redis.conf file

8, at the same time you need to configure Redis a password, also in the redis.conf file, # Requirepass Foobared, release this note, requirepass Follow your password

9. Use the configuration file to start Redis: Switch to the/usr/local/redis/bin directory to execute the redis-server command and use the/usr/local/redis/etc/redis.conf profile to start the Redis service

10, Redis comes with the client, in the bin directory, using the command: ./redis-cli start the client, if you set a password, then use: Auth your password to log in, and then Ping, there will be pong response

Installing Redis under Linux

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.