A TCP monitor in java
This is a simple Monitor in Java. It pings the monitor and updates the status to a mysql database. you can retrieve the statuses from that database in your website the way you like. Further documentation follows.
Java 11 or later required. (JDK + mysql or mariadb connector when compiling from source) A MySQL/mariadb server
- create a database and use
db.sql
to create the table. - modify monitor.cnf to match your connection details
- add a mysql/mariadb connector to the modulepath
- run main/startup.java
- Download & extract the pre-compiled jarfile (in a .tar.gz archive with monitor.cnf and db.sql)
- create a database and populate with db.sql
- edit the monitor.cnf file with the connection details
- run the jarfile with
java -jar monitor-mariadb-1.0.jar
(mariadb) orjava -jar monitor-mysql-1.0.jar
(mysql)
you add monitors by adding rows to the mysql database. Below is an example:
-- 'nuc' is the name, '10.0.0.27' is the ip
insert into monitor.monitor(name,ip) values ('nuc','10.0.0.27');
just select the statuc collumn:
select name, status from monitor;
domain package api: https://k1l0b1t.github.io/monitor/
Licence: GPLv3
- E-mail notifications (optional, will use SMTP)
- SQLite Storage
- Interactive installer (will populate database for you and write config file.