Friday, October 9, 2015

My Experience on Sitecore IP Geolocation service

Recently we had a task of configuring Sitecore IP Geolocation service with our existing Sitecore website. Even though the configuration is straight forward with good documentation, we were NOT able to configure Personalization to work properly.

i.e.
When we try to add a personalization with GEO IP rules, it didn't detect the country/IP information fro IP Geolocation service
Some sample configurations can be found in the following document
https://doc.sitecore.net/sitecore%20experience%20platform/ip%20geolocation/getting%20started%20with%20sitecore%20ip%20geolocation%20service


INSTALLATION


Follow the installation steps in the following document
https://doc.sitecore.net/Sitecore%20Experience%20Platform/IP%20Geolocation/Setting%20up%20Sitecore%20IP%20Geolocation#_Install_and_enable

NOTE :
If you don't have a way to configure your firewall settings to allow requests to the service by domain names, then you need to allow all the IPs for Microsoft Azure Datacenter, defined in the following document

https://msdn.microsoft.com/en-us/library/azure/dn175718.aspx

That contains larger number of IPs and they can be changed time to time

TROUBLESHOOTING


If your IP is not getting resolved correctly (or your personalizations are not working correctly), then try to use the 'TestIp.aspx' file in the following kb.sitecore.net artible and try to see if your IP is correction detected by Sitecore IP Geolocation services.

https://kb.sitecore.net/articles/798498


NOTE:
This TestIp.aspx page directly contacts/users GeoIP service and get the necessary data for the requested IP.

That is not the case when this service used in Sitecore website

Quote from doc.sitecore.net
When IP information is requested, the following steps are performed:
  • Lookup of IP information in the memory cache;
  • Lookup of IP information in the database;
  • Request to the Geolocation service.

Quote from Sitecore Support
When IP is resolved, the Geo Data (Country, City, etc) corresponded to the IP is searched in cache and then analytics database. If these storage contain data even incorrect, the service won't be used at all.

So, if you are continuously receiving incorrect information, then it is good to do following steps

1) Check whether the correct IP information is stored in the Analytics database:
  • Sitecore 7.5 - Sitecore 8.x: the "GeoIps" collection, Collection database (MongoDB)
  • Sitecore 6.4.1 - Sitecore 7.2: the "GeoIps" table, Analytics database (SQL)
And if incorrect Geo location information stared for a given IP, deleted that incorrect IP info from the GeoIps table/collection and do an app pool reset (to clear application cache). 
Correct Geo information will be cached/stored again in the next request.

2) Use proxy client (like Hide My Ass) to change your IP and try with a new IP


1 comment:

  1. This comment has been removed by a blog administrator.

    ReplyDelete