October-09-2019
Developed in 2009, REmote Dictionary Server(REDIS) is an open source, NoSql key value database. You can say it’s a data structure server for developers to organize and use data efficiently and quickly. It is written in ANSI C.
It supports data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs, geospatial indexes with radius queries and streams.
Redis is a popular choice for caching, session management, gaming, leaderboards, real-time analytics, geospatial, ride-hailing, chat/messaging, media streaming, and pub/sub apps.
Redis delivers sub-millisecond response times enabling millions of requests per second for real-time applications in Gaming, Ad-Tech, Financial Services, Healthcare, and IoT.
Update the apt-get packages index files and also update existing packages to the newest versions by using the following commands:
sudo apt-get update
sudo apt-get upgrade
Run below command from the terminal to install Redis on your machine:
sudo apt-get install redis-server
Enable Redis to start on system boot. Also restart Redis service once.
sudo systemctl enable redis-server.service
Although you don’t need to configure to start redis. But if you want to change something according to your needs. You need to edit this file :
sudo vim /etc/redis/redis.conf
You can increase max memory limit as per available on your server.
maxmemory 256mb
maxmemory-policy allkeys-lru
Save the configuration file and restart the Redis service:
sudo systemctl restart redis-server.service
Use redis-cli tool to verify the connection between the Redis server.
127.0.0.1:6379> ping
PONG
127.0.0.1:6379>
If you’re getting this error:
Could not connect to Redis at 127.0.0.1:6379: Connection refused
Then, Open a terminal and type this command:
redis-server
If you liked this post, then share it with friends :-)
Thank you!
Share this post:
Get in touch_
Or just write me a letter here_