Skip to content

[SOU-650] 디스크 모니터링 로직 개선 및 임계값 이중화#265

Merged
bum0w0 merged 1 commit into
developfrom
fix/SOU-650-disk-alert
Jun 12, 2026
Merged

[SOU-650] 디스크 모니터링 로직 개선 및 임계값 이중화#265
bum0w0 merged 1 commit into
developfrom
fix/SOU-650-disk-alert

Conversation

@bum0w0

@bum0w0 bum0w0 commented Jun 12, 2026

Copy link
Copy Markdown
Member
  • 80% 초과 후 100%까지 추가 알림이 없던 단일 임계값 구조 개선
  • 경고 임계값 90%, 긴급 임계값 95%로 이중 단계 알림 구성
  • 디스크 100% 시 mktemp 실패로 스크립트가 종료되던 문제 수정

Summary by CodeRabbit

릴리스 노트

  • 개선사항
    • 디스크 사용률이 95%를 초과할 경우 긴급 알림이 전송됩니다.
    • 디스크 경고 알림이 보다 명확하게 개선되어 90% 초과 상황을 명시적으로 알립니다.
    • 디스크 상태 추적 및 모니터링이 강화되었습니다.

- 80% 초과 후 100%까지 추가 알림이 없던 단일 임계값 구조 개선
- 경고 임계값 90%, 긴급 임계값 95%로 이중 단계 알림 구성
- 디스크 100% 시 mktemp 실패로 스크립트가 종료되던 문제 수정
@coderabbitai

coderabbitai Bot commented Jun 12, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: ac4a2d18-dcde-4289-a0d2-81099c1b35db

📥 Commits

Reviewing files that changed from the base of the PR and between 49a23ca and f476b46.

📒 Files selected for processing (2)
  • deploy/shared/discord-notify.sh
  • deploy/shared/system-monitor.sh

Walkthrough

디스크 사용률 95% 초과 시 Discord로 긴급 알림을 전송하는 notify_disk_critical 함수가 추가되고, 기존 경고 알림(90%)의 설명이 구체화되었습니다. 모니터 시스템에서 임계값과 상태 플래그를 관리하여 중복 알림을 방지합니다.

Changes

디스크 임계 알림 시스템 확장

Layer / File(s) Summary
Discord 임계 알림 함수 및 경고 설명 개선
deploy/shared/discord-notify.sh
notify_disk_critical 함수가 추가되어 디스크 95% 초과 시 @here 메시션과 함께 빨간색 Discord 임베드를 전송합니다. notify_disk_warning의 설명 문구도 "임계값을 초과했습니다"에서 "디스크 사용량이 90%를 초과했습니다"로 구체화됩니다.
모니터 임계값 상수 및 초기 상태 설정
deploy/shared/system-monitor.sh
디스크 임계값이 90%로 상향 조정되고, 새로운 임계값 DISK_CRITICAL_THRESHOLD=95가 추가됩니다. 상태 파일 초기화 시 DISK_CRITICAL_SENT 플래그가 포함되어 false로 초기화됩니다.
임계 알림 판정 및 상태 파일 갱신
deploy/shared/system-monitor.sh
디스크 사용률이 95% 이상이면 DISK_CRITICAL_SENT 상태에 따라 notify_disk_critical을 호출하고(1회만), 95% 미만으로 내려가면 플래그를 초기화합니다. 상태 파일 갱신 시 mktemp 실패를 처리하고 DISK_CRITICAL_SENT를 저장합니다.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

  • souzip/souzip-api#222: 동일하게 deploy/shared/discord-notify.sh의 디스크 알림 로직을 수정하며, notify_disk_warning 함수의 파라미터 및 페이로드를 환경 인식형으로 리팩토링합니다.
  • souzip/souzip-api#231: 같은 system-monitor.sh에서 .system-status 파일을 mktempmv로 작성하고, 디스크 알림 함수 호출 인자를 재정렬하는 등 디스크 알림 및 상태 기록 부분을 함께 수정합니다.

Suggested labels

feat

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/SOU-650-disk-alert

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@bum0w0 bum0w0 merged commit 883e7ce into develop Jun 12, 2026
1 of 2 checks passed
@Develop-KIM Develop-KIM deleted the fix/SOU-650-disk-alert branch June 13, 2026 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant