HBmonitor/utils
2020-08-17 19:55:22 +02:00
..
hbmon.service Add files via upload 2019-09-17 21:24:12 +02:00
lastheard Update lastheard 2019-09-14 21:13:22 +02:00
log.php Update log.php 2020-08-17 19:55:22 +02:00
Readme.md Update Readme.md 2020-08-17 07:18:54 +02:00

Requirements a webserver with activated PHP (apache, nginx or whatever) PHP 7.x is ok

Extension of hbmonitor we log if a call is ended (I think its better as start) Please check permissions for writing the logfile in target folder !

I recommed to shorten the lastheard.log from time to time (I cut every day to 150 lines, longer values maybe extend the load time and parsing) with this script lastheard:

#!/bin/bash
mv /opt/HBmonitor/log/lastheard.log /opt/HBmonitor/log/lastheard.log.save
/usr/bin/tail -150 /opt/HBmonitor/log/lastheard.log.save > /opt/HBmonitor/log/lastheard.log
mv /opt/HBmonitor/log/lastheard.log /opt/HBmonitor/log/lastheard.log.save
/usr/bin/tail -150 /opt/HBmonitor/log/lastheard.log.save > /opt/HBmonitor/log/lastheard.log

Call this script with crontab for everyday use.

Put this file in /etc/cron.daily/ and add attribute: chmod +x /etc/cron.daily/lastheard

Call the website with http://YOUR_HOST/log.php it runs with a refresh/reload time of 30sec, change the script for other timeset.

Thank you, Heiko DL1BZ, who shared the lastheard code.

73 Waldek SP2ONG