"Original" CentOS6.5 Installing the Redis database

Source: Internet
Author: User
Tags benchmark

1 , to install redis2.8.19 as an example

Download the installation package: Http://redis.io

Tar zxvf redis-2.8.19.tar.gz  # unzip the CD redis-2.8.19               # into the unpacked folder Yum install GCC               # may need to install GCCmake                          # compilation First

If compile error: Error:jemalloc/jemalloc.h:no such file or directory

Solution:

Make MALLOC=LIBC          # compile cd src && make install    # Enter the src folder and compile the installation file

2 , recursively create folders

Mkdir-p/usr/local/redis/-p/usr/local/redis/etc

3 , move files

Mv/usr/local/src/redis-2.8.19/redis.conf/usr/local/redis/etc        # configuration file mv mkreleasehdr.sh Redis-benchmark redis-check-aof redis-check-dump redis-cli redis-sentinel redis-server/usr/local/redis/bin        # Startup file

4 , to see if the profile has moved

Cd/usr/local/redis/bin#Enter this directoryll#See if the file is as follows Total2484-rwxrwxr-x. 1 root root 566 Dec 16 16:18mkreleasehdr.sh-rwxr-xr-x. 1 root root 4586363 Mar 01:54 redis-Benchmark-rwxr-xr-x. 1 root root 22233 Mar 01:54 redis-check-aof#Log Append Database-rwxr-xr-x. 1 root root 45443 Mar 01:54 redis-check-dump#Snapshot Mode Database-rwxr-xr-x. 1 root root 4679859 Mar 01:54 redis-cli#Client-rwxr-xr-x. 1 root root 6241796 Mar 01:54 redis-server#Start the service

5 , modify Configuration

vi/usr/local/redis/etc/redis.conf  # change config file daemonize No to Yes                # background boot 

6 , run

redis-server/usr/local/redis/etc/redis.conf  # start service command NETSTAT-TUNPL | grep 6379                    # See if Port 6379 is occupied

7 , open firewall port

/sbin/iptables-i input-p TCP--dport 6379-j ACCEPT  # open 6379 port /etc/rc.d/init.d/iptables save< c11/># save config /etc/rc.d/init.d/iptables restart                      # Restart service /etc/init.d/ Iptables status                            # to see if the port is open


--Solemn statement: This article is only for the author's personal notes, please do not reprint! ——

Original CentOS6.5 Installing the Redis database

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.