# GeoIP block is not working

**URL:** <https://community.ipfire.org/t/geoip-block-is-not-working/814>\
**Category:** Network\
**Created:** [2 January 2020 14:19 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814 "2020-01-02T14:19:18Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![rob\_v](https://community.ipfire.org/user_avatar/community.ipfire.org/rob_v/32/234_2.png) [@rob\_v](https://community.ipfire.org/u/rob_v)\
**Post date:** [2 January 2020 14:19 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/1 "2020-01-02T14:19:18Z")

</div>

I did a new install and I am trying to solve a problem with the network configuration.  
I cant get GeoIP blocking working, the country list is empty.

 ![Schermafdruk%20van%202020-01-02%2013-05-23](https://community.ipfire.org/uploads/default/original/1X/89b1c2b9d9555c5c7cf45030d55ec6477fb2380e.png)

I did “xt\_geoip\_update” in bash, but this did not help to update the list.

update:  
found this on the [MaxMind.com](http://MaxMind.com) website

Starting **December 30, 2019,** downloads will no longer be served from our [public GeoLite2 page](https://dev.maxmind.com/geoip/geoip2/geolite2/), from [geolite.maxmind.com/download/geoip/database/\*](http://geolite.maxmind.com/download/geoip/database/*), or from any other public URL. See the section below for steps on how to migrate to the new download mechanism.

[https://blog.maxmind.com/2019/12/](https://blog.maxmind.com/2019/12/)

is this the problem?

can you help me?  
thanks

---

<div class="post-metadata">

**Author:** ![bbitsch](https://community.ipfire.org/user_avatar/community.ipfire.org/bbitsch/32/7420_2.png) [@bbitsch](https://community.ipfire.org/u/bbitsch)\
**Post date:** [2 January 2020 20:50 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/2 "2020-01-02T20:50:30Z")

</div>

I fear you are right. ☹  
I’ll post a ticket at [bugzilla](http://bugzilla.ipfire.org)

Update: done. [#12264](https://bugzilla.ipfire.org/show_bug.cgi?id=12264)

---

<div class="post-metadata">

**Author:** ![bbitsch](https://community.ipfire.org/user_avatar/community.ipfire.org/bbitsch/32/7420_2.png) [@bbitsch](https://community.ipfire.org/u/bbitsch)\
**Post date:** [3 January 2020 20:14 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/3 "2020-01-03T20:14:23Z")

</div>

Discussion in Bugzilla shows, that there is no update possible from Maxmind ( because of their EULA! ).  
Thus Geoip blocking will be functional not before the migration to libloc.

OT: the actions of Maxmind remind me to the behaviour of [gutenberg.org](http://gutenberg.org) regarding european copyright. ☹

---

<div class="post-metadata">

**Author:** ![rob\_v](https://community.ipfire.org/user_avatar/community.ipfire.org/rob_v/32/234_2.png) [@rob\_v](https://community.ipfire.org/u/rob_v)\
**Post date:** [3 January 2020 20:40 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/4 "2020-01-03T20:40:38Z")

</div>

thank you for the info  
I have to wait until the migration to libloc before I can use my new router with GeoIP block 😒  
I like the tool  
is there any info when this will happen ?

---

<div class="post-metadata">

**Author:** ![rob\_v](https://community.ipfire.org/user_avatar/community.ipfire.org/rob_v/32/234_2.png) [@rob\_v](https://community.ipfire.org/u/rob_v)\
**Post date:** [5 January 2020 12:50 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/5 "2020-01-05T12:50:50Z")

</div>

I have an old version of the GeoIP database and a few files more copied to my new system and now GeoIP Block seems to work.  
I do not know if I copied all the right files and keep this router for a while as a test system until there is a solution of the developers, 😄

---

<div class="post-metadata">

**Author:** ![bbitsch](https://community.ipfire.org/user_avatar/community.ipfire.org/bbitsch/32/7420_2.png) [@bbitsch](https://community.ipfire.org/u/bbitsch)\
**Post date:** [5 January 2020 14:35 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/6 "2020-01-05T14:35:40Z")

</div>

Answer in Bugzilla: [https://bugzilla.ipfire.org/show\_bug.cgi?id=12264#c3](https://bugzilla.ipfire.org/show_bug.cgi?id=12264#c3)

---

<div class="post-metadata">

**Author:** ![xperimental](https://community.ipfire.org/user_avatar/community.ipfire.org/xperimental/32/16702_2.png) [@xperimental](https://community.ipfire.org/u/xperimental)\
**Post date:** [5 January 2020 15:32 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/7 "2020-01-05T15:32:13Z")

</div>

“We will ship the oldest version of the database…”

Hopefully it will be the latest… 😆

---

<div class="post-metadata">

**Author:** ![bbitsch](https://community.ipfire.org/user_avatar/community.ipfire.org/bbitsch/32/7420_2.png) [@bbitsch](https://community.ipfire.org/u/bbitsch)\
**Post date:** [5 January 2020 15:44 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/8 "2020-01-05T15:44:55Z")

</div>

One more argument against non-native communication. 😉  
SCNR

---

<div class="post-metadata">

**Author:** ![rob\_v](https://community.ipfire.org/user_avatar/community.ipfire.org/rob_v/32/234_2.png) [@rob\_v](https://community.ipfire.org/u/rob_v)\
**Post date:** [5 January 2020 21:03 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/9 "2020-01-05T21:03:43Z")

</div>

I used a database from november 2019 and it seems to work

I was searching on the old forum and there ware a lot of post in the German languish but I didn’t understand it well enough to know what to do, sometime a translation website is a useful tool, there is a lot of information on the old forum, so if that can stay online in a read-only mode, I think that will be helpful.  
English is not my native languish but I can understand it enough to find a solution for this kind of problems. 😀

---

<div class="post-metadata">

**Author:** ![anon42188109](https://community.ipfire.org/letter_avatar_proxy/v4/letter/a/94ad74/32.png) [@anon42188109](https://community.ipfire.org/u/anon42188109)\
**Post date:** [5 January 2020 22:57 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/10 "2020-01-05T22:57:43Z")

</div>

which file(s) do I need to copy?  
I built another ipfire for a colleague yesterday and she’d like to have the db. My ipfire has it.  
thx

---

<div class="post-metadata">

**Author:** ![rob\_v](https://community.ipfire.org/user_avatar/community.ipfire.org/rob_v/32/234_2.png) [@rob\_v](https://community.ipfire.org/u/rob_v)\
**Post date:** [6 January 2020 20:02 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/11 "2020-01-06T20:02:01Z")

</div>

I had to copy 2 folders, one is called GeoIP and you find it in  
/var/lib/GeoIP (13 files)  
and the other is called xt\_geoip and found it in  
/usr/share/xt\_geoip (508 files).

good luck

---

<div class="post-metadata">

**Author:** ![dragonslayr](https://community.ipfire.org/user_avatar/community.ipfire.org/dragonslayr/32/16814_2.png) [@dragonslayr](https://community.ipfire.org/u/dragonslayr)\
**Post date:** [9 January 2020 20:26 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/12 "2020-01-09T20:26:48Z")

</div>

Thanks for the info. This worked for me.

install rsync using pakfire on both systems  
from the box that has a good database:

rsync -av /var/lib/GeoIP/ 123.123.123.123:/var/lib/GeoIP/  
rsync -av /usr/share/xt\_geoip/ 123.123.123.123:/usr/share/xt\_geoip/

---

<div class="post-metadata">

**Author:** ![dragonslayr](https://community.ipfire.org/user_avatar/community.ipfire.org/dragonslayr/32/16814_2.png) [@dragonslayr](https://community.ipfire.org/u/dragonslayr)\
**Post date:** [9 January 2020 20:54 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/13 "2020-01-09T20:54:36Z")

</div>

Or maybe easier for the moment.  
Seems to be available here: (use at your own risk)  
[https://ivre.rocks/data/geolite/GeoLite2-Country-CSV.zip](https://ivre.rocks/data/geolite/GeoLite2-Country-CSV.zip)

change the line in /usr/local/bin/xt\_geopip\_update  
DL\_URL=https://ivre.rocks/data/geolite

Might be easier…

---

<div class="post-metadata">

**Author:** ![roberto](https://community.ipfire.org/user_avatar/community.ipfire.org/roberto/32/8265_2.png) [@roberto](https://community.ipfire.org/u/roberto)\
**Post date:** [10 January 2020 07:55 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/14 "2020-01-10T07:55:36Z")

</div>

YES!!!, this works OK.

Thanks @dragonslayr

Bye.

---

<div class="post-metadata">

**Author:** ![steph78630](https://community.ipfire.org/user_avatar/community.ipfire.org/steph78630/32/8251_2.png) [@steph78630](https://community.ipfire.org/u/steph78630)\
**Post date:** [10 January 2020 13:28 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/15 "2020-01-10T13:28:30Z")

</div>

@dragonslayr, thanks for the tip 🙂

It work, but you have to modify the file : /usr/local/bin/xt\_geoip\_update

---

<div class="post-metadata">

**Author:** ![bbitsch](https://community.ipfire.org/user_avatar/community.ipfire.org/bbitsch/32/7420_2.png) [@bbitsch](https://community.ipfire.org/u/bbitsch)\
**Post date:** [12 January 2020 13:12 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/16 "2020-01-12T13:12:39Z")

</div>

Just for information:  
Core 140 will contain the last available DB from end of December 2019.

---

<div class="post-metadata">

**Author:** ![arne\_f](https://community.ipfire.org/user_avatar/community.ipfire.org/arne_f/32/12760_2.png) [@arne\_f](https://community.ipfire.org/u/arne_f)\
**Post date:** [12 January 2020 15:06 UTC](https://community.ipfire.org/t/geoip-block-is-not-working/814/17 "2020-01-12T15:06:02Z")

</div>

If you are on core139 you can download the already converted DB and install it:

wget [https://source.ipfire.org/source-2.x/GeoIP-LiteCity-1-2csv-xtables-20191217.tar.xz](https://source.ipfire.org/source-2.x/GeoIP-LiteCity-1-2csv-xtables-20191217.tar.xz)  
tar xvaf GeoIP-LiteCity-1-2csv-xtables-20191217.tar.xz -C /

This is the latest database that i have got yet which is still under Creative Commons and not the new EULA.
