Tuesday, 26 April 2022

Optimizing Redis: Best Practices for Enhanced Performance and Tuning

TCP-KeepAlive

TCP-KeepAlive Graph
vim /etc/redis/redis.conf# Update the value to 0
tcp-keepalive 0

Pipelining

How to Use Pipelining
Pipelining Graph

Max-Connection

sudo vim /etc/rc.local

# make sure this line is just before of exit 0.
sysctl -w net.core.somaxconn=65365

Overcommit Memory

echo 'vm.overcommit_memory = 1' >> /etc/sysctl.conf

RDB Persistence and Append Only File

sudo vim /etc/redis/redis.conf

# Comment out these lines
save 900 1
save 300 10
save 60 10000

rdbcompression no
rdbchecksum no

appendonly no

Transparent Huge Page(THP)

sudo vim /etc/rc.local

# Add this line before exit 0
echo never > /sys/kernel/mm/transparent_hugepage/enabled








No comments:

Post a Comment

Exploring the Power of Generative AI Services: Unlocking Limitless Creativity

Introduction In recent years, we have witnessed remarkable advancements in the field of artificial intelligence (AI). One of the most intrig...