Centos7 redis-4.0.8 installation process and troubleshooting, centos7redis-4.0.8

Source: Internet
Author: User

Centos7 redis-4.0.8 installation process and troubleshooting, centos7redis-4.0.8
Redis-4.0.8 Installation Process

Please install it under the root account.

1. Upload

Use a tool to upload the redis Installation File to/usr/local.

. Decompress

Su-root

Cd/usr/local

Tar-zxvf redis-2.8.19.tar.gz

1. 3. Compile

Cd redis-4.0.8

Make

1.4. Answers to the compilation process

1. make: Warning: A clock error is detected. Your creation may be incomplete.

Solution 1: touch/shttpd/include/shttpd. h

Then re-make

Solution 2: the cause of this problem is that the file to be compiled is later than the current system time, so you can synchronize the current system time

Date-s "yyyy-BB-dd HH: mm: ss"

Update the time to the latest time, and then compile the system. There is no problem that the system time is earlier than the time needed for compilation.

2. error: jemalloc/jemalloc. h: No such file or directory

About the Allocator, the default alloc is MALLOC, which has fewer problems, but if you do not have jemalloc, but only lib, make will have an error.

Solution: make MALLOC = libc

1.5 Installation

After the compilation is successful, install: make install

1.6 Start the server

Cd/usr/local/cd redis-2.8.19

Redis-server redis. conf &

1.7 run

Install the Test Service and run the client: redis-cli

1.8 common redis commands

Redis> ping

PONG

Redis> set foo bar

OK

Redis> get foo

"Bar"

Redis> incr mycounter

(Integer) 1

Redis> incr mycounter

(Integer) 2

Redis>

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.