CENTOS7 Installing Redis boot up

Source: Internet
Author: User
Tags redis download

Redis Download Https://redis.io/download

wget http://download.redis.io/releases/redis-3.2.6.tar.gz

Unzip

tar xzf redis-3.2. 6. tar. gz

Enter the extracted files directory

CD redis-3.2. 6

Redis installation is relatively straightforward and straightforward to compile

Make

To create a storage Redis file directory

mkdir -p/usr/local/redis

Copy Redis-server Redis-cli to the newly created folder

CP./REDIS-SERVER/USR/LOCAL/REDIS/CP./redis-cli/usr/local/redis/

Copy a Redis configuration file

Cd.. CP redis.conf/usr/local/redis/

Editing a configuration file

cd/usr/local/redis/
Vim redis.conf

Change to Yes background run

Add Boot start Service

Vim/etc/systemd/system/redis-server.service

Paste a little bit of content

[unit]description=the redis-server Process managerafter=syslog.target network.target[service ]type=simplepidfile=/var/run/redis_6379.pidexecstart=/usr/local/redis/redis-server/usr/ local/redis/redis.conf         execreload=/bin/kill -USR2 $MAINPIDExecStop=/bin/Kill -SIGINT $MAINPID [Install]wantedby=multi-user.target

Set boot up

Systemctl daemon-Reload systemctl start Redis-server.service systemctl enable Redis- Server.service

Check if the installation is successful

To create a redis command soft connection

LN -s/usr/local/redis/redis-cli/usr/bin/redis

Test Redis

Installation Complete

CENTOS7 Installing Redis boot up

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.