Install 1st Redis instance
By installing the first Redis instance, you can use the configuration as template for your 2nd one.
yum install redis
service redis start
This redis instance listens on localhost:6379
by default.
Install 2nd Redis instance
create a new working directory
The default redis instance uses /var/lib/redis
as its working directory, dumped memory content is saved under this directory with name dump.rdb
if you did not change it manually.
to avoid runtime conflict, we need to create a new working directory
mkdir -p /var/lib/redis2/
chown redis /var/lib/redis2/
chgrp redis /var/lib/redis2/
generate configurations
Create a new configuration file by copying /etc/redis.conf
cp /etc/redis.conf /etc/redis2.conf
Edit following settings to avoid conflicts
logfile "/var/log/redis/redis2.log"
dir "/var/lib/redis2"
pidfile "/var/run/redis/redis2.pid"
port 6380
add startup script
Create service file
cp /usr/lib/systemd/system/redis.service /usr/lib/systemd/system/redis2.service
Modify the settings under Service
section
[Service]
ExecStart=/usr/bin/redis-server /etc/redis2.conf --daemonize no
ExecStop=/usr/bin/redis-shutdown redis2
set to start with boot
systemctl enable redis2
start 2nd redis
service redis2 start
check status
lsof -i:6379
lsof -i:6380
Great article. this blog shared very useful information about game developing. very nice information provide for beginners level game developers. M&A data room
ReplyDeletedesign lovely custom boxes in minutes. Alter mailer boxes, shipping boxes, and collapsing containers. Low essentials, moment statements, and quick turnaround time
ReplyDeleteNice blog, it’s so knowledgeable, informative, and good looking site. I appreciate your hard work. Good job. Thank you for this wonderful sharing with us. Keep Sharing.
ReplyDeleteTours and Travels in Madurai | Best tour operators in Madurai
Best travel agency in Madurai | Best Travels in Madurai
Amazing Article,Really useful information to all So, I hope you will share more information to be check and share here.
ReplyDeleteinplant training
inplant training chennai
inplant training meaning
inplant training certificate
inplant training report
report for inplant training
inplant training certificate format
inplant training meaning in tamil
what is inplant training
inplant training in chennai for mechanical
Thanks for sharing such a great blog......!!!
ReplyDeletefull form
full form of nrc
nrc full form
mbbs full form
full form of rip