sábado, 8 de abril de 2017

Get CPU/GPU Temp in linux

Create and ejecute this bash

#!/bin/bash
cpu=$(</sys/class/thermal/thermal_zone0/temp)
echo "$(date) @ $(hostname)"
echo "-------------------------------------------"
echo "GPU => $(/opt/vc/bin/vcgencmd measure_temp)"
echo "CPU => $((cpu/1000))'C"

No hay comentarios:

Publicar un comentario