This article is a mirror article of machine translation, please click here to jump to the original article.

View: 15702|Reply: 4

[Redis] CentOS 7 installation Redis 5.0.3 tutorial

[Copy link]
Posted on 3/7/2019 1:08:38 PM | | | |
Environment:

CentOS Linux release 7.5.1804 (Core)
Redis version: 5.0.3 (the latest stable version of redis is 5.0.3)

Installation



disposition

The main modification of the redis.conf configuration

# Modify the configuration
# redis runs as a daemon
# no means it does not run as a daemon (takes up a terminal)  
daemonize yes

# Set up password authorization
requirepass <设置密码>

#持久化存放目录
dir /alidata/server/redis/data/
Configure environment variables



--Added the following code

# Save and exit
# Make environment variables take effect immediately
Configure the startup script


Create a new redis file

redis (1.37 KB, Number of downloads: 1, 售价: 1 粒MB)

Turn on the self-start settings

Start the test

(End)




Previous:Install the redis extension under php 5.5.7 under CentOS
Next:python3 crawler latest eBook! Asynchronous book membership purchase
Posted on 3/7/2019 2:10:09 PM |
There is a bug in the configuration script here, that is, after the server is restarted, wait for more than 5 minutes before the restart is successful.

View the service startup time command:





There is no service that takes very long time.

Looking at the /var/log/messages log, I found a large number of logs as follows:

Mar  7 13:57:15 itsvse.com redis: Waiting for Redis to shutdown ...
Mar  7 13:57:16 itsvse.com redis: Waiting for Redis to shutdown ...
Mar  7 13:57:17 itsvse.com redis: Waiting for Redis to shutdown ...
Mar  7 13:57:18 itsvse.com redis: Waiting for Redis to shutdown ...
Mar  7 13:57:19 itsvse.com redis: Waiting for Redis to shutdown ...
Mar  7 13:57:20 itsvse.com redis: Waiting for Redis to shutdown ...


Because password authentication is configured,And when restarting, there is no password configured

Workaround:

1. Modify the redis service script and add the following information:




Posted on 3/7/2019 6:03:28 PM |
Learn to learn
 Landlord| Posted on 4/23/2024 9:07:33 AM |
 Landlord| Posted on 4/24/2024 4:54:11 PM |
CentOS 7 installs the Redis 7.2.4 caching service
https://www.itsvse.com/thread-10761-1-1.html
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com