How To Install Redis on RHEL 7 Server

Posted on 190 views

How to Install Redis on RHEL 7 Server / Desktop system?. Redis is an Open Source in-memory data store which can be used as a database server, as a message broker, or to cache data in memory for faster retrieval.

In this article, we will cover the steps used to Install Redis on RHEL 7 Server. The version of Redis installed will be the latest stable available. A pre-requisite for this installation is existing RHEL 7 server/Desktop.

Step 1: Register your RHEL 7 server

Start by registering your RHEL 7 server with Red Hat Subscription Management or Satellite server.

sudo subscription-manager register --auto-attach

Input your username and password when prompted.

Step 2: Enable required repositories

After registering the system, enable RHEL 7 repositories.

sudo subscription-manager repos --enable=rhel-7-server-rpms \
  --enable=rhel-7-server-extras-rpms \

Also add EPEL and Remi repositories.

sudo yum -y install
sudo yum -y install

Step 3: Install Redis on RHEL 7

Now install Redis on RHEL 7 using the following commands.

sudo yum install -y redis --enablerepo=remi

Enable and start the service after installation.

sudo systemctl enable --now redis

If you have an active firewalld service, allow port 6379

sudo firewall-cmd --add-port=6379/tcp --permanenent
sudo firewall-cmd --reload

Step 4: Configure Redis Authentication (optional)

Configure Redis Authentication for clients to require AUTH  before processing any other commands.



requirepass [email protected]

Restart redis service after making the changes

sudo systemctl restart redis

Step 5: Test Redis Installation on RHEL 7

Confirm that you can connect to redis locally:

$ redis-cli>

Test authenticate:> AUTH 

You should receive OK in the output. If you input a wrong password, Authentication should fail:> AUTH WrongPassword 
(error) ERR invalid password

Check redis information.>  INFO

In this article, you have learned how to Install and Configure Redis Server on RHEL 7. Stay connected for more articles.


Gravatar Image
A systems engineer with excellent skills in systems administration, cloud computing, systems deployment, virtualization, containers, and a certified ethical hacker.