@mattab opened this Issue on May 2nd 2018 Member

Now that we have Geoip2 activated by default for all new users (done in https://github.com/matomo-org/matomo/pull/12699), we should also activate the feature for all existing users who are upgrading. Since Geoip2 requires a DB update for the Region column, we need to wait for Matomo 4 to enable the plugin.

Suggested steps for final Geoip2 takeover

  • Activate the plugin on update to Matomo 4.0.0
  • Could we automatically download the database?
  • When Geoip1 was enabled, and Geoip2 database successfully downloaded, could we automatically enable Geoip2 provider instead?
  • We should also move all the Geoip1 code to a separate plugin. Later (maybe in Matomo 5?) we should then remove/delete this plugin completely.
  • Check that all FAQs/ user guides exclusively mention Geoip2 (delete all Geoip1 specifics)
  • ...?
@sgiehl commented on February 14th 2020 Member

With #15521 geoip legacy support will be removed and the db update will be done with Matomo 4.

@diosmosis commented on April 8th 2020 Member

@mattab given dbip's city inaccuracies, should this still be done?

@mattab commented on April 8th 2020 Member

Ideally we would present both options, the pros and cons:

  • DB-IP, less accurate, does not require registration, setup in a few clicks
  • GeoIp, more accurate, requires registration and accepting terms and conditions

people in one click can setup the DB-IP if they choose to, or instead register to GeoIp and then enter the info in the UI so Matomo will automatically download their DB using their credentials. Thoughts?

@diosmosis commented on April 8th 2020 Member

@mattab this functionality is already available in the geolocation admin page, what would you change?

@tsteur commented on April 15th 2020 Member

The goal of this issue should be

  • for new installs to automatically set up GeoIP2 with DB-IP. Meaning we would download the free DB in the background after installation. There could be a task that runs eg hourly or something and executes in the end only once to download the initial DB and configures it (unless a DB is already available or a different provider is configured).
  • for existing users if I see this right in @mattab comment is to migrate users over from GeoIP to GeoIP2 plugin and to activate the GeoIP2 plugin and configure automatically the DB-IP DB. Although not 100% sure about this? I guess we would do this only if no DB and no provider is configured yet. If already some MaxMind URL is configured (which could be a commercial or free license DB) etc then this should not happen.
  • for existing users still using GeoIP1 plugin: Show a warning to super users in the admin they should migrate to GeoIP2 plugin as GeoIP1 is deprecated and might be inaccurate
  • Ideally, in the Geolocation admin, when the free DB-IP is configured, in the top of the page somewhere we might want to show more clearly a note that MaxMind is more accurate and that they might want to make the effort to get a free or paid license.
@diosmosis commented on April 15th 2020 Member

Ideally, in the Geolocation admin, when the free DB-IP is configured, in the top of the page somewhere we might want to show more clearly a note that MaxMind is more accurate and that they might want to make the effort to get a free or paid license.

Will also need to ensure it's just the free version that has issues.

@sgiehl commented on April 21st 2020 Member
  • for existing users if I see this right in @mattab comment is to migrate users over from GeoIP to GeoIP2 plugin and to activate the GeoIP2 plugin and configure automatically the DB-IP DB. Although not 100% sure about this? I guess we would do this only if no DB and no provider is configured yet. If already some MaxMind URL is configured (which could be a commercial or free license DB) etc then this should not happen.
  • for existing users still using GeoIP1 plugin: Show a warning to super users in the admin they should migrate to GeoIP2 plugin as GeoIP1 is deprecated and might be inaccurate

Matomo 4 doesn't support the old GeoIP Legacy format any longer since #15521. The update currently switches users that were using an old database to the default provider. So that might need to be changed to an automatic switch to DB-IP database.
GeoIP Legacy was already marked as deprecated in Matomo 3.4.1. New installs didn't offer GeoIP Legacy anymore and old installs should have shown an information in the admin if automatic updates had been set up.

@sgiehl commented on April 21st 2020 Member

for new installs to automatically set up GeoIP2 with DB-IP.

Should we really do that without any bigger notice or possibility to not do that?
I would suggest to at least add a checkbox somewhere to enable usage of DB-IP or maybe even add a new step in the end to set up GeoIP2 directly (with the option to also use a paid DB or Maxmind or switch the step completely)

@Findus23 commented on April 21st 2020 Member

I would not automatically set up GeoIP, but adding a new setup page sounds like a good idea so people are not confused (e.g. https://forum.matomo.org/t/matomo-and-geolocation-getting-the-location-wrong-from-my-linux-machine/36934)

@tsteur commented on April 21st 2020 Member

Not sure what the problem be with automatically installing DB-IP in the background? It be a better default than detecting country based on language and realistically > 80% will want to set this up anyway.

@sgiehl commented on April 22nd 2020 Member

@tsteur I have no problem with offering an automatic setup. But I don't think it's good not to give the user the opportunity to opt out. Some people might not want to have a geolocation at all because of privacy reasons. For others it might possibly be a no go that installing Matomo triggers an automatic download of a ~80MB file. Others might have already a set up server module, where downloading DB-IP is simply unneeded.
Personally I would suggest to add another (skip-able) step in the install. It could offer the (default) option to automatically set up DB-IP (or maybe also Maxmind) or to choose another geolocation provider (if any is already set up and working).

@Findus23 commented on April 22nd 2020 Member

I think automatically loading any files after install seems really suspicious. Also people expect that the matomo.zip and the LEGALNOTICE contain all licenses they have to pay attention to (even if it is a "tame" one like CC BY-SA)

So if we would make it automatically, we would have to include the db in the original matomo.zip (but that would create new issues)

@tsteur commented on April 22nd 2020 Member

We could generally also add it to the LEGALNOTICE? On WP it's fine to do this as long as you mention it in the readme (the plugin directory page).

If it's easy to do we can also add a checkbox to the installer (maybe enabled by default since it would be in the interest of most users to have this enabled) and it could mention it will download the DB and have a link to the license maybe or so. Could also mention (if you disable, then the location detection will be highly inaccurate but you can configure it later at any time).

Otherwise we'd need to disable all geolocation plugins (User Country etc) by default as we can't have the country detected by the language anymore.

For others it might possibly be a no go that installing Matomo triggers an automatic download of a ~80MB file. Others might have already a set up server module, where downloading DB-IP is simply unneeded.

There will be for sure a few users, but it's also easy to disable/change it later if someone really wants to use eg a server module. We shouldn't make a bad decision for say 95% of the users just because a few users wouldn't want it.

So adding a checkbox in the installer should be fine, it would be enabled by default.

@sgiehl commented on April 24th 2020 Member

So adding a checkbox in the installer should be fine, it would be enabled by default.

Sounds fine for me. While thinking about where we could add it, I was wondering if it maybe would make sense to add a complete new step in installation for "Privacy". There we could also directly make it possible to set some basic privacy setting like ip anonymization

This Issue was closed on May 14th 2020
Powered by GitHub Issue Mirror