simetnicbr / simet-ma Goto Github PK
View Code? Open in Web Editor NEWSIMET-2 Measurement Agent (linux and docker version)
License: Other
SIMET-2 Measurement Agent (linux and docker version)
License: Other
@hmh , bom dia!
Uma ideia original para este projeto é incluir no https://github.com/isptools/isptools
Por que não troca uma ideia com o @giovaneh
Status:
Em geral, outros sistemas operacionais e versões funcionam, mas com alguns problemas de integração e/ou empacotamento.
ARM 32-bits funciona perfeitamente, porém não distribuímos binários. Basta compilar diretamente do código fonte.
A visualização dos resultados das medições realizadas pelo SIMET-MA ainda não está disponível para o público em geral.
Essa issue será atualizada à medida que os diversos sistemas de visualização de resultados (mapas temáticos, portal de acesso do provedor, portal de acesso do usuário) forem disponibilizados.
Talvez seja o uso de plugins estilo NTOP, ou flows (Netflow) ou ainda MQTT, com logstash/elasticsearch pois acredito que SMNP já tá mais para aposentadoria.
Olá!
Observei hoje que o simet-ma está retornando mensagens de erro relativo a autorização(Authorization request failed), conforme log abaixo.
Segue para conhecimento e eventual correção:
Nov 10 00:26:01 localhost CRON[32284]: (root) CMD (if [ -x /opt/simet/bin/simet_geolocation.sh ] ; then /opt/simet/bin/simet_geolocation.sh >/dev/null 2>&1 || true ; fi)
Nov 10 00:26:01 localhost CRON[32285]: (nicbr-simet) CMD (if [ -x /opt/simet/bin/simet_register_ma.sh ] ; then /opt/simet/bin/simet_register_ma.sh >/dev/null ; fi)
Nov 10 00:26:01 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 00:26:02 localhost simet-ma: SIMET: view_results token updated
Nov 10 00:26:02 localhost simet-ma: SIMET: LMAP measurement agent id: be22b143-fde0-11ec-8f49-56a4322248f4
Nov 10 01:20:01 localhost simet-ma: downloaded a proposed schedule from controller
Nov 10 01:20:01 localhost simet-lmapd: proposed new SIMET schedule is invalid
Nov 10 01:20:01 localhost simet-ma: failed to download or activate schedule from controller
Nov 10 01:20:01 localhost simet-ma: SIMET schedule unchanged
Nov 10 01:20:01 localhost simet-ma: using local schedule
Nov 10 02:26:55 localhost simet-ma: geolocation: error: No valid geolocation cached data found
Nov 10 02:27:26 localhost simet-ma: geolocation: error: No valid geolocation cached data found
Nov 10 02:27:26 localhost lmapd[29211]: failed to execute action 'simet.nic.br_spoofer_ip4'
Nov 10 02:27:51 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br/collector/measure
Nov 10 02:28:39 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 02:28:39 localhost simet-ma: measurement peer: https://sp-ix-p1.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 02:28:39 localhost simet-ma: starting measurement task: TWAMP IPv4
Nov 10 02:28:55 localhost simet-ma: starting measurement task: traceroute IPv4
Nov 10 02:28:56 localhost simet-ma: starting measurement task: TWAMP IPv6
Nov 10 02:28:58 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 02:28:58 localhost simet-ma: starting measurement task: traceroute IPv6
Nov 10 02:29:28 localhost simet-ma: starting measurement task: TCPBW IPv4
Nov 10 02:29:53 localhost simet-ma: starting measurement task: TCPBW IPv6
Nov 10 02:30:23 localhost simet-ma: Task TCPBW IPv6, failed with exit code: 25
Nov 10 02:30:24 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 02:30:24 localhost simet-ma: Geolocation attempt failed.
Nov 10 02:30:24 localhost simet-ma: Waiting for background measurements to complete
Nov 10 02:30:24 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Nov 10 02:30:24 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 02:30:25 localhost simet-ma: measurement peer: https://sp-ix-p2.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 02:30:25 localhost simet-ma: starting measurement task: TWAMP 001-IPv4
Nov 10 02:30:29 localhost simet-ma: starting measurement task: TWAMP 001-IPv6
Nov 10 02:30:29 localhost simet-ma: starting measurement task: traceroute 001-IPv4
Nov 10 02:30:31 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 02:30:31 localhost simet-ma: starting measurement task: traceroute 001-IPv6
Nov 10 02:30:32 localhost simet-ma: measurement peer: https://sp-ix-p1.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 02:30:32 localhost simet-ma: starting measurement task: TWAMP 002-IPv4
Nov 10 02:30:36 localhost simet-ma: starting measurement task: traceroute 002-IPv4
Nov 10 02:30:36 localhost simet-ma: starting measurement task: TWAMP 002-IPv6
Nov 10 02:30:38 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 02:30:38 localhost simet-ma: starting measurement task: traceroute 002-IPv6
Nov 10 02:30:38 localhost simet-ma: measurement peer: https://rj-ix-p1.rj-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 02:30:38 localhost simet-ma: starting measurement task: TWAMP 003-IPv4
Nov 10 02:30:43 localhost simet-ma: starting measurement task: TWAMP 003-IPv6
Nov 10 02:30:43 localhost simet-ma: starting measurement task: traceroute 003-IPv4
Nov 10 02:30:45 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 02:30:45 localhost simet-ma: starting measurement task: traceroute 003-IPv6
Nov 10 02:32:56 localhost simet-ma: Authorization request failed at: https://ba-ix-p1.ba-ix.peers.simet.nic.br:443/server-monitor/measure-allowed
Nov 10 02:32:57 localhost simet-ma: measurement peer: https://sp-p1.sp.peers.simet.nic.br:443/server-monitor/
Nov 10 02:32:57 localhost simet-ma: starting measurement task: TWAMP 004-IPv4
Nov 10 02:33:01 localhost simet-ma: starting measurement task: traceroute 004-IPv4
Nov 10 02:33:01 localhost simet-ma: starting measurement task: TWAMP 004-IPv6
Nov 10 02:33:03 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 02:33:03 localhost simet-ma: starting measurement task: traceroute 004-IPv6
Nov 10 02:33:04 localhost simet-ma: Waiting for background measurements to complete
Nov 10 02:33:34 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Nov 10 04:26:01 localhost CRON[27322]: (root) CMD (if [ -x /opt/simet/bin/simet_geolocation.sh ] ; then /opt/simet/bin/simet_geolocation.sh >/dev/null 2>&1 || true ; fi)
Nov 10 04:26:01 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 06:25:32 localhost simet-ma: SIMET: view_results token updated
Nov 10 06:25:32 localhost simet-ma: SIMET: LMAP measurement agent id: be22b143-fde0-11ec-8f49-56a4322248f4
Nov 10 06:25:33 localhost simet-ma: downloaded a proposed schedule from controller
Nov 10 06:25:33 localhost simet-lmapd: proposed new SIMET schedule is invalid
Nov 10 06:25:33 localhost simet-ma: failed to download or activate schedule from controller
Nov 10 06:25:33 localhost simet-ma: SIMET schedule unchanged
Nov 10 06:25:33 localhost simet-ma: using local schedule
Nov 10 06:28:57 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 06:28:57 localhost simet-ma: measurement peer: https://sp-ix-p2.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 06:28:57 localhost simet-ma: starting measurement task: TWAMP IPv4
Nov 10 06:29:13 localhost simet-ma: starting measurement task: traceroute IPv4
Nov 10 06:29:14 localhost simet-ma: starting measurement task: TWAMP IPv6
Nov 10 06:29:16 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 06:29:16 localhost simet-ma: starting measurement task: traceroute IPv6
Nov 10 06:29:46 localhost simet-ma: starting measurement task: TCPBW IPv4
Nov 10 06:30:12 localhost simet-ma: starting measurement task: TCPBW IPv6
Nov 10 06:30:42 localhost simet-ma: Task TCPBW IPv6, failed with exit code: 25
Nov 10 06:30:42 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 06:30:42 localhost simet-ma: Geolocation attempt failed.
Nov 10 06:30:42 localhost simet-ma: Waiting for background measurements to complete
Nov 10 06:30:42 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Nov 10 06:30:42 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 06:30:43 localhost simet-ma: measurement peer: https://sp-ix-p2.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 06:30:43 localhost simet-ma: starting measurement task: TWAMP 001-IPv4
Nov 10 06:30:48 localhost simet-ma: starting measurement task: TWAMP 001-IPv6
Nov 10 06:30:48 localhost simet-ma: starting measurement task: traceroute 001-IPv4
Nov 10 06:30:50 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 06:30:50 localhost simet-ma: starting measurement task: traceroute 001-IPv6
Nov 10 06:30:50 localhost simet-ma: measurement peer: https://sp-ix-p1.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 06:30:50 localhost simet-ma: starting measurement task: TWAMP 002-IPv4
Nov 10 06:30:55 localhost simet-ma: starting measurement task: TWAMP 002-IPv6
Nov 10 06:30:55 localhost simet-ma: starting measurement task: traceroute 002-IPv4
Nov 10 06:30:57 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 06:30:57 localhost simet-ma: starting measurement task: traceroute 002-IPv6
Nov 10 06:30:57 localhost simet-ma: measurement peer: https://rj-ix-p1.rj-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 06:30:57 localhost simet-ma: starting measurement task: TWAMP 003-IPv4
Nov 10 06:31:01 localhost simet-ma: starting measurement task: TWAMP 003-IPv6
Nov 10 06:31:01 localhost simet-ma: starting measurement task: traceroute 003-IPv4
Nov 10 06:31:03 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 06:31:04 localhost simet-ma: starting measurement task: traceroute 003-IPv6
Nov 10 06:33:14 localhost simet-ma: Authorization request failed at: https://ba-ix-p1.ba-ix.peers.simet.nic.br:443/server-monitor/measure-allowed
Nov 10 06:33:15 localhost simet-ma: measurement peer: https://sp-p1.sp.peers.simet.nic.br:443/server-monitor/
Nov 10 06:33:15 localhost simet-ma: starting measurement task: TWAMP 004-IPv4
Nov 10 06:33:19 localhost simet-ma: starting measurement task: TWAMP 004-IPv6
Nov 10 06:33:19 localhost simet-ma: starting measurement task: traceroute 004-IPv4
Nov 10 06:33:21 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 06:33:21 localhost simet-ma: starting measurement task: traceroute 004-IPv6
Nov 10 06:33:22 localhost simet-ma: Waiting for background measurements to complete
Nov 10 06:33:52 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Nov 10 07:20:43 localhost simet-ma: downloaded a proposed schedule from controller
Nov 10 07:20:43 localhost simet-lmapd: proposed new SIMET schedule is invalid
Nov 10 07:20:43 localhost simet-ma: failed to download or activate schedule from controller
Nov 10 07:20:43 localhost simet-ma: SIMET schedule unchanged
Nov 10 07:20:43 localhost simet-ma: using local schedule
Nov 10 08:26:01 localhost CRON[22287]: (root) CMD (if [ -x /opt/simet/bin/simet_geolocation.sh ] ; then /opt/simet/bin/simet_geolocation.sh >/dev/null 2>&1 || true ; fi)
Nov 10 08:26:01 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 10:27:25 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 10:27:25 localhost simet-ma: measurement peer: https://sp-ix-p2.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 10:27:25 localhost simet-ma: starting measurement task: TWAMP IPv4
Nov 10 10:27:41 localhost simet-ma: starting measurement task: traceroute IPv4
Nov 10 10:27:42 localhost simet-ma: starting measurement task: TWAMP IPv6
Nov 10 10:27:44 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 10:27:44 localhost simet-ma: starting measurement task: traceroute IPv6
Nov 10 10:28:14 localhost simet-ma: starting measurement task: TCPBW IPv4
Nov 10 10:28:40 localhost simet-ma: starting measurement task: TCPBW IPv6
Nov 10 10:29:10 localhost simet-ma: Task TCPBW IPv6, failed with exit code: 25
Nov 10 10:29:10 localhost simet-ma: geolocation: error: Not enough BSSIDs found to geolocate
Nov 10 10:29:10 localhost simet-ma: Geolocation attempt failed.
Nov 10 10:29:10 localhost simet-ma: Waiting for background measurements to complete
Nov 10 10:29:10 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Nov 10 10:29:10 localhost simet-ma: simet-ma-runner v0.17.9.1-0-gb60936f5a6+ starting...
Nov 10 10:29:11 localhost simet-ma: measurement peer: https://sp-ix-p1.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 10:29:11 localhost simet-ma: starting measurement task: TWAMP 001-IPv4
Nov 10 10:29:16 localhost simet-ma: starting measurement task: traceroute 001-IPv4
Nov 10 10:29:16 localhost simet-ma: starting measurement task: TWAMP 001-IPv6
Nov 10 10:29:18 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 10:29:18 localhost simet-ma: starting measurement task: traceroute 001-IPv6
Nov 10 10:29:18 localhost simet-ma: measurement peer: https://sp-ix-p2.sp-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 10:29:18 localhost simet-ma: starting measurement task: TWAMP 002-IPv4
Nov 10 10:29:23 localhost simet-ma: starting measurement task: traceroute 002-IPv4
Nov 10 10:29:23 localhost simet-ma: starting measurement task: TWAMP 002-IPv6
Nov 10 10:29:25 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 10:29:25 localhost simet-ma: starting measurement task: traceroute 002-IPv6
Nov 10 10:29:25 localhost simet-ma: measurement peer: https://rj-ix-p1.rj-ix.peers.simet.nic.br:443/server-monitor/
Nov 10 10:29:25 localhost simet-ma: starting measurement task: TWAMP 003-IPv4
Nov 10 10:29:29 localhost simet-ma: starting measurement task: TWAMP 003-IPv6
Nov 10 10:29:29 localhost simet-ma: starting measurement task: traceroute 003-IPv4
Nov 10 10:29:31 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 10:29:31 localhost simet-ma: starting measurement task: traceroute 003-IPv6
Nov 10 10:31:42 localhost simet-ma: Authorization request failed at: https://ba-ix-p1.ba-ix.peers.simet.nic.br:443/server-monitor/measure-allowed
Nov 10 10:31:42 localhost simet-ma: measurement peer: https://sp-p1.sp.peers.simet.nic.br:443/server-monitor/
Nov 10 10:31:42 localhost simet-ma: starting measurement task: TWAMP 004-IPv4
Nov 10 10:31:47 localhost simet-ma: starting measurement task: TWAMP 004-IPv6
Nov 10 10:31:47 localhost simet-ma: starting measurement task: traceroute 004-IPv4
Nov 10 10:31:49 localhost simet-ma: Task TWAMP IPv6, failed with exit code: 12
Nov 10 10:31:49 localhost simet-ma: starting measurement task: traceroute 004-IPv6
Nov 10 10:31:49 localhost simet-ma: Waiting for background measurements to complete
Nov 10 10:32:19 localhost simet-ma: LMAP report accepted by collector https://api.simet.nic.br:443/collector/measure
Meu ambiente:
Olá Pessoal, boa tarde tudo bem?
Estamos trabalhando no monitoramento da nossa infra.
Para otimizar o processo, seria importante exportar o JSON do último teste, análogo ao que vemos na página do Simet.
Será que possuem alguma dica de como realizar?
O Speedtest tem essa funcionalidade e já utilizamos.
Abraço,
Erros no build do SIMET-MA no Docker:
S.O.: Ubuntu 18.04.2 LTS
Kernel: 4.18.0-16-generic SMP x86_64 GNU/Linux
As dependências foram previamente instaladas:
$ sudo apt-get install build-essential autoconf automake libtool fakeroot debhelper libjson-c-dev cmake libcurl4-gnutls-dev pkg-config lsb-release
Foram usados os comandos recomendados na documentação:
$./autogen.sh
Não ocorreram erros.
$./configure --prefix=/opt/simet --localstatedir=/var --libdir=/opt/simet/lib --sysconfdir
=/opt/simet/etc
Não ocorreram erros.
$ sudo docker build -t simet-ma:local -f docker/Dockerfile .
Ocorreram alguns erros:
Sending build context to Docker daemon 20.25MB
Step 1/28 : ARG DISTRO=debian:stretch
Step 2/28 : FROM $DISTRO
---> 0af60a5c6dd0
Step 3/28 : LABEL description="SIMET2 Measurement Agent builder environment"
---> Using cache
---> f16491abda1c
Step 4/28 : LABEL maintainer="Henrique de Moraes Holschuh [email protected]"
---> Using cache
---> cabdeba559bb
Step 5/28 : RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get -y dist-upgrade && apt-get -y install --install-recommends build-essential autoconf autom
ake libtool fakeroot debhelper
---> Running in f3fe5a9a4c86
Err:1 http://security.debian.org/debian-security stretch/updates InRelease
Could not connect to security.debian.org:80 (200.17.202.197), connection timed out
Err:2 http://deb.debian.org/debian stretch InRelease
Could not connect to deb.debian.org:80 (130.89.148.14), connection timed out [IP: 130.89.148.14 80]
Err:3 http://deb.debian.org/debian stretch-updates InRelease
Unable to connect to deb.debian.org:http: [IP: 130.89.148.14 80]
Reading package lists...
W: Failed to fetch http://deb.debian.org/debian/dists/stretch/InRelease Could not connect to deb.debian.org:80 (130.89.148.14), connection timed out [IP: 130.89.148.14 80]
W: Failed to fetch http://security.debian.org/debian-security/dists/stretch/updates/InRelease Could not connect to security.debian.org:80 (200.17.202.197), connection time
d out
W: Failed to fetch http://deb.debian.org/debian/dists/stretch-updates/InRelease Unable to connect to deb.debian.org:http: [IP: 130.89.148.14 80]
W: Some index files failed to download. They have been ignored, or old ones used instead.
Reading package lists...
Building dependency tree...
Reading state information...
Calculating upgrade...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
Package debhelper is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Unable to locate package build-essential
E: Unable to locate package autoconf
E: Unable to locate package automake
E: Unable to locate package libtool
E: Unable to locate package fakeroot
E: Package 'debhelper' has no installation candidate
The command '/bin/sh -c DEBIAN_FRONTEND=noninteractive apt-get update && apt-get -y dist-upgrade && apt-get -y install --install-recommends build-essential autoco
nf automake libtool fakeroot debhelper' returned a non-zero code: 100
$
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.