Giter Club home page Giter Club logo

py-psql-speed-checker's Introduction

Wanted to keep track of my ISP internet speeds throughout the day, as I've noticed downtimes when working from home for some time.

This script checks for DL speeds and uploads the data (timestamp, dl, up speeds) into a local postgresql server.

Script runs off of an example crontab: * * * * * cd /path/to/speedtest-checker && venv/bin/python main.py

The data is then graphed in Grafana, which is also running on the RPI connected to the router.

The config.ini1 is an example one, rename it to config.ini and update it to match your local DB settings for it to work.

Example speeds taken from Grafana:
Grafana graph

PSQL DB example:

patchbox_data=> select * from speedtests limit 10;
        date         | download_speed | upload_speed
---------------------+----------------+--------------
 2020-10-26 16:40:02 |          23.13 |          2.2
 2020-10-26 16:41:02 |           16.7 |         2.61
 2020-10-26 16:42:02 |          20.33 |         1.89
 2020-10-26 16:43:02 |          16.17 |         2.61
 2020-10-26 16:44:02 |          25.83 |         2.21
 2020-10-26 16:45:02 |          15.43 |          2.6
 2020-10-26 16:46:02 |          22.08 |         2.26
 2020-10-26 16:47:02 |          12.64 |         2.15
 2020-10-26 16:48:03 |          20.51 |         2.42
 2020-10-26 16:49:02 |          17.03 |          2.5
(10 rows)

py-psql-speed-checker's People

Contributors

punksnotbread avatar

Watchers

 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.