跳至主要內容

GPU环境-NVIDIA-smi

pptg大约 1 分钟

1. NVIDIA驱动版本

# 检测可用驱动
# driver   : nvidia-driver-550 - distro non-free recommended
ubuntu-drivers devices

# 下载驱动
# 选择带recommended的版本
sudo apt update
sudo apt install nvidia-driver-550

# 重启
sudo reboot

# NVIDIA System Management Interface工具
nvidia-smi

2. NVIDIA-smi

NVIDIA-smi
NVIDIA-smi

上述关键指标如下

  • GPU:GPU编号(多卡时显示0,1,2...)

  • Name:GPU型号(此处是NVIDIA A10,服务器/工作站级显卡)

  • Persistence-M:持久模式(Off=关闭,开启可减少初始化延迟)

  • Bus-Id:GPU硬件总线地址(用于定位物理设备)

  • Disp.A:是否连接显示器(Off=未接显示器)

  • Volatile Uncorr. ECC:ECC内存错误计数(0=无错误)

  • Fan:风扇转速百分比(0%=可能自动停转或涡轮散热)

  • Temp:GPU核心温度(62°C,安全范围通常<85°C)

  • Perf:性能状态(P0=最高性能模式,P1-P12为节能状态)

  • Pwr:Usage/Cap:功耗(69W / 150W,当前功耗/最大功耗)

  • Memory-Usage:显存使用(21429MiB / 23028MiB ≈ 21GB/22.5GB)

  • GPU-Util:GPU计算核心利用率(0%=空闲)

  • Compute M.:计算模式(Default=允许多进程共享GPU)

  • PID 2846013:进程ID

  • Type C:计算进程(非图形渲染)

  • Process name:python3(通常是深度学习/科学计算任务)

  • GPU Memory Usage:该进程占用21420MiB显存(占总显存的93%)