flant / netgwm Goto Github PK
View Code? Open in Web Editor NEWNetGWM (Network Gateway Manager)
NetGWM (Network Gateway Manager)
NetGWM stands for Network Gateway Manager (http://flant.ru/projects/netgwm) NetGWM is a tool on Python used for automatically switching network gateway when your current ISP goes offline. How to deploy NetGWM? 0) Install prerequisites: - iproute2 - conntrack (http://conntrack-tools.netfilter.org/) - python-yaml (http://pyyaml.org/) 1) Execute "make install". It will create /usr/lib/netgwm with netgwm.py and /etc/netgwm with configs and samples. 2) Using simple YAML configuration file (samples/netgwm.yml), you should define your gateways (by IPs or devices) and their priorities. In /etc/default/netgwm, you can change the period of checking gateways (by default, every 60 sec). 3) Add new routing table named "netgwm_check" to your iproute configuration file (/etc/iproute2/rt_tables; there is an example at samples/rt_tables.sample). It's done automatically in the Debian package. 4) Use /etc/init.d/netgwm to launch NetGWM. That's all! NetGWM will ping given addresses through your current gateway to check your Internet connection. If all of these addresses are down, NetGWM will switch your current gateway to a working one (with a highest priority). Other features: * A gateway is considered as working only after N seconds of successfull checks. This setting ("min_uptime") can be configured in netgwm.yml. * When a gateway with a higher priority goes back online NetGWM will automatically switch to it from the current one. * Every time NetGWM switches a network gateway, it will execute all the scripts placed in /etc/netgwm/post-replace.d (for more details, please have a look at samples/post-replace.d/script.sh). * NetGWM can maintain the full list of gateways statuses continually for your special needs (e.g. to be used in other software). This data is stored in /var/run/netgwm/gwstore.yml. This setting ("check_all_gateways") can be enabled in netgwm.yml.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.