This article describes how to install Redis for Ubuntu Linux 20.04.
Install Redis
For correct operation, you will need Redis version 5 or 6.2.
Install redis by running the following command:
sudo apt install redis-server
Configure Redis
начало внимание
You can use the following characters in a password:
- Capital Latin letters (A to Z)
- Lowercase Latin letters (a to z)
- Digits (0 to 9)
- Symbols: !()-_+=$
конец внимание
- Allow connecting to the Redis server by editing the
/etc/redis/redis.conf
configuration file and adding the machine’s IP address (for example, 192.168.10.10):
sudo nano /etc/redis/redis.conf
bind 127.0.0.1 ::1 192.168.10.10
- Increase the maximum number of clients by changing the
maxclients
parameter’s value to20000
. You also need to uncomment the line (delete the # character):
maxclients 20000
- Restart Redis:
sudo systemctl restart redis-server
Connect to Redis
Connection string for Redis:
redis://<redis-server-address>:6379/0
Was this helpful?
Found a typo? Highlight the text, press ctrl + enter and notify us