From 1163649c960d0a9cf975a2bdd31c7eb7f76458c6 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Tue, 12 Jul 2016 14:18:25 +0300 Subject: [PATCH] Add a makefile and readme --- Makefile | 2 ++ Readme.txt | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 Makefile create mode 100644 Readme.txt diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..400f13b --- /dev/null +++ b/Makefile @@ -0,0 +1,2 @@ +netmon: main.c + $(CC) main.c -o netmon -lpcap -std=c99 diff --git a/Readme.txt b/Readme.txt new file mode 100644 index 0000000..0e4c4b4 --- /dev/null +++ b/Readme.txt @@ -0,0 +1,32 @@ +netmon - a simple network connectivity monitor +Copyright © 2008-2016 Mikko Rasa, Mikkosoft Productions + +Netmon keeps track of the machine's network connection status. It can +passively monitor network traffic with libpcap or actively ping a target +machine. It can also run an external command when the network goes down, +for example to reset an ADSL modem in an effort to bring the connection +back up. + +Command-line options: + -f + Run in foreground (by default netmon daemonizes itself) + + -v + Be more verbose + + -p HOST + Send a ping to HOST every second + + -s NUM + Reports packet loss statistics every NUM seconds (default 1800, only + works if pinging is enabled) + + -i NAME + Monitor packets on interface NAME + + -c CMD + Run CMD if the connection goes down + + -t NUM[,NUM] + Sets the delay and interval (in seconds) for running the trigger + command (default 60 and 600) -- 2.45.2