Application for traffic monitoring in OLTs (Optical Line Terminals) using SNMP (Simple Network Management Protocol) for traffic analysis by OLT, port, clients, or geographical location.
graph LR
X[(OLT 1)] -- SNMP --> M(Measurement*)
Y[(OLT 2)] -- SNMP --> M(Measurement*)
Z[(OLT n)] -- SNMP --> M(Measurement*)
M --> D[(Database)]
D --> S(Smart*)
D --> R(Report*)
D --> T(Traffic*)
T --> A(Auth*)
R --> A(Auth*)
S --> A(Auth*)
A --> C(Client)
This diagram shows how measurement data from various OLTs is collected and stored in a database, then used to generate traffic and reports, which are accessible to clients through an authentication system. Below are the components and their interactions:
- OLT (Optical Line Terminal):
- OLT's: Represent different OLTs sending measurement data.
- SNMP Protocol: Measurement data is transmitted from the OLTs to the measurement node using the SNMP (Simple Network Management Protocol).
- Measurement: Node representing the module that receives and centralizes the measurements sent by the OLTs.
- Database: Node where the module received measurements are stored for further processing.
- Data Processing:
- Traffic: Node representing the module the traffic generated from the stored data.
- Report: Node representing the module the generation of reports based on the stored data.
- Smart: Node representing the module that processing of intelligent data from stored information.
- Authentication:
- Auth: Node representing the module that controls access to both the traffic and the reports, ensuring that only authenticated users can access the information.
- Client: Node representing the end client who accesses the authenticated data.
- Go: concurrent, compiled, efficient, simple and scalable language
- Python: interpreted language, versatile, easy, powerful and popular
- Astro: framework for creating fast and efficient websites
- PostgreSQL: robust, flexible and free relational database
- Ollama: platform for running and customizing language models
- Docker: is an efficient and portable application container platform
To initialize the application as a developer, follow these steps:
# clone this repository
git clone https://github.com/metalpoch/olt-blueprint.git
-- create the database
CREATE DATABASE olt;
create the configuration file called config.json
in the root of the project
{
"db_uri": "postgresql://xxx:yyy@zzz:5432/olt",
"cache_uri": "redis://xxx:yyy@zzz:6379",
"secret_key": "supersecrettoken",
"telegram_bot_token_id": "xx:yyy-zzz",
"telegram_chat_id": "xxx"
}
run any module
# run auth module
make dev-auth
# run traffic module
make dev-traffic
# run report module
make dev-report
# run traffic module
make dev-traffic
# run the CLI measurement module
CONFIG_JSON=./config.json go run ./measurement/cmd/main.go