현상
- Redis 에서 "Used Memory RSS" 가 지속적으로 증가
- RSS(Resident Set Size) : 해당 프로세스에 할당되고 RAM에있는 메모리 양
- Maxmemory 부근에서 key 증가와 삭제가 발생 확인
증상
- 메모리 단편화(memory fragmentation) 발생
- Swap도 발생.
- Swap: 운영체제의 가상메모리
해소
- 단편화 이슈 : 온라인 상황에서 activedefrag 사용
- Swap 이슈 : 프로세스 재시작
- stop replicas
- drop cache
- swap off & swap on
- start replicas
- failover
참고
- 메모리 단편화란? : https://cocoon1787.tistory.com/859
- Swap 이란? https://minimilab.tistory.com/65
- activedefrag : https://kimdubi.github.io/redis/redis_activedefrag/
- 메모리 운영기법 및 주의점 : https://ssoco.tistory.com/16
'개발' 카테고리의 다른 글
Universal Links & App Links (0) | 2023.07.23 |
---|---|
Exponential Backoff (0) | 2022.12.22 |
Android WebView Debugging (0) | 2021.07.23 |
Redux 사이드 이펙트 라이브러리 비교 (0) | 2020.12.15 |
Cookie recipes - SameSite and beyond (0) | 2020.08.29 |