Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no data displayed in grafana #47

Open
sistemmsn opened this issue Oct 7, 2024 · 3 comments
Open

no data displayed in grafana #47

sistemmsn opened this issue Oct 7, 2024 · 3 comments

Comments

@sistemmsn
Copy link

I don't understand why it doesn't give me data in Grafana
image

image

Internal IP-Source: 172.17.0.1 called: meta.levecs.com Internal IP-Source: 172.17.0.1 called: meta.levecs.com **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> **************** start ********************* Measurement-name: ReverseProxyConnections response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) **************** start ********************* Measurement-name: ReverseProxyConnections ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> **************** start ********************* Measurement-name: ReverseProxyConnections response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> **************** start ********************* Measurement-name: ReverseProxyConnections response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database. **************** start ********************* Measurement-name: ReverseProxyConnections Traceback (most recent call last): File "/root/.config/NPMGRAF/Getipinfo.py", line 59, in <module> response = reader.asn(str(sys.argv[1])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 176, in asn ASN, self._flat_model_for(geoip2.models.ASN, "GeoLite2-ASN", ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 267, in _flat_model_for (record, prefix_len) = self._get(types, ip_address) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/geoip2/database.py", line 240, in _get raise geoip2.errors.AddressNotFoundError( geoip2.errors.AddressNotFoundError: The address 1.2.8.1 is not in the database.

@smilebasti
Copy link
Owner

Hi, can you please share your environments variables you set.

@sistemmsn
Copy link
Author

@smilebasti of course

`version: '3'
services:
npmgraf:
image: smilebasti/npmgrafstats:latest
restart: unless-stopped
hostname: npmgraf
environment:
REDIRECTION_LOGS: TRUE
INTERNAL_LOGS: TRUE
MONITORING_LOGS: TRUE
INFLUX_HOST: influxdb_nginx:8086
INFLUX_BUCKET: npmgrafstats
INFLUX_ORG: npmgrafstats
INFLUX_TOKEN: 232123132123123123132132
volumes:
- /home/docker/nginx/data/logs:/logs
- /home/docker/nginx/geolite:/geolite
- /home/docker/nginx/monitoringips.txt:/monitoringips.txt
- /etc/localtime:/etc/localtime:ro
depends_on:
- geoipupdate
networks:
- proxy

influxdb_nginx:
image: influxdb:2.7-alpine
hostname: influxdb_nginx
restart: unless-stopped
environment:
DOCKER_INFLUXDB_INIT_MODE: setup
DOCKER_INFLUXDB_INIT_USERNAME: npmgrafstats
DOCKER_INFLUXDB_INIT_PASSWORD: 121313313
DOCKER_INFLUXDB_INIT_ORG: npmgrafstats
DOCKER_INFLUXDB_INIT_BUCKET: npmgrafstats
volumes:
- /home/docker/nginx/influxdbv2:/var/lib/influxdb2
- /etc/localtime:/etc/localtime:ro
networks:
- proxy

geoipupdate:
image: maxmindinc/geoipupdate
hostname: geoipupdate
restart: unless-stopped
environment:
GEOIPUPDATE_ACCOUNT_ID: 1213131
GEOIPUPDATE_LICENSE_KEY: 123365656
GEOIPUPDATE_EDITION_IDS: GeoLite2-ASN GeoLite2-City GeoLite2-Country
GEOIPUPDATE_FREQUENCY: 24
volumes:
- /home/docker/nginx/geolite:/usr/share/GeoIP
- /etc/localtime:/etc/localtime:ro
networks:
- proxy

networks:
proxy:
external: true
`

@JuliusBlueTek
Copy link

Try changing:

INFLUX_HOST: influxdb_nginx:8086

To:

INFLUX_HOST: 'http://influxdb_nginx:8086'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants