This article contains step by step on Installing And enable Redis On DirectAdmin With Ubuntu Operating system. Redis is open source webserver which is used for caching dynamic objects with fastest way to simplify database connection.
With this article I’m going to share with you on how to install and enable it on DirectAdmin panel with Ubuntu operating system.
This tip only works for VPS, Cloud and Dedicated hosting with root access, if you host your sites from shared hosting or managed hosting with limited root access, then this isn’t for you.
These are the steps for installing, configure and enable Redis server with Ubuntu OS;
Install system updates and upgrades before installing the Redis server with following commands
sudo apt update && apt upgrade
Second step, install Redis server with following commands
sudo apt install Redis-server
After the installation, just check if the Redis server running by running the following commands
sudo service Redis status
If it shows green active status, then close it then let’s go to another step
Configure the redis server with following commands
sudo nano /etc/redis/redis.conf
Find the supervised no name in configuration file, then replace it with supervised system then save it to make changes.
Install php-redis extension to DA if it isn’t present by typing the following commands, if it present then skip this.
apt-get install php-redis
Make sure you install the php-redis in according to php version by running the following commands
sudo apt-get install php7.4-redis
Test the connection by running the following commands
the result should be PONG, then everything is working as it supposed to be.
Last, if you are WordPress user then install Redis object cache plugin on WordPress repository, then enable it, you will see everything worked as it supposed to work.