Git Product home page Git Product logo

netgwm's Introduction

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.

netgwm's People

Contributors

shurup avatar vladimir-ipatov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.