kosctelecom / horus Goto Github PK
View Code? Open in Web Editor NEWHorus is a distributed tool to collect snmp and icmp metrics from various network equipments and send the results to kafka, NATS.io, prometheus, and/or influxDB
License: Other
Horus is a distributed tool to collect snmp and icmp metrics from various network equipments and send the results to kafka, NATS.io, prometheus, and/or influxDB
License: Other
currently we use the first 4 characters of the hostname as the hostID. This implementation is kosc-specific. We should use the device db id instead.
Hi,
I would like to filter indexes when the agent polishes data from the interfaces of the dslam equipement for example. I would like to keep only the indexes equal to 235036672.
I updated the "measures" table by indicating the metric to be taken into account for filtering and in the "filter_pattern" field, I put the index to keep "235036672". Unfortunately, the agent doesn't send me anything back.
How does the "filter" part of the data work?
Thanks,
Christophe.
Hello,
I am trying to install Horus on a Freebsd VM and I get this error message.
Cloning into 'horus'...
remote: Enumerating objects: 1501, done.
remote: Counting objects: 100% (1501/1501), done.
remote: Compressing objects: 100% (667/667), done.
remote: Total 1501 (delta 957), reused 1363 (delta 819), pack-reused 0
Receiving objects: 100% (1501/1501), 452.31 KiB | 1.75 MiB/s, done.
Resolving deltas: 100% (957/957), done.
make all
go build -ldflags "-X main.Revision== -X main.Build= -X main.Branch=" -o ./cmd/bin ./...
go: downloading github.com/lib/pq v1.2.0
go: downloading github.com/vma/influxclient v1.0.0
go: downloading github.com/jmoiron/sqlx v1.2.0
go: downloading github.com/nats-io/nats.go v1.10.0
go: downloading github.com/prometheus/client_golang v1.1.0
go: downloading github.com/mitchellh/copystructure v1.0.0
go: downloading github.com/vma/httplogger v1.0.0
go: downloading github.com/teris-io/shortid v0.0.0-20171029131806-771a37caa5cf
go: downloading github.com/optiopay/kafka/v2 v2.1.1
go: downloading github.com/vma/gosnmp v1.22.4
go: downloading github.com/nats-io/nuid v1.0.1
go: downloading github.com/mitchellh/reflectwalk v1.0.0
go: downloading github.com/nats-io/nkeys v0.1.4
go: downloading github.com/prometheus/common v0.6.0
go: downloading github.com/vma/glog v1.5.1
go: downloading github.com/prometheus/procfs v0.0.3
go: downloading github.com/vma/getopt v1.0.0
go: downloading golang.org/x/crypto v0.0.0-20200323165209-0ec3e9974c59
go: downloading github.com/golang/protobuf v1.3.2
go: downloading github.com/golang/mock v1.3.1
go: downloading github.com/matttproud/golang_protobuf_extensions v1.0.1
go: downloading github.com/beorn7/perks v1.0.1
go: downloading github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90
go: downloading github.com/nats-io/jwt v0.3.2
go: downloading github.com/golang/snappy v0.0.1
agent/poll.go:88:5: undefined: updateTotalMem
agent/poll.go:89:5: undefined: updateUsedMem
agent/poll.go:188:15: undefined: usedMem
agent/poll.go:192:78: undefined: usedMem
agent/prometheus.go:108:13: undefined: totalMem
*** Error code 2
Stop.
make: stopped in /data/horus
I have installed Go.
#pkg info | grep go-
go-1.15.9,1 Go programming language
My OS is :
FreeBSD vma-ingscr-08 12.2-RELEASE-p4 FreeBSD 12.2-RELEASE-p4 GENERIC amd64
Regards,
Chris.
Currently, the hostname field in devices table is only used as label for the metrics. The snmp and ping target is taken from the ip_address field which is mandatory.
Whe should make the ip_address field optional and if empty, take the hostname as the target. It may be resolved by the dispatcher before sending the request to an agent.
Hi,
I'm trying to pool the information of the mac addresses of the different devices from Horus.
The polling goes well but the agents do not expose the results.
Looks like Horus doesn't recognize the "PhysAddress" data type.
"ID": 39,
"Name": "ifPhysAddress",
"Oid": ".1.3.6.1.2.1.2.2.1.6",
"Description": "The interface address at the protocol layer immediately below the network layer in the protocol stack.",
"PollingFrequency": 0,
"LastPolledAt": null,
"Active": true,
"ExportAsLabel": false,
"ExportedName": "if_phys_address",
"PostProcessors": []
}
Reponse:
[I] 2021-12-14 09:43:42.409962 - CdK5EptWH@3 - con#2: res map for group indexed oid .1.3.6.1.2.1.2.2.1.6: 97 metrics
[I] 2021-12-14 09:43:42.410015 - CdK5EptWH@3 - con#2: done walking indexed oid .1.3.6.1.2.1.2.2.1.6 [ifPhysAddress]: took 14ms
{"oid":".1.3.6.1.2.1.2.2.1.6","name":"ifPhysAddress","exported_name":"if_phys_address","description":"The interface address at the protocol layer immediately below the network layer in the protocol stack.","value":"\u0000\ufffd\ufffdﻫ","index":"36044800"}
The type of value "ifPhysAddress" is PHYSADDRESS.
BR,
Christophe.
Hi,
We use the "tags" field of the "devices" table which allows you to add labels. This feature works well but does not expose the labels in the "pingmetrics" metrics. It exposes tags only in the results of the "snmpmetrics" metric.
Examples:
champs "tags": {Communaute="TEST", location="TEST"} for devices "xxxxxxxxxxxxxx"
snmpmetrics:
ifMetrics_ifMtu{Communaute="TEST",category="Network Terminaison Equipment",host="xxxxxxxxxxxxxx",id="1",ifDescr="ETHERNET NETWORK PORT",ifName="NETWORK PORT-1-1-1-2",index="2",location="TEST",model="NTE",oid=".1.3.6.1.2.1.2.2.1.4",vendor="GENERIC"} 9612 1638376611615
pingmetrics: We don't see the tags label "Communaute" and "location".
ping_min_duration_seconds{category="Network Terminaison Equipment",host="xxxxxxxxxxxxxx",id="1",ip_address="yyyyyyyyy",model="NTE",vendor="GENERIC"} 0.01567 1638518891194
It's possible to add labels (tags) in pingmetrics ?
BR,
Christophe.
Currently when exporting to Prometheus, indexed measures with labels only metrics are skipped. This is a bug as scalar metrics are exported correcly as labels.
The behaviour should be the same as for scalar metrics and the prometheus metric should take the name of the horus measure and the default value of 1.0.
Hello,
I did the following test.
I stop the "Horus" database and I notice the dispatcher process drops when it no longer has access to its database.
We must restart the "dispatcher" process for the "Horus" polling to resume when the database is available again.
Can we tell the dispacter not to stop even if he no longer has access to his base ?
Process start with option:
/data/horus/cmd/bin/horus-dispatcher -l 1 -c postgres://horus:[email protected]/horus?sslmode=disable -d 3 --log /logs/horus
Logs:
[F] 2021-11-16 08:39:53.083835 db.go:74 - db lock conn ping: driver: bad connection
Br,
Christophe.
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.