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

Maxmind IP lookup database cannot be downloaded anonymously anymore #8275

Open
escopecz opened this issue Dec 31, 2019 · 6 comments
Open

Maxmind IP lookup database cannot be downloaded anonymously anymore #8275

escopecz opened this issue Dec 31, 2019 · 6 comments
Labels
Bug

Comments

@escopecz
Copy link
Member

@escopecz escopecz commented Dec 31, 2019

Bug Description

Mautic uses Maxmind dataset as the default IP lookup database. It cannot be downloaded directly since yesterday. Users must register to get a license key. We'll have to update the Maxmind config option to allow users to set the key.

Starting December 30, 2019, we will be requiring users of our GeoLite2 databases to register for a MaxMind account and obtain a license key in order to download GeoLite2 databases.

https://blog.maxmind.com/2019/12/18/significant-changes-to-accessing-and-using-geolite2-databases/

Q A
Mautic version Any
PHP version Any
Browser Any
@npracht npracht added the Bug label Jan 6, 2020
@marioguima

This comment has been minimized.

Copy link

@marioguima marioguima commented Jan 6, 2020

While we don't have the automatic update I solved it like this

Let's go step by step

  1. Create a maxmind account
    just click here
    https://www.maxmind.com/en/geolite2/signup

  2. Create a password
    For this you need to click on the link you will receive in your email (they will send you an email, just click on the link where it is written)
    "you must first create a password here" you will click on the word "here" in your email message to create a password

  3. You will be logged into your maxmind.com account by entering your email and the password you just created

  4. Sign in to your account by clicking the icon at the top.
    Will open a screen with a menu on the left side
    Click on the "Download Files" option

  5. Download the file that has the ID "GeoLite2-City" (to date was on the third line)
    Click on GZIP
    (will download a file named GeoLite2-City_20191231.tar.gz)
    note that 20191231 will change every week because this is the last ips list update date
    This list is updated every Tuesday.

  6. Use an unzip (I use 7zip)
    it will open another .tar file
    (GeoLite2-City_20191231.tar)

  7. Extract again with 7zip
    Will create a folder (GeoLite2-City_20191231)

  8. Send the file GeoLite2-City.mmdb (which is inside the folder) to the server where your mautic is installed.
    Put the file in the folder
    YOUR-MAUTIC / app / cache / ip_data
    Where YOUR-MAUTIC is the folder where you installed mautic

Ready :)

After that (if you want to check if it's up to date)
Go to settings in your mautic and see that the list of ips will have the update time

@quangmai911

This comment has been minimized.

Copy link

@quangmai911 quangmai911 commented Jan 11, 2020

Hi,

I followed your helpful tips. However, I am still stucked at the last step. Put in the folder. I put the file exactly where the path shown with File Manager in Cpanel and grand the permission for read/write etc... Put the issue can not solve yet. Any ideas please. Thank you so much.

Quang

  1. Send the file GeoLite2-City.mmdb (which is inside the folder) to the server where your mautic is installed.
    Put the file in the folder
    YOUR-MAUTIC / app / cache / ip_data
    Where YOUR-MAUTIC is the folder where you installed mautic
@ekkeguembel

This comment has been minimized.

Copy link

@ekkeguembel ekkeguembel commented Jan 11, 2020

Disable the cronjob that tries to update ("app/console mautic:iplookup:download"), or it will overwrite (delete) the manual upload next time it's executed.

@quangmai911

This comment has been minimized.

Copy link

@quangmai911 quangmai911 commented Jan 12, 2020

"app/console mautic:iplookup:download
Thanks for the reply.
I attached the photos for your references. What I did so far.

  • Disable cronjob
  • download & upload through cpanel the latest GeoIP file included license from my download account page from maxmind website.
  • grant the file with read/write/modification
  • try to fetch it again, still error.
    Any other ideas? Thanks so much
    screencapture-maxmind-en-accounts-161904-license-key
    screencapture cronjob
    screencapture frontend
    screencapture-email-muenvironmental-org-nz-s-config-edit-2020-01-12-10_28_33
@atulcj

This comment has been minimized.

Copy link

@atulcj atulcj commented Jan 15, 2020

Starting with @marioguima's comment (above), I discovered "Automatic Updates for GeoIP2 and GeoIP Legacy Databases".

  1. Installed the GeoIP Update program as described on the page
  2. Created an account and obtained license keys
  3. Created a geoipudate configuration file as per the "partially pre-filled configuration file"
  4. Then using the command "sudo -u daemon geoipupdate -f /usr/local/etc/GeoIP.conf -d /path/to/my/mautic/install/app/cache/ip_data downloaded the geoip database
  5. Confirmed that this worked ok
  6. Replaced my geoip update cron with the above command to periodically update the database

Fingers crossed, hopefully this should help me till the team finds a solution

@atulcj

This comment has been minimized.

Copy link

@atulcj atulcj commented Jan 16, 2020

"app/console mautic:iplookup:download
Thanks for the reply.
I attached the photos for your references. What I did so far.

  • Disable cronjob
  • download & upload through cpanel the latest GeoIP file included license from my download account page from maxmind website.
  • grant the file with read/write/modification
  • try to fetch it again, still error.
    Any other ideas? Thanks so much
    screencapture-maxmind-en-accounts-161904-license-key
    screencapture cronjob
    screencapture frontend
    screencapture-email-muenvironmental-org-nz-s-config-edit-2020-01-12-10_28_33

@quangmai911 - In your screenshot the mmdb file seems to be 0kb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.