HBMonv2/sysinfo/Readme.txt

78 lines
1.5 KiB
Plaintext
Raw Normal View History

2021-01-06 13:24:27 +01:00
Monitoring system
Install package:
sudo apt-get install rrdtool -y
2021-01-06 13:29:29 +01:00
Change scripts to execute:
2021-01-06 13:24:27 +01:00
2021-01-06 13:29:29 +01:00
chmod +x /opt/HBMonv2/sysinfo/cpu.sh
chmod +x /opt/HBMonv2/sysinfo/grap.sh
chmod +x /opt/HBMonv2/sysinfo/rrd-db.sh
Run script create database
2021-01-06 13:24:27 +01:00
2021-01-06 13:29:29 +01:00
/opt/HBMonv2/sysinfo/rrd-db.sh
2021-01-06 13:24:27 +01:00
2021-01-06 13:29:29 +01:00
Edit file
2021-01-06 13:24:27 +01:00
/opt/HBMonv2/sysinfo/graph.sh
Setup temperature depend of your computer
2021-02-21 15:57:23 +01:00
On raspberry pi or PC you can use sensors package to get temperature CPU
2021-01-06 13:24:27 +01:00
2021-02-21 15:57:23 +01:00
If not avilable set:
tempcpu=false
For VPS set:
tempcpu=false
2021-01-06 13:24:27 +01:00
Optional display network traffic
===============================
2021-02-21 08:15:53 +01:00
Instal package mrtg and snmp
2021-01-06 13:24:27 +01:00
2021-02-21 08:15:53 +01:00
sudo apt-get install mrtg snmp snmpd -y
2021-01-06 13:24:27 +01:00
Edit file
/etc/snmp/snmpd.conf
and set as below
rocommunity public localhost
#rocommunity public default -V systemonly
#rocommunity6 public default -V systemonly
Restart snmpd
systemctl restart snmpd
Create config for mrtg:
2021-02-21 15:57:23 +01:00
cfgmaker -zero-speed=5000 public@localhost > /etc/mrtg.cfg
2021-01-06 13:24:27 +01:00
2021-02-21 15:57:23 +01:00
Please edit /etc/mrtg.cfg and change diretory to store image change WorkDir to:
2021-01-06 13:24:27 +01:00
2021-02-21 08:25:54 +01:00
WorkDir:/opt/HBMonv2/img/mrtg
2021-01-06 13:24:27 +01:00
2021-02-21 15:57:23 +01:00
put below lines in section your netrwork card
2021-02-21 08:23:33 +01:00
and replace localhost_2 to your name network card as result cfgmaker generate in mrtg.cfg
2021-01-06 13:24:27 +01:00
XSize[localhost_2]: 600
Options[localhost_2]: growright, bits
Unscaled[localhost_2]: d
2021-02-21 08:54:19 +01:00
Tune MaxBytes value for exmample 50000 to set vertical scale graph
2021-01-06 13:24:27 +01:00
2021-01-06 13:29:29 +01:00
Please edit template file where is which graph you are want display /opt/HBMonv2/templates/sysinfo_template.html