Skip to content

Commit 7588d27

Browse files
author
Hao Zhi
committed
modify readme of monitor
1 parent 4665a02 commit 7588d27

File tree

3 files changed

+42
-10
lines changed

3 files changed

+42
-10
lines changed

monitor/README.md

Lines changed: 0 additions & 10 deletions
This file was deleted.

script/monitor/README.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# GPU 监控脚本使用说明
2+
3+
该脚本用于定时采集指定 GPU 的温度和图形频率,支持高温/降频报警,并可将结果记录到日志文件中,适用于性能测试与运行状态监控。
4+
5+
---
6+
7+
## ✅ 脚本功能
8+
9+
- 支持指定 GPU 设备编号
10+
- 可自定义刷新时间间隔和记录次数
11+
- 实时记录温度(℃)与图形频率(MHz)
12+
- 高温(>95°C)或降频(<1750MHz)触发报警(门限可根据实际设备调整)
13+
- 监控结束后自动统计报警次数
14+
- 默认输出日志文件为:`gpu_monitor_log.txt`
15+
16+
---
17+
18+
## ⚙️ 参数说明
19+
20+
| 参数 | 含义 | 示例 |
21+
|------|--------------------|-----------------|
22+
| `-d` | GPU 设备编号 | `-d 0` |
23+
| `-i` | 刷新时间(单位:秒)| `-i 1` |
24+
| `-n` | 记录次数(默认无限)| `-n 10` |
25+
26+
> 如未指定 `-n`,脚本将持续运行,直到手动停止。
27+
28+
---
29+
30+
## 🚀 使用示例
31+
32+
### ✅ 前台运行
33+
34+
```bash
35+
./monitor_gpu.sh -d 0 -i 1 -n 10
36+
```
37+
38+
### ✅ 后台运行
39+
```
40+
nohup ./monitor_gpu.sh -d 0 -i 1 -n 100 > /dev/null 2>&1 &
41+
tail -f gpu_monitor_log.txt
42+
```

0 commit comments

Comments
 (0)