Valkey is a high-performance NoSQL database management system designed based on Redis for modern cloud and distributed systems.
начало внимание
Valkey version 7.2.8 or higher is required for proper system operation.
конец внимание
This article describes how to install Valkey 8.1.1 on Ubuntu Linux 22.04 and 24.04. You can obtain Valkey installation files for your OS from:
For detailed instructions, refer to the official Valkey documentation.
It is recommended to install Valkey in the same Kubernetes environment as the BRIX application. For more details on infrastructure organization options, refer to the BRIX On-Premises Standard and BRIX On-Premises Enterprise articles.
To replace Redis with Valkey, see the Migrate from Redis to Valkey article.
Valkey deployment steps:
Step 1: Valkey installation
- Install the packages:
sudo apt install -y apt-transport-https ca-certificates curl
- Import the keys:
sudo curl -fsSL https://repo.elma365.tech/deb/elma365-keyring.gpg | gpg --dearmor > /etc/apt/trusted.gpg.d/elma365-keyring.gpg
- Add the repository:
echo "deb [arch=amd64] https://repo.elma365.tech/deb $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/elma365.list
sudo apt update
- Install Valkey:
sudo apt install elma365-valkey-server
Step 2: Valkey configuration
начало примечание
Note
The password can contain the following characters:
- Uppercase Latin letters: A to Z
- Lowercase Latin letters: a to z
- Digits: 0 to 9
- Symbols: -_
Reserved (invalid) characters:
! * ' ( ) ; : @ & = + $ , / ? % # [ ]
конец примечание
Configure the database management system installed:
- Enable connection to the Valkey server. To do it, edit the
/etc/Valkey/Valkey.conf
configuration file by adding the IP address of the server, e. g. 192.168.10.10:
sudo nano /etc/valkey/valkey.conf
bind 127.0.0.1 ::1 192.168.10.10
port 0 |
- Increase the maximum number of clients by setting the
maxclients
parameter to20000
. Uncomment the line by removing the#
sign:
maxclients 20000
- Set the key eviction policy by setting the
maxmemory-policy
parameter toallkeys-lfu
. Uncomment the line by removing the#
sign:
maxmemory-policy allkeys-lfu
- Disable creation of snapshots by setting the
save
parameter to null. Uncomment the line by removing the#
sign:
save ""
- Disable the AOF (Append Only File) to prevent saving of Valkey data in a file. To do it, set the
appendonly
parameter tono
. Uncomment the line by removing the#
sign:
appendonly no
- Optional. Add a password to access Valkey using allowed characters:
requirepass SecretPassword
- Disable the protected mode if the
bind 0.0.0.0
parameter is used or therequirepass
option is not set:
protected-mode no
- Restart Valkey:
sudo systemctl restart valkey-server
Step 3: Connection to Valkey
Connection string for Valkey:
redis://<valkey-server-address>:6379/0
Connection string for Valkey if access by password is enabled:
redis://:SecretPass@<valkey-server-address>:6379/0
Connection string for Valkey with TLS/SSL:
rediss://<valkey-server-address>:6379/0
Connection string for Valkey with TLS/SSL if access by password is enabled:
rediss://:SecretPass@<valkey-server-address>:6379/0
Found a typo? Select it and press Ctrl+Enter to send us feedback