Install
์ ์
Remote Dictionary Server์ ์ฝ์๋ก, ๋ฉ๋ชจ๋ฆฌ ๊ธฐ๋ฐ์ key-value ๊ตฌ์กฐ ๋ฐ์ดํฐ ๊ด๋ฆฌ ์์คํ ์ด๋ค.
์คํ์์ค์ด๋ฉฐ, ์๋๊ฐ ๋น ๋ฅด๋ค๋ ์ฅ์ ์ด ์๋ค.
ํ์
Redis
1 main node : no redundancy
replication (main-secondary) : 1 main node + 1 or more secondary node
Redis Sentinel
1 main node + 1 or more secondary node + 3 or more sentinel node
Redis Cluster
3 or more main node + 3 or more secondary node with replication
https://architecturenotes.co/content/images/size/w2400/2022/08/Redis-v2-01-1.jpg

Redis ์ค์น
์ฃผ์ : redis docker image๋ ์ ๋ช ํ๊ฒ์ด 2๊ฐ์ง๊ฐ ์๋ค.
๋๋ค ์จ๋ ๋ฌด๋ฐฉํ๋ค.
redis๋ ํ๊ฒฝ ๋ณ์๋ฅผ ์ง์์ ์ํ๊ณ conf ํ์ผ์ ์ง์ํ๋ค.
bitnami/redis๋ ํ๊ฒฝ ๋ณ์๋ฅผ ์ง์ํ๋ค.
bitnami/redis๋ฅผ ์ฌ์ฉํ๋ค. ๋ฒ์ ์ ๋ค์์์ ์ฐพ์์ ์๋ค. https://hub.docker.com/r/bitnami/redis/tags
single main node
cd redis/single-node
cat > docker-compose.yaml <<EOF
version: '3'
services:
redis:
image: 'bitnami/redis:7.2'
container_name: redis
ports:
- 6379:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
EOF
docker-compose up -d
docker ps -a
# test
docker run -it --rm bitnami/redis:7.2 redis-cli -h host.docker.internal
set mykey myvalue
> OK
get mykey
> "myvalue"
๋์ํ์ธ๋ซ๋ค ์ด๋ฐฉ์์ redundancy๊ฐ ์๋ค. ๊ทธ๋ฆฌ๊ณ ํธ๋ํฝ์ด ๋ง์์ง๋ฉด 1๊ฐ์ ์๋ฒ๊ฐ ๋ชจ๋ ํธ๋ํฝ์ ๋ฐ์์ผํ๋ค. ๊ทธ๋์ replication์ ์ฌ์ฉํ๋ค.
replication (main-secondary)
cd replica-multi-node
cat > docker-compose.yaml <<EOF
version: '3'
services:
redis-main:
image: 'bitnami/redis:7.2'
container_name: redis-main
hostname: redis-main
ports:
- 6379:6379
environment:
- REDIS_REPLICATION_MODE=main
- ALLOW_EMPTY_PASSWORD=yes
redis-replica:
image: 'bitnami/redis:7.2'
deploy:
replicas: 2
depends_on:
- redis-main
environment:
- REDIS_REPLICATION_MODE=Secondary
- ALLOW_EMPTY_PASSWORD=yes
EOF
docker-compose up -d
docker ps

# test
docker run -it --rm bitnami/redis:7.2 redis-cli -h host.docker.internal #access to main

์ด์ replica-1์์ ํ์ธํด๋ณด์.
docker exec -it replica-multi-node-redis-replica-1 redis-cli # access to replica-1
get mykey
> "myvalue"
๋ง์คํฐ์์ ์ ๋ ฅํ ๊ฐ์ Secondary๊ฐ ๊ฐ์ง๊ณ ์๋ค.
ํ๋ก๊ทธ๋จ์ Secondary ์ฐ๊ฒฐํ์ฌ ๋ฐ์ดํฐ๋ฅผ ๊ฐ์ ธ๊ฐ์ ์๋ค.
๋ฐ์ดํฐ์ ๋ณต์ ๊ฐ ์์ด์ ํ๋ ธ๋๊ฐ ๋ง๊ฐ์ง๋๋ผ๋ ๋ฐ์ดํฐ๊ฐ ์ ์ค๋์ง ์๋๋ค. ๊ทธ๋ฌ๋ ์๋์ผ๋ก main๋ฅผ ๋ณ๊ฒฝํด์ผํ๋ค. ์ด๊ฑธ ์๋์ผ๋ก ํด์ฃผ๋ ๊ฒ์ด Redis Sentinel์ด๋ค.
Redis Sentinel ์ค์น
cd sentinel
cat > docker-compose.yaml <<EOF
EOF
docker-compose up -d
docker ps

