Skip to Content
Menu
This question has been flagged
3 Replies
4075 Views

So i installed maxmind/geoipupdate and configured that so it updates properly. Then geoip2 python module. Added "geoip_database = /var/lib/GeoIP/GeoLite2-City.mmdb" to odoo config and it just refuses to work. Even tried "odoo-bin  --geoip-db=/var/lib/GeoIP/GeoLite2-City.mmdb"

So going trough the steps in documentation just gives me empty brackets even if i bypass the proxy, and the ip is passed properly to the server when checking logs.

Am i missing some step here?


Avatar
Discard

Hi Kim, Did you ever resolve this? im having the same problem with empty brackets.. Have updated everything, followed all the steps, and still empty brackets :(

Author Best Answer

actually yes. It works fine if i had geoip installed and added to the odoo conf 

(geoip_database = /var/lib/GeoIP/GeoLite2-City.mmdb)

before creating or duplicating the db. maybe its some strange bugg because it refused to work if i tried to add it to the server after the odoo instance was already running.


Not enough to just stop odoo service. you need to create the database after the geoip application is installed on the server and the config added to odoo conf. 

Avatar
Discard

Thanks Kim. I’ll give that a go.
So do you mean:
Stop the Odoo service.
Then download the db into place.
Then restart the Odoo service ?

Many thanks.

Best Answer

Install geoip2 Python library. pip install geoip2.

Download the GeoLite2 City database. You should end up with a file called GeoLite2-City.mmdb.

Move the file to the folder /usr/share/GeoIP/ mv ~/Downloads/GeoLite2-City.mmdb /usr/share/GeoIP/

Restart the server.


Regards,
J Wick

Avatar
Discard
Best Answer

You can follow this link https://www.odoo.com/documentation/15.0/applications/websites/website/publish/on-premise_geo-ip-installation.html

If it's not work then you need to check your odoo configuration. Maybe something missing.

Avatar
Discard