CPU Stress
Inhaltsverzeichnis
CPU Stress
Benötigt lm-sensors
lm-sensors installieren, sensors-detect alles etwas yes und in Module eintragen lassen, reboot.
CPU Stress Test
Manchmal braucht man einfach nur etwas Wärme
Das erste Zeichen darf kein Leerzeichen sein, wiki bedingt.
#!/bin/bash
#
# Scriptname: cpustress
#
# CPU stress to turn the cpu temperature to max normal, if the computer is not dusty!
# So you can determine the values of alarm settings for other scripts stuffs etc..
#
# Required: apt install lm-sensors
#
# Installation:
#
# /usr/local/bin/cpustress
# chmod 700 /usr/local/bin/cpustress
#
for i in 1 2 3 4; do while : ; do : ; done & export cpustress_pid=$(printf "$cpustress_pid\n$!"); done
while [ -z "$a" ] ;do
clear
uptime
echo "---------------------------------------------------------------------"
sensors | grep "Core"
# check your sensors output, maybe you need
# sensors | grep "temp"
echo
echo " For quit: any Key"
read -t 0.5 -n 1 a
done
kill $cpustress_pid > /dev/null
echo
exit 0So sieht der sich wiederholende Output aus:
11:05:30 up 14 min, 3 users, load average: 2.58, 1.03, 0.70 --------------------------------------------------------------------- Core 0: +69.0°C (high = +74.0°C, crit = +100.0°C) Core 1: +58.0°C (high = +74.0°C, crit = +100.0°C) Core 2: +65.0°C (high = +74.0°C, crit = +100.0°C) Core 3: +70.0°C (high = +74.0°C, crit = +100.0°C) For quit: any Key b root@debian:~$
