Cleaning up log messages for Geo IP Location

Starting with Sitecore 8.1 Geo IP lookup services come pre-installed and configured. All a site owner than need to do is log into the App Center and purchase the service. This is great from an implementer standpoint this is great as it’s one less configuration step that we have to take.

On the downside, if the site owners never purchase the lookup service the log will quickly clutter with ERROR messages.

ManagedPoolThread #12 16:01:15 ERROR Failed to perform GeoIp lookup for dd4795c0-1dca-ea8d-93c4-06d7f7aa5063
Exception: System.Net.WebException
Message: The remote name could not be resolved: ‘discovery-ces.cloud.sitecore.net’
Source: System
at System.Net.HttpWebRequest.GetResponse()
at Sitecore.CES.Client.WebClient.ExecuteRequest(String requestUri)
at Sitecore.CES.Client.ResourceConnector`1.Request(String endpoint, Object[] parameters)
at Sitecore.CES.Discovery.EndpointSource.GetEndpoint(String serviceName)
at Sitecore.CES.GeoIp.SitecoreProvider.GetInformationByIp(String ip)
at Sitecore.Analytics.Lookups.GeoIpManager.GetDataFromLookupProvider(GeoIpHandle geoIpHandle)

The Fix

The fix isn’t hard; all it requires is a simple patch config to disable the lookup service.

<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
    <sitecore>
        <settings>
            <setting name="Analytics.PerformLookup">
                <patch:attribute name="value">false</patch:attribute>
            </setting>
        </settings>
    </sitecore>
</configuration>

For the full details on the lookup service checkout the full documentation at https://doc.sitecore.net/sitecore_experience_platform/setting_up__maintaining/ip_geolocation/setting_up_sitecore_ip_geolocation.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s