Re: Issue with Fedora GeoIP service
On Thu, 9 Apr 2020 at 12:35, Tomasz Torcz wrote: > On Thu, Apr 09, 2020 at 04:55:20PM +0200, Adrian Reber wrote: > > > > We finally pushed it to Fedora's staging environment. Please try it > > using https://geoip.stg.fedoraproject.org/city if you have a chance. > > It seems to have only IPv4 address. It provides correct city in > my case, but IPv6 testing would be nice, too. > > staging is ipv4 only. > > -- > Tomasz Torcz “(…) today's high-end is tomorrow's embedded > processor.” > to...@pipebreaker.pl — Mitchell Blank on LKML > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to > infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org > -- Stephen J Smoogen. ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Thu, Apr 09, 2020 at 04:55:20PM +0200, Adrian Reber wrote: > > We finally pushed it to Fedora's staging environment. Please try it > using https://geoip.stg.fedoraproject.org/city if you have a chance. It seems to have only IPv4 address. It provides correct city in my case, but IPv6 testing would be nice, too. -- Tomasz Torcz “(…) today's high-end is tomorrow's embedded processor.” to...@pipebreaker.pl — Mitchell Blank on LKML ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Wed, Dec 18, 2019 at 01:29:03PM +0100, Martin Kolman wrote: > On Fri, 2019-12-13 at 09:21 -0800, Kevin Fenzi wrote: > > On Fri, Dec 13, 2019 at 08:00:01AM +0100, Adrian Reber wrote: > > > On Mon, Dec 09, 2019 at 12:19:17PM -0800, Kevin Fenzi wrote: > > > > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > > > > > I have an updated copy working with geoip2, with the exception of > > > > > area code data (which isn’t included in the > > > > > new database). But if I’m understanding it’s purpose correctly, > > > > > telephone area code isn’t needed. I need to do > > > > > some testing with IPs around the world to ensure that the data is > > > > > sane outside the US; once I’ve had a chance to > > > > > do that I’ll submit a PR on GitHub. > > > > > > > > Wow. Awesome work! > > > > > > > > Thanks for diving in and getting this going. > > > > > > > > In another email thread someone, Adrian said he had some code to do > > > > this, but if you already have it working, perhaps he could review your > > > > code/setup and we could then push it into ansible? > > > > > > I had a look at the PR > > > (https://github.com/fedora-infra/geoip-city-wsgi/pull/1) > > > and it works and the output is almost the same. Maybe one of the known > > > data consumers can have a short look if those subtle changes in the > > > output are not a problem. > > > > The main user I know of is anaconda and it sounds like the changes work > > for them. > > > > I guess I'd say we should pick a date (likely after the new year now), > > announce we are going to be changing it then a few times, and then on > > that date cut over to the new system. > Sounds good to me (as an Anaconda developer)! :) > > BTW, will the new API be available somewhere before that (stagin, etc.) ? > > We could patch Anaconda to talk to the new API & do some smoke testing, > just in case. :) We finally pushed it to Fedora's staging environment. Please try it using https://geoip.stg.fedoraproject.org/city if you have a chance. Adrian signature.asc Description: PGP signature ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Fri, 2019-12-13 at 09:21 -0800, Kevin Fenzi wrote: > On Fri, Dec 13, 2019 at 08:00:01AM +0100, Adrian Reber wrote: > > On Mon, Dec 09, 2019 at 12:19:17PM -0800, Kevin Fenzi wrote: > > > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > > > > I have an updated copy working with geoip2, with the exception of area > > > > code data (which isn’t included in the > > > > new database). But if I’m understanding it’s purpose correctly, > > > > telephone area code isn’t needed. I need to do > > > > some testing with IPs around the world to ensure that the data is sane > > > > outside the US; once I’ve had a chance to > > > > do that I’ll submit a PR on GitHub. > > > > > > Wow. Awesome work! > > > > > > Thanks for diving in and getting this going. > > > > > > In another email thread someone, Adrian said he had some code to do > > > this, but if you already have it working, perhaps he could review your > > > code/setup and we could then push it into ansible? > > > > I had a look at the PR > > (https://github.com/fedora-infra/geoip-city-wsgi/pull/1) > > and it works and the output is almost the same. Maybe one of the known > > data consumers can have a short look if those subtle changes in the > > output are not a problem. > > The main user I know of is anaconda and it sounds like the changes work > for them. > > I guess I'd say we should pick a date (likely after the new year now), > announce we are going to be changing it then a few times, and then on > that date cut over to the new system. Sounds good to me (as an Anaconda developer)! :) BTW, will the new API be available somewhere before that (stagin, etc.) ? We could patch Anaconda to talk to the new API & do some smoke testing, just in case. :) > > kevin > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Mon, Dec 09, 2019 at 12:19:17PM -0800, Kevin Fenzi wrote: > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > > I have an updated copy working with geoip2, with the exception of area code > > data (which isn’t included in the new database). But if I’m understanding > > it’s purpose correctly, telephone area code isn’t needed. I need to do some > > testing with IPs around the world to ensure that the data is sane outside > > the US; once I’ve had a chance to do that I’ll submit a PR on GitHub. > Wow. Awesome work! Awesome indeed. Please enjoy the Blessing of the FPL badge. :) https://badges.fedoraproject.org/user/ks3 -- Matthew Miller Fedora Project Leader ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Fri, Dec 13, 2019 at 08:00:01AM +0100, Adrian Reber wrote: > On Mon, Dec 09, 2019 at 12:19:17PM -0800, Kevin Fenzi wrote: > > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > > > I have an updated copy working with geoip2, with the exception of area > > > code data (which isn’t included in the new database). But if I’m > > > understanding it’s purpose correctly, telephone area code isn’t needed. I > > > need to do some testing with IPs around the world to ensure that the data > > > is sane outside the US; once I’ve had a chance to do that I’ll submit a > > > PR on GitHub. > > > > Wow. Awesome work! > > > > Thanks for diving in and getting this going. > > > > In another email thread someone, Adrian said he had some code to do > > this, but if you already have it working, perhaps he could review your > > code/setup and we could then push it into ansible? > > I had a look at the PR > (https://github.com/fedora-infra/geoip-city-wsgi/pull/1) > and it works and the output is almost the same. Maybe one of the known > data consumers can have a short look if those subtle changes in the > output are not a problem. The main user I know of is anaconda and it sounds like the changes work for them. I guess I'd say we should pick a date (likely after the new year now), announce we are going to be changing it then a few times, and then on that date cut over to the new system. kevin signature.asc Description: PGP signature ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Mon, Dec 09, 2019 at 12:19:17PM -0800, Kevin Fenzi wrote: > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > > I have an updated copy working with geoip2, with the exception of area code > > data (which isn’t included in the new database). But if I’m understanding > > it’s purpose correctly, telephone area code isn’t needed. I need to do some > > testing with IPs around the world to ensure that the data is sane outside > > the US; once I’ve had a chance to do that I’ll submit a PR on GitHub. > > Wow. Awesome work! > > Thanks for diving in and getting this going. > > In another email thread someone, Adrian said he had some code to do > this, but if you already have it working, perhaps he could review your > code/setup and we could then push it into ansible? I had a look at the PR (https://github.com/fedora-infra/geoip-city-wsgi/pull/1) and it works and the output is almost the same. Maybe one of the known data consumers can have a short look if those subtle changes in the output are not a problem. Adrian signature.asc Description: PGP signature ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
> Wow. Awesome work! > > Thanks for diving in and getting this going. > > In another email thread someone, Adrian said he had some code to do > this, but if you already have it working, perhaps he could review your > code/setup and we could then push it into ansible? > > Thanks again for working on this! > > kevin Sounds good. I submitted the PR on GitHub yesterday. I’ve also included the git patch below. --- geoip-city.wsgi | 36 +++- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/geoip-city.wsgi b/geoip-city.wsgi index 9435820..4f9d4d7 100755 --- a/geoip-city.wsgi +++ b/geoip-city.wsgi @@ -13,12 +13,13 @@ from string import zfill, atoi, strip, replace from paste.wsgiwrappers import * -import GeoIP +from iso3166 import countries +import geoip2.database +import geoip2.errors import json global gi -gi = GeoIP.open("/usr/share/GeoIP/GeoLiteCity.dat", GeoIP.GEOIP_STANDARD) -gi.set_charset(GeoIP.GEOIP_CHARSET_UTF8) +gi = geoip2.database.Reader("/usr/share/GeoIP/GeoLite2-City.mmdb") def real_client_ip(xforwardedfor): @@ -44,6 +45,7 @@ def get_client_ip(environ, request): def application(environ, start_response): request = WSGIRequest(environ) response = WSGIResponse() +results = {} code = 500 try: @@ -51,15 +53,39 @@ def application(environ, start_response): if client_ip is None: code = 400 raise Exception -results = gi.record_by_addr(client_ip) -if results is None: +data = gi.city(client_ip) +if data is None: code = 404 raise Exception +except geoip2.errors.AddressNotFoundError: +response.status_code = 404 +return response(environ, start_response) except: response.status_code=code return response(environ, start_response) results['ip'] = client_ip + +# map geoip2 data to a structure that matches the prior geoip format +results['city'] = data.city.name +results['region_name'] = data.subdivisions.most_specific.name +results['region'] = data.subdivisions.most_specific.iso_code +results['postal_code'] = data.postal.code +results['country_name'] = data.country.name +results['country_code'] = data.country.iso_code +results['time_zone']= data.location.time_zone +results['latitude'] = data.location.latitude +results['longitude']= data.location.longitude +results['metro_code'] = data.location.metro_code +results['dma_code'] = data.location.metro_code + +# geoip2 no longer includes country_code3, so it has to be pulled +# from iso3166.countries +if data.country.iso_code in countries: +results['country_code3'] = countries[data.country.iso_code].alpha3 +else: +results['country_code3'] = None + results = json.dumps(results) response.headers['Content-Length'] = str(len(results)) response.write(results) -- 2.21.0 (Apple Git-122.2) ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > I have an updated copy working with geoip2, with the exception of area code > data (which isn’t included in the new database). But if I’m understanding > it’s purpose correctly, telephone area code isn’t needed. I need to do some > testing with IPs around the world to ensure that the data is sane outside the > US; once I’ve had a chance to do that I’ll submit a PR on GitHub. Wow. Awesome work! Thanks for diving in and getting this going. In another email thread someone, Adrian said he had some code to do this, but if you already have it working, perhaps he could review your code/setup and we could then push it into ansible? Thanks again for working on this! kevin -- > > -- kevin > > > On Dec 6, 2019, at 7:13 PM, Kevin Sandy wrote: > > > > I’m interested in looking at this. Is this the script? > > > > https://github.com/fedora-infra/geoip-city-wsgi/blob/master/geoip-city.wsgi > > > > Assuming that’s the one, it looks like we need to replace GeoIP with geoip2 > > and wrap the geoip2 data in a structure to match what is currently being > > returned. Let me know if I’m missing anything. > > > > -- kevin > > > >> On Dec 6, 2019, at 6:39 PM, Kevin Fenzi wrote: > >> > >> On Fri, Dec 06, 2019 at 04:49:15PM +, Tom Hughes wrote: > >>> On 06/12/2019 16:41, Martin Kolman wrote: > On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: > > > I also installed the Fedora 31 GeoIP packages and ran the geoipupdate, > > and that DB has the correct info. > > IIRC the infra team mentioned some issues with the new geoip database > being incompatible with how the service is currently implemented, > resulting in being stuck with an outdated database until this is > resolved. > >>> > >>> Sounds like it maybe doesn't have support for GeoLite2 and is using the > >>> old MaxMind GeoLite Legacy databases which haven't been updated since > >>> the start of this year. > >> > >> Yes, that is exactly the case. > >> > >> We recently looked at this to see if we could retire the service, but it > >> looks like it's still needed, so we need to figure out how to get cycles > >> to update it. > >> > >> If someone wants to work on this, let us know! > >> > >> kevin > >> ___ > >> infrastructure mailing list -- infrastructure@lists.fedoraproject.org > >> To unsubscribe send an email to > >> infrastructure-le...@lists.fedoraproject.org > >> Fedora Code of Conduct: > >> https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > >> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > >> List Archives: > >> https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org > > ___ > > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > > Fedora Code of Conduct: > > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > > List Archives: > > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org signature.asc Description: PGP signature ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
I went ahead and published the updated copy on a test site, so feel free to hit it and test it out - http://geoip.digitallotus.com/. It’s also accepting the X-Forwarded-For header and doing the lookup on that if set, so I’ve been testing it with curl, e.g.: curl -s -H 'X-Forwarded-For: 1.180.10.10' http://geoip.digitallotus.com/ | jq . -- kevin > On Dec 7, 2019, at 1:10 PM, Tomasz Torcz wrote: > > On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: >> I have an updated copy working with geoip2, with the exception of area >> code data (which isn’t included in the new database). But if I’m >> understanding it’s purpose correctly, telephone area code isn’t >> needed. I need to do some testing with IPs around the world to ensure >> that the data is sane outside the US; once I’ve had a chance to do >> that I’ll submit a PR on GitHub. > > Do you need some IP's with known location to test? > > > -- > Tomasz Torcz “If you try to upissue this patchset I shall be > seeking > to...@pipebreaker.pl an IP-routable hand grenade.” — Andrew Morton > (LKML) > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Sat, Dec 07, 2019 at 09:39:46AM -0500, Kevin Sandy wrote: > I have an updated copy working with geoip2, with the exception of area > code data (which isn’t included in the new database). But if I’m > understanding it’s purpose correctly, telephone area code isn’t > needed. I need to do some testing with IPs around the world to ensure > that the data is sane outside the US; once I’ve had a chance to do > that I’ll submit a PR on GitHub. Do you need some IP's with known location to test? -- Tomasz Torcz “If you try to upissue this patchset I shall be seeking to...@pipebreaker.pl an IP-routable hand grenade.” — Andrew Morton (LKML) ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
I have an updated copy working with geoip2, with the exception of area code data (which isn’t included in the new database). But if I’m understanding it’s purpose correctly, telephone area code isn’t needed. I need to do some testing with IPs around the world to ensure that the data is sane outside the US; once I’ve had a chance to do that I’ll submit a PR on GitHub. -- kevin > On Dec 6, 2019, at 7:13 PM, Kevin Sandy wrote: > > I’m interested in looking at this. Is this the script? > > https://github.com/fedora-infra/geoip-city-wsgi/blob/master/geoip-city.wsgi > > Assuming that’s the one, it looks like we need to replace GeoIP with geoip2 > and wrap the geoip2 data in a structure to match what is currently being > returned. Let me know if I’m missing anything. > > -- kevin > >> On Dec 6, 2019, at 6:39 PM, Kevin Fenzi wrote: >> >> On Fri, Dec 06, 2019 at 04:49:15PM +, Tom Hughes wrote: >>> On 06/12/2019 16:41, Martin Kolman wrote: On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: > I also installed the Fedora 31 GeoIP packages and ran the geoipupdate, > and that DB has the correct info. IIRC the infra team mentioned some issues with the new geoip database being incompatible with how the service is currently implemented, resulting in being stuck with an outdated database until this is resolved. >>> >>> Sounds like it maybe doesn't have support for GeoLite2 and is using the >>> old MaxMind GeoLite Legacy databases which haven't been updated since >>> the start of this year. >> >> Yes, that is exactly the case. >> >> We recently looked at this to see if we could retire the service, but it >> looks like it's still needed, so we need to figure out how to get cycles >> to update it. >> >> If someone wants to work on this, let us know! >> >> kevin >> ___ >> infrastructure mailing list -- infrastructure@lists.fedoraproject.org >> To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org >> Fedora Code of Conduct: >> https://docs.fedoraproject.org/en-US/project/code-of-conduct/ >> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines >> List Archives: >> https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
I’m interested in looking at this. Is this the script? https://github.com/fedora-infra/geoip-city-wsgi/blob/master/geoip-city.wsgi Assuming that’s the one, it looks like we need to replace GeoIP with geoip2 and wrap the geoip2 data in a structure to match what is currently being returned. Let me know if I’m missing anything. -- kevin >> On Dec 6, 2019, at 6:39 PM, Kevin Fenzi wrote: > On Fri, Dec 06, 2019 at 04:49:15PM +, Tom Hughes wrote: >>> On 06/12/2019 16:41, Martin Kolman wrote: On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: I also installed the Fedora 31 GeoIP packages and ran the geoipupdate, and that DB has the correct info. >>> IIRC the infra team mentioned some issues with the new geoip database >>> being incompatible with how the service is currently implemented, >>> resulting in being stuck with an outdated database until this is resolved. >> >> Sounds like it maybe doesn't have support for GeoLite2 and is using the >> old MaxMind GeoLite Legacy databases which haven't been updated since >> the start of this year. > > Yes, that is exactly the case. > > We recently looked at this to see if we could retire the service, but it > looks like it's still needed, so we need to figure out how to get cycles > to update it. > > If someone wants to work on this, let us know! > > kevin > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Fri, Dec 06, 2019 at 04:49:15PM +, Tom Hughes wrote: > On 06/12/2019 16:41, Martin Kolman wrote: > > On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: > > > > > I also installed the Fedora 31 GeoIP packages and ran the geoipupdate, > > > and that DB has the correct info. > > > > IIRC the infra team mentioned some issues with the new geoip database > > being incompatible with how the service is currently implemented, > > resulting in being stuck with an outdated database until this is resolved. > > Sounds like it maybe doesn't have support for GeoLite2 and is using the > old MaxMind GeoLite Legacy databases which haven't been updated since > the start of this year. Yes, that is exactly the case. We recently looked at this to see if we could retire the service, but it looks like it's still needed, so we need to figure out how to get cycles to update it. If someone wants to work on this, let us know! kevin signature.asc Description: PGP signature ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Fri, 6 Dec 2019 at 11:41, Martin Kolman wrote: > > On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: > > When installing Fedora 31 on a system, I noticed that anaconda defaulted > > to US/Pacific for the time zone, rather than the correct US/Central. > > I'm on a Google Fiber connection, and when I check Fedora's service at > > https://geoip.fedoraproject.org/city I get the info for their HQ in > > Mountain View. I'm pretty sure I got my proper location in the past. > > > > What geoIP service is Fedora using for this? > AFAIK the service is run as part of the Fedora infrastrucuture, due to > its potentially sensitive nature (every manual installation that has > network access will try to reach this API). It is not a third party provided > API. Basically the tool is using an old GeoIP2 database from when that database was still maintained (so last May?). To use the libmaxminddb which has the newer data, a porting effort would be needed to rewrite the geoip.fedoraproject.org to that. Because of all the other 'it must be done now' work it has been deprioritized. Since we do not have the resources to fix this, we are actually talking about dropping it altogether. -- Stephen J Smoogen. ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: Issue with Fedora GeoIP service
On Fri, 2019-12-06 at 08:38 -0600, Chris Adams wrote: > When installing Fedora 31 on a system, I noticed that anaconda defaulted > to US/Pacific for the time zone, rather than the correct US/Central. > I'm on a Google Fiber connection, and when I check Fedora's service at > https://geoip.fedoraproject.org/city I get the info for their HQ in > Mountain View. I'm pretty sure I got my proper location in the past. > > What geoIP service is Fedora using for this? AFAIK the service is run as part of the Fedora infrastrucuture, due to its potentially sensitive nature (every manual installation that has network access will try to reach this API). It is not a third party provided API. > When I check MaxMind's > site, they give the correct info for both my IPv4 and IPv6 addresses > (which BTW the Fedora geoIP lookup doesn't have a v6 address so only > checks v4). > > I also installed the Fedora 31 GeoIP packages and ran the geoipupdate, > and that DB has the correct info. IIRC the infra team mentioned some issues with the new geoip database being incompatible with how the service is currently implemented, resulting in being stuck with an outdated database until this is resolved. But I'm sure the people actually running this will know more, so CCing the Fedora infra list. > -- > Chris Adams > ___ > devel mailing list -- de...@lists.fedoraproject.org > To unsubscribe send an email to devel-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/de...@lists.fedoraproject.org ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org