ํ์ธํด๋ณด์.
docker exec -it replica-multi-node-sentinel-redis-sentinel-1 redis-cli -p 26379
info sentinel
>
# Sentinel
sentinel_mains:1
sentinel_tilt:0
sentinel_tilt_since_seconds:-1
sentinel_running_scripts:0
sentinel_scripts_queue_length:0
sentinel_simulate_failure_flags:0
main0:name=mymain,status=ok,address=192.168.128.2:6379,Secondarys=2,sentinels=3
Redis Cluster ์ค์น
cd redis-cluster
cat > docker-compose.yaml <<EOF
version: '3'
services:
redis-node-0:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-0
ports:
- 6371:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
redis-node-1:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-1
ports:
- 6372:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
redis-node-2:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-2
ports:
- 6373:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
redis-node-3:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-3
ports:
- 6374:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
redis-node-4:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-4
ports:
- 6375:6379
environment:
- ALLOW_EMPTY_PASSWORD=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
redis-node-5:
image: 'bitnami/redis-cluster:7.2'
container_name: redis-node-5
ports:
- 6379:6379
depends_on:
- redis-node-0
- redis-node-1
- redis-node-2
- redis-node-3
- redis-node-4
environment:
- ALLOW_EMPTY_PASSWORD=yes
- REDIS_CLUSTER_REPLICAS=1
- REDIS_CLUSTER_CREATOR=yes
- 'REDIS_NODES=redis-node-0 redis-node-1 redis-node-2 redis-node-3 redis-node-4 redis-node-5'
EOF
docker-compose up -d
docker ps -a

# test
docker exec -it redis-node-1 redis-cli -c -p 6379 #cluster์ ์์ -c ์ต์
์ฌ์ฉ
cluster info
>
cluster_state:ok
cluster_slots_assigned:16384
cluster_slots_ok:16384
cluster_slots_pfail:0
cluster_slots_fail:0
cluster_known_nodes:6
cluster_size:3
cluster_current_epoch:6
cluster_my_epoch:2
cluster_stats_messages_ping_sent:228
cluster_stats_messages_pong_sent:227
cluster_stats_messages_meet_sent:1
cluster_stats_messages_sent:456
cluster_stats_messages_ping_received:227
cluster_stats_messages_pong_received:229
cluster_stats_messages_received:456
total_cluster_links_buffer_limit_exceeded:0
3 master ์ 3 secondary๋ก ๊ตฌ์ฑ๋์๋ค.

cluster_state : ํด๋ฌ์คํฐ๊ฐ ์ ์์ธ ์ํ์ ๋๋ค. cluster_slots_assigned : ํด๋ฌ์คํฐ์ ํ ๋น๋ ์ฌ๋กฏ ๊ฐ์ ์ ๋๋ค. cluster_slots_ok : ํ์ฌ ๊ตฌ๋๋ ํด๋ฌ์คํฐ์ ํ ๋น๋ ์ฌ๋กฏ ๊ฐ์ ์ ๋๋ค. (ํน์ ๋ ธ๋ ๋ค์ด ์, ํด๋น ๋ ธ๋์ ์ฌ๋กฏ ๊ฐ์๊ฐ ๋น ์ง๊ฒ ๋ฉ๋๋ค.) cluster_slots_fail : ์ธ์ํ์ง ๋ชปํ๋ ์ฌ๋กฏ ๊ฐ์์ ๋๋ค. cluster_known_nodes : ํด๋ฌ์คํฐ์ ๊ตฌ์ฑ๋ ๋ชจ๋ ๋ ธ๋ ์ ์ ๋๋ค. cluster_size : ํด๋ฌ์คํฐ ๋ง์คํฐ ๋ ธ๋ ์ ์ ๋๋ค.
cluster nodes

์ด์ ์๋ฌด ๋ ธ๋๋ ์ ์ํด์ ํ ์คํธํด๋ณด์.
docker exec -it redis-node-1 redis-cli -p 6379 -c
set mykey myvalue
> OK
get mykey
> "myvalue"
์ ๋๋ค.
Type๋ณ ํน์ง
Redis - standalone
simple
no redundancy
no failover
Redis - replication
HA(High Availability)๋ฅผ ์ํ ๊ตฌ์กฐ
Read Performance(์ฝ๊ธฐ ์ฑ๋ฅ) ํฅ์
Fault tolerance
Main instance๋ ๋ณต์ ID์ offset์ ๊ฐ์ง๊ณ ์๋ค.(Replication ID, offset)
Main๊ณผ Secondary ๊ฐ ๊ฐ์ replication ID๋ฅผ ๊ฐ์ง๊ณ ์๊ณ offset์ด ๋ค๋ฅธ ๊ฒฝ์ฐ ๋๊ธฐํ๊ฐ ํ์
offset ๊ฐ์ main Redis๊ฐ deployment(๋ฐฐํฌ)๋ ๋๋ง๋ค ์ผ์ด๋๋ค
๋ ์์๋ ๋ณต์ ๊ฐ ๊ณ์๋ ์ ์๋ ์์ ์ ์ฐพ๋๋ฐ๋ ๋์์ด ๋๋ฉฐ, Secondary main instance ๊ฐ ๋๊ธฐํ๋ฅผ ํ์ธํ ์ ์๋ค.
RDB snapshot์ด๋, ๋ณต์ ๋ณธ์ ๋ณด๋ด์ด ๋๊ธฐํ๋ฅผ ํ๋ ๋ฑ Main๊ณผ secondary๋ฅผ syncํ ์์ ์ด ๋ฐ์ํ๋ค.
Replication ID: instance๊ฐ Main์ผ๋ก ์น๊ฒฉ๋๊ฑฐ๋ Main์ผ๋ก์ ๋ค์ ์ฒ์๋ถํฐ ์์ํ๊ฒ ๋๋ค๋ฉด, replication ID ๋ณ๊ฒฝ
ํด๋ผ์ด์ธํธ ์์ฒญ์ Zookeeper์ฒ๋ผ ํ์ฌ ๊ธฐ๋ณธ ์ธ์คํด์ค๊ฐ ๋ฌด์์ธ์ง๋ฅผ ์๋ ค์ค๋ค.ํด๋ผ์ธํธ๋ ์ด์ ๋ณด๋ฅผ ์ฌ์ฉํ์ฌ ๋ค์ ์ ๋ณด ์์ฒญํ๋ค.
Redis์ ๋ณต์ ๋ ๋น๋๊ธฐ์
Redis - sentinel
Main/Secondary ์ ๋๋ก ๋์ํ๋์ง ์ง์์ Monitoring
Automatic Failover
Notification : failover๋์์ ๋ Notification ๋ณด๋ผ ์ ์๋ค
๊ณผ๋ฐ ์ ์ด์์ sentinel์ด Master ์ฅ์ ๋ฅผ ๊ฐ์งํ๋ฉด Slave ์ค ํ๋๋ฅผ Master๋ก ์น๊ฒฉ์ํค๊ณ ๊ธฐ์กด์ Master๋ Slave๋ก ๊ฐ๋ฑ์ํจ๋ค
Slave๊ฐ ์ฌ๋ฌ๊ฐ ์์ ๊ฒฝ์ฐ Slave๊ฐ ์๋ก์ด Master๋ก๋ถํฐ ๋ฐ์ดํฐ๋ฅผ ๋ฐ์ ์ ์๋๋ก ์๋์ผ๋ก ์ฌ๊ตฌ์ฑ๋๋ค.
Quorum : ๋ช ๊ฐ์ Sentinel์ด Redis์ ์ฅ์ ๋ฐ์์ ๊ฐ์งํด์ผ ์ฅ์ ๋ผ๊ณ ํ๋ณํ๋์ง๋ฅผ ๊ฒฐ์ ํ๋ ๊ธฐ์ค ๊ฐ. redis replica์ ๊ณผ๋ฐ ์ ์ด์์ผ๋ก ์ค์ ํ๋ค.
Sentinel์ 1์ฐจ ๋ณต์ ๋ง Master ํ๋ณด์ ์ค๋ฅผ ์ ์๋ค. (๋ณต์ ์๋ฒ์ ๋ณต์ ์๋ฒ๋ ๋ถ๊ฐ๋ฅ)
1์ฐจ ๋ณต์ ์๋ฒ ์ค replica-priority ๊ฐ์ด ๊ฐ์ฅ ์์ ์๋ฒ๊ฐ ๋ง์คํฐ์ ์ ์ ๋๋ค. 0์ผ๋ก ์ค์ ํ๋ฉด master๋ก ์น๊ฒฉ ๋ถ๊ฐ๋ฅํ๊ณ ๋์ผํ ๊ฐ์ด ์์ ๋ ์์ง์์ ์ ํํ๋ค.
์์ ์ ์ด์์ ์ํด 3๊ฐ ์ด์์ sentinel์ ๋ง๋๋ ๊ฒ์ ๊ถ์ฅํ๋๋ฐ, ์๋ก ๋ฌผ๋ฆฌ์ ์ผ๋ก ์ํฅ๋ฐ์ง ์๋ ์ปดํจํฐ๋ ๊ฐ์ ๋จธ์ ์ ์ค์น๋๋ ๊ฒ์ด ์ข๋ค.
sentienl์ ๋ด๋ถ์ ์ผ๋ก redis ์ Pub/Sub ๊ธฐ๋ฅ์ ์ฌ์ฉํด์ ์๋ก ์ ๋ณด๋ฅผ ์ฃผ๊ณ ๋ฐ๋๋ค.
์ผํฐ๋ + ๋ ๋์ค ๊ตฌ์กฐ์ ๋ถ์ฐ ์์คํ ์ ๋ ๋์ค๊ฐ ๋น๋๊ธฐ ๋ณต์ ๋ฅผ ์ฌ์ฉํ๊ธฐ ๋๋ฌธ์ ์ฅ์ ๊ฐ ๋ฐ์ํ๋ ๋์ ์ผ๋ ๋ด์ฉ๋ค์ด ์ ์ง๋จ์ ๋ณด์ฅํ ์ ์๋ค.
Sentinel์ Redis์ ๋์ผํ Node์ ๊ตฌ์ฑํด๋ ๋๊ณ , ๋ณ๋๋ก ๊ตฌ์ฑํด๋ ๋๋ค.
ํด๋ผ์ด์ธํธ๋ ๋ ๋์ค Main์ ์ฃผ์๋ฅผ ์์๋ด๊ธฐ ์ํด ์ผํฐ๋์ ์ฐ๊ฒฐํ๋ค. sentinel์ด Main ์ฃผ์๋ฅผ ๋ณด๋ด์ค๋ค. ์ฅ์ ์กฐ์น๊ฐ ๋ฐ์ํ๋ฉด sentinel์ ์ Main์ฃผ์๋ฅผ ์๋ ค์ค๋ค.
์ฟผ๋ผ(Quorum) : ์ผํฐ๋์ด ์ฅ์ ๋ฅผ ๊ฐ์งํ๊ธฐ ์ํ ์ต์ํ์ ์ผํฐ๋ ์
number of serverQuorumavailable Fail1
1
0
2
2
0
3
2
1
4
3
1
4
3
1
5
3
2
5๊ฐ์ ์๋ฒ๊ฐ ๋๋ฉด 2๊ฐ๊ฐ failํด๋ ์๋ํ๋ค. ๊ทธ๋ฌ๋ฏ๋ก 5๊ฐ๋ฅผ ์ถ์ฒํ๋ค.
failover ๊ฐ์ง ๋ฐฉ๋ฒ
SDOWN : Subjectively down(์ฃผ๊ด์ ๋ค์ด) sentinel์์ ์ฃผ๊ธฐ์ ์ผ๋ก Master์๊ฒ ๋ณด๋ด๋ PING๊ณผ INFO ๋ช ๋ น์ ์๋ต์ด 3์ด ๋์ ์ค์ง ์์ผ๋ฉด ์ฃผ๊ด์ ๋ค์ด์ผ๋ก ์ธ์ง ์ผํฐ๋ ํ ๋์์ ํ๋จํ ๊ฒ์ผ๋ก, ์ฃผ๊ด์ ๋ค์ด๋ง์ผ๋ก๋ ์ฅ์ ์กฐ์น๋ฅผ ์งํํ์ง ์๋๋ค.
ODOWN : Objectively down(๊ฐ๊ด์ ๋ค์ด) ์ค์ ํ quorum ์ด์์ sentinel์์ ํด๋น Master๊ฐ ๋ค์ด๋์๋ค๊ณ ์ธ์งํ๋ฉด ๊ฐ๊ด์ ๋ค์ด์ผ๋ก ์ธ์ ํ๊ณ ์ฅ์ ์กฐ์น๋ฅผ ์งํํฉ๋๋ค.
redis-cluster
Automatic Failover
sharding
main์ด ์ฃฝ์ ๊ฒฝ์ฐ Secondary์ค ํ๋๊ฐ main๋ก ์น๊ฒฉ๋๋ค โ ์ค๋จ์๋ ์๋น์ค ์ ๊ณต
gossip Protocol : ๊ฐ Redis๋ ๋ค๋ฅธ Redis๋ค๊ณผ ์ง์ ์ฐ๊ฒฐํ์ฌ ์ํ ์ ๋ณด๋ฅผ ํต์
๊ธฐ์กด main์ด ๋ค์ ์ด์๋๋ฉด Secondary๊ฐ ๋๋ค
Multi-Main, Multi-Secondary ๊ตฌ์กฐ
๋ ธ๋๋ฅผ ์ถ๊ฐ/์ญ์ ํ ๋ ์ด์ ์ค๋จ ์์ด Hash slot์ ์ฌ๊ตฌ์ฑํ ์ ์๋ค
๊ณผ๋ฐ์ ์ด์์ ๋ ธ๋๊ฐ fail๋๋ฉด cluster๊ฐ ๋ง๊ฐ์ง๋ค
data ์ ํฉ์ฑ์ด ๋ง์ง์์ผ๋ฉด Master์ Data๋ฅผ ๊ธฐ์ค์ผ๋ก ์ ํฉ์ฑ์ ๋ง์ถ๋ค.
cluster redis๋ 2๊ฐ์ ํฌํธ๊ฐ ํ์ํ๋ค (ํด๋ผ์ด์ธํธ๋ฅผ ์ํ ํฌํธ, ๋ ธ๋ ๊ฐ ํต์ ๋ฒ์ค ํฌํธ)
ํด๋ผ์ด์ธํธ๊ฐ redis์ ๋ฐ์ดํฐ๋ฅผ ์์ฒญํ์ ๋, ์ฌ๋ฐ๋ฅด์ง ์์ master node์ ์์ฒญํ๋ฉด ํด๋น ๋ฐ์ดํฐ๊ฐ ์ ์ฅ๋ ์์น๋ฅผ ์๋ ค์ฃผ๊ณ client์๊ฒ ์๋ ค์ฃผ๊ณ client๋ ์ ๋๋ก ๋ ์ฃผ์์ ๋ค์ ์์ฒญํ๋ค
16K hashslot์ ์ด์ฉํ์ฌ ๋ฐ์ดํฐ๊ฐ cluster ์ฌ์ด์ ์ ์ ํ ๋ถ๋ฐฐ๋ ์ ์๋๋ก ๋๋๋ค.
์์์ฑ
RDB Files
Snapshot
Snapshot ์ดํ ๋ฐ์ดํฐ๋ ์์ค
AOF ๋ณด๋ค๋ฉ๋ชจ๋ฆฌ์ ๋ก๋๋๋ ์๋ ๋น ๋ฅด๋ค.
AOF (Append Only File)
์๋ฒ ์์ ์, ๋ค์ ์ฌ์๋ ์๋ฒ๊ฐ ์์ ํ๋ ๋ชจ๋ ์ฐ๊ธฐ ์์ ์ ๊ธฐ๋กํ์ฌ ์๋ณธ ๋ฐ์ดํฐ ์ธํธ๋ฅผ ์ฌ๊ตฌ์ฑํ๋ค.
์์ ์ด ๋ฐ์ํ๋ฉด, ๋ก๊ทธ์ ๋ฒํผ๋ง๋๋ค.
์์ถ๋์ง ์์ RDB(Redis DataBase)๋ณด๋ค ํจ์ฌ ๋ ๋ง์ ๋์คํฌ๋ฅผ ์ฌ์ฉํ ์ ์๋ค
์๋ฒ ์ฌ์์์์ ๊ธฐ์กด๋ฐ์ดํฐ ๋ณด๊ด์ด ํ์ํ๊ฒฝ์ฐ์ ์ข์๊ฑฐ๊ฐ๋ค. replication์ด๋ sentinel์ ์ค์ ํ๊ฒฝ์ฐ ์ฌ๋ถํ ํ ์๋ ๋ณต์ ์ผ์ด๋์ ํ์์์.
Kubernetes ์์ ๋ฐฐํฌ
์ด์ kubernetes์์ ๋ฐฐํฌํด๋ณด์.
argocd๋ฅผ ์ฌ์ฉํ๋ฏ๋ก subchart๋ฅผ ๋ง๋ค์.
mkdir redis-helm
cd redis-helm
vi Chart.yaml
apiVersion: v2
name: redis
type: application
version: 1.0.0
appVersion: '1.0.0'
dependencies:
- name: redis
version: '17.1.4'
repository: https://charts.bitnami.com/bitnami
helm chart versin์ ์ ํ์ ์ ์ด ์ค๋๋ค.
vi values.yaml
redis:
image:
registry: docker.io
repository: bitnami/redis
tag: 7.2
architecture: replication
auth:
enabled: true
sentinel: true
password: 'xxxx'
commonConfiguration: |-
# Enable AOF https://redis.io/topics/persistence#append-only-file
appendonly yes
# Disable RDB persistence, AOF persistence already enabled.
save ""
existingConfigmap: ''
master:
count: 1
persistence:
enabled: true
replica:
replicaCount: 3
persistence:
enabled: true
sentinel:
enabled: true
image:
registry: docker.io
repository: bitnami/redis-sentinel
tag: 7.2
quorum: 2
metrics:
enabled: true
argocd๋ก ๋ฐฐํฌํ์.
git add --all && git commit -am "update" && git push
vi add-redis-helm.yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: redis
namespace: argocd
spec:
destination:
name: ''
namespace: web
server: 'https://kubernetes.default.svc'
source:
path: apps/redis-heml
repoURL: 'https://github.com/bbbb/ccc.git'
targetRevision: HEAD
project: default
replica๊ฐฏ์๋งํฐ pod๊ฐ ์์ฑ์ด ๋ฉ๋๋ค ๊ทธ๋ฆฌ๊ณ ์ด pod์๋ redis์ sentinel์ด sidecar๋ก ์์ฑ๋ฉ๋๋ค.
replica๊ฐ 3๊ฐ๋ฉด 3๊ฐ์ pod๊ฐ ์์ฑ๋ฉ๋๋ค. ๊ทธ๋ฆฌ๊ณ ๊ทธ์ค ํ๋๊ฐ master๊ฐ ๋๊ณ ๋๋จธ์ง 2๊ฐ๋ slave๊ฐ ๋ฉ๋๋ค.
์ ์ฒด pod์ sentinel๋ ๋์์ ์ค์น๋๋ฏ๋ก quorum์ 3๋ก ์ค์ ํ๋ฉด (2๊ฐ์ pod๊ฐ ๋ง๊ฐ์ ธ๋ sentinel ํด๋ฌ์คํฐ ์ ์ง)ํ๋ ค๋ฉด 5๊ฐ์ replica๋ฅผ ์ค์ ํด์ผํฉ๋๋ค.
์ถ๊ฐ ์ค์ ์ ๋ค์์์ ํ์ธํ์ธ์.
https://artifacthub.io/packages/helm/bitnami/redis
์ฐธ๊ณ
์ฌ๋ฌ๊ฐ์ง ํ๊ฒฝ๋ณ์ ์ํ : https://cloudinfrastructureservices.co.uk/run-redis-with-docker-compose/
์ด์ ๊ทธ๋ฆผ : https://architecturenotes.co/redis/
Last updated
Was this helpful?