2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 06:39:11 +00:00
fhem-mirror/fhem/www/gplot/SM_CPUStat.gplot
2022-03-07 08:45:37 +00:00

51 lines
1.5 KiB
Plaintext

# SYSMON
#
# Anzeige: system cpu auslastung
#
# Daten: user nice system idle iowait irq softirq
# Beispiel aus dem Logfile:
# 2014-01-23_23:37:59 sysmon stat_cpu_percent: 32.17 0.00 18.53 37.72 0.15 0.04 11.38
#
#
set readonly
set terminal png transparent size <SIZE> crop
set output '<OUT>.png'
set xdata time
set timefmt "%Y-%m-%d_%H:%M:%S"
set xlabel " "
set ytics
set yrange [0:100]
set y2range [0:100]
set title '<L1>'
set grid xtics y2tics
set y2label "Auslastung %"
#FileLog 4:stat_cpu_percent:0:$fld[3]
#FileLog 5:stat_cpu_percent:0:$fld[4]
#FileLog 6:stat_cpu_percent:0:$fld[5]
#FileLog 7:stat_cpu_percent:0:$fld[6]
#FileLog 8:stat_cpu_percent:0:$fld[7]
#FileLog 9:stat_cpu_percent:0:$fld[8]
#FileLog 10:stat_cpu_percent:0:$fld[9]
plot \
"< awk '/load avg:/ {print $1, $4}' <IN>" \
using 1:2 ls l0 axes x1y1 title 'user' lw 1.5 with lines \
"< awk '/load avg5:/ {print $1, $4}' <IN>" \
using 1:2 ls l1 axes x1y1 title 'nice' lw 1.5 with lines \
"< awk '/load avg15:/ {print $1, $4}' <IN>" \
using 1:2 ls l2 axes x1y1 title 'system' lw 1.5 with lines
"< awk '/load avg15:/ {print $1, $4}' <IN>" \
using 1:2 ls l3 axes x1y1 title 'idle' lw 1.5 with lines
"< awk '/load avg15:/ {print $1, $4}' <IN>" \
using 1:2 ls l4 axes x1y1 title 'iowait' lw 1.5 with lines
"< awk '/load avg15:/ {print $1, $4}' <IN>" \
using 1:2 ls l5 axes x1y1 title 'irq' lw 1.5 with lines
"< awk '/load avg15:/ {print $1, $4}' <IN>" \
using 1:2 ls l6 axes x1y1 title 'softirq' lw 1.5 with lines