From 5f7e9e34f4860908bfb6e41be37a9b0c3164eab9 Mon Sep 17 00:00:00 2001 From: belliash Date: Thu, 26 Apr 2018 19:04:32 +0200 Subject: [PATCH] update readme --- README.md | 40 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 37 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index b3b3719..1bde77f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ -# wanmonitor -WAN Monitor & Failover Connection Manager +# WAN Monitor & Failover Connection Manager + + +# Configuration All configuration is done in /etc/config/wanmonitor file. Options available: * check_host - IP address of remote host used to check Internet connectivity @@ -8,4 +10,36 @@ All configuration is done in /etc/config/wanmonitor file. Options available: * wan_primary - Primary WAN interface name to use * wan_secondary - Secondary WAN interface name to use -In order to work this software correctly it is recommended to disable default routes on all WAN interfaces. +What is more it can make a use of WAN routes metrics set in /etc/config/network, +thus allowing to use PPPoE to work correctly. When PPPoE connection is established, +it automatically adds a route with proper (higher) priority and this connection +is being used as default. After a while, when WanMonitor notices primary connection +is again available, it removes a route for secondary WAN connection (eg. in order to +save mobile traffic). + + +# Sample configuration + +/etc/config/network: +
config interface 'wan1'
+        option ifname 'eth0'
+        option metric '0'
+        option proto 'pppoe'
+        option username 'login'
+        option password 'password'
+        option service 'PPPoE'
+
+config interface 'wan2'
+        option ifname 'eth1'
+        option proto 'dhcp'
+        option metric '5'
+        option defaultroute '0'
+        option service 'LTE'
+ +/etc/config/wanmonitor: +
config wanmonitor
+        option check_host '8.8.8.8'
+        option interval '5'
+        option sleep '5'
+        option wan_primary 'wan1'
+        option wan_secondary 'wan2'