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

[BUG] Geolite database download failing #164

Closed
supersnellehenk opened this issue Dec 31, 2019 · 5 comments
Closed

[BUG] Geolite database download failing #164

supersnellehenk opened this issue Dec 31, 2019 · 5 comments
Labels
bug Something isn't working in-next-release In the next release

Comments

@supersnellehenk
Copy link

supersnellehenk commented Dec 31, 2019

Describe the bug
The URL Varken is trying to download is offline. (http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.tar.gz) which makes installing Varken for the first time impossible. This is due to what I'm guessing new privacy regulations at Maxmind that started on the 30th of December, 2019.

2019-12-31 12:11:08 : ERROR : helpers : Could not find GeoLite2 DB! Downloading!

2019-12-31 12:11:08 : INFO : helpers : Downloading GeoLite2 from http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.tar.gz
Traceback (most recent call last):
File "/app/varken/helpers.py", line 33, in reader_manager
self.reader = Reader(self.dbfile)
File "/usr/local/lib/python3.7/site-packages/geoip2/database.py", line 86, in __init__
self._db_reader = maxminddb.open_database(fileish, mode)
File "/usr/local/lib/python3.7/site-packages/maxminddb/__init__.py", line 41, in open_database
return maxminddb.reader.Reader(database, mode)
File "/usr/local/lib/python3.7/site-packages/maxminddb/reader.py", line 51, in __init__
with open(database, 'rb') as db_file:
FileNotFoundError: [Errno 2] No such file or directory: '/config/GeoLite2-City.mmdb'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.7/urllib/request.py", line 1317, in do_open
encode_chunked=req.has_header('Transfer-encoding'))
File "/usr/local/lib/python3.7/http/client.py", line 1229, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/usr/local/lib/python3.7/http/client.py", line 1275, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/usr/local/lib/python3.7/http/client.py", line 1224, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/usr/local/lib/python3.7/http/client.py", line 1016, in _send_output
self.send(msg)
File "/usr/local/lib/python3.7/http/client.py", line 956, in send
self.connect()
File "/usr/local/lib/python3.7/http/client.py", line 928, in connect
(self.host,self.port), self.timeout, self.source_address)
File "/usr/local/lib/python3.7/socket.py", line 707, in create_connection
for res in getaddrinfo(host, port, 0, SOCK_STREAM):
File "/usr/local/lib/python3.7/socket.py", line 748, in getaddrinfo
for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
socket.gaierror: [Errno -2] Name does not resolve

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/app/Varken.py", line 110, in <module>
GEOIPHANDLER = GeoIPHandler(DATA_FOLDER)
File "/app/varken/helpers.py", line 26, in __init__
self.reader_manager(action='open')
File "/app/varken/helpers.py", line 36, in reader_manager
result_status = self.download()
File "/app/varken/helpers.py", line 87, in download
urlretrieve(url, tar_dbfile)
File "/usr/local/lib/python3.7/urllib/request.py", line 247, in urlretrieve
with contextlib.closing(urlopen(url, data)) as fp:
File "/usr/local/lib/python3.7/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/usr/local/lib/python3.7/urllib/request.py", line 525, in open
response = self._open(req, data)
File "/usr/local/lib/python3.7/urllib/request.py", line 543, in _open
'_open', req)
File "/usr/local/lib/python3.7/urllib/request.py", line 503, in _call_chain
result = func(*args)
File "/usr/local/lib/python3.7/urllib/request.py", line 1345, in http_open
return self.do_open(http.client.HTTPConnection, req)
File "/usr/local/lib/python3.7/urllib/request.py", line 1319, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [Errno -2] Name does not resolve>`

To Reproduce
Steps to reproduce the behavior:

  1. Install Varken from fresh without Geolite2-City.mmdb

Expected behavior
Varken to grab the .mmdb file from Maxmind and install successfully.

Environment (please complete the following information):

  • OS: Docker, boerderij/varken
  • Version: latest

Additional context
I managed to fix this myself by creating an account and downloading it manually, but this should be addressed.

@supersnellehenk supersnellehenk added the awaiting-triage Request awaiting triage label Dec 31, 2019
@samwiseg0 samwiseg0 added bug Something isn't working in-next-release In the next release and removed awaiting-triage Request awaiting triage labels Dec 31, 2019
@samwiseg0
Copy link
Member

samwiseg0 commented Dec 31, 2019

MaxMind did not give us a lot of time to transition to their new system. The changes have been pushed to develop. The fixes will be posted to master soon.

@davralin
Copy link

Any ETA on when this change will go live in the docker-image?

Being new with Varken/InfluxDB, have I understood it correctly that I could sign up on MaxMind and get an API-key, and after setting that it will work?

@samwiseg0
Copy link
Member

samwiseg0 commented Jan 17, 2020

@davralin

Have you checked the releases or read the changelog?

2020-01-17_12-24-15 (3)

Also in the future if you need support please use one of our support methods.

@davralin

This comment has been minimized.

@samwiseg0
Copy link
Member

samwiseg0 commented Jan 18, 2020

@davralin The documentation is clear. It is only a requirement if you use the Tautulli module. It has always been that way. MaxMind changed their requirements where a key is now required.

If you have any further questions or issues use our support methods as I already stated. Issues is not the place for support.

@Boerderij Boerderij locked as resolved and limited conversation to collaborators Jan 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working in-next-release In the next release
Projects
None yet
Development

No branches or pull requests

3 participants