22

If I don't have a working connection to MongoDB and I don't want to use xDB functionality. Currently, my logs are being filled with errors.

What is the configuration needed to disable xDB?

1
  • 2
    what is the sitecore version ? Commented Oct 4, 2016 at 11:59

4 Answers 4

24

For Sitecore 8.1 and later:

Per Sitecore documentation, you can run in "CMS-only" mode:

To run CMS-only mode, you must set the Xdb.Enabled configuration setting to false in the Sitecore.Xdb.config configuration file. https://doc.sitecore.net/sitecore_experience_platform/setting_up__maintaining/experience_management/experience_management_an_overview

For Sitecore 8.0:

There is a knowledge base article describing how to run Sitecore 8.0 without MongodDB, listing these steps:

Configuration Instructions To Disable XDB

Step 1: Disable analytics:

Go to /App_Config/Include/Sitecore.Analytics.config and set Analytics.Enabled to false:

<setting name="Analytics.Enabled" value="false" />

Step 2: Comment out analytics related connection strings:

Go to /App_Config/ConnectionStrings.config and comment out, or remove, the following connection strings:

<add name="analytics" connectionString="mongodb://localhost/analytics" />
<add name="tracking.live" connectionString="mongodb://localhost/tracking_live" />
<add name="tracking.history" connectionString="mongodb://localhost/tracking_history" />
<add name="tracking.contact" connectionString="mongodb://localhost/tracking_contact" />
<add name="reporting" connectionString="user id=user;password=password;Data Source=(server);Database=Sitecore_Analytics" />

The process is not as clean (for example, the system writes error messages to the log), and the KB article documents how Sitecore functionality is impacted.

4
  • 1
    It looks like you're mixing up pre-8.1 and post-8.1 configuration settings. In the past, it was Analytics.Enabled, these days it's Xdb.Enabled. Commented Oct 4, 2016 at 14:18
  • I took this directly from Sitecore documentation, and I do make this distinction. I will improve the formatting to call it out better, however. Commented Oct 4, 2016 at 15:28
  • I see what you mean now! Yes, reformatting will help. Commented Oct 4, 2016 at 15:30
  • 3
    Done! I also corrected Sitecore's typo. The doc has "Xdb.enabled", but the actual setting is "Xdb.Enabled", as you point out. I figured it made more sense to show the correct setting then copy Sitecore's mistake. Commented Oct 4, 2016 at 15:49
16

Starting from Sitecore 8.1, the settings that disable xDB have changed.

The settings are now located in Sitecore.Xdb.config. There are two boolean settings:

  • Xdb.Enabled — if you set this to false, Sitecore will not store any data in MongoDB.
  • Xdb.Tracking.Enabled — if you set this to false, there will be no in-memory tracking of website users and their actions.

Using these two settings, you can fine-tune the way in which you want to disable marketing, tracking and reporting functionality.

Please refer to the official documentation for more information:

The CMS-only mode configuration settings

CMS-only mode compatibility

Disabling xDB and the Xdb tracker

(please note that there is an error on the above page: the setting is actually called Xdb.Tracking.Enabled, not Xdb.Tracker.Enabled)

1
  • Links are 404'ing
    – jrap
    Commented Apr 17, 2019 at 13:59
3

Please note, as the KB article describes, that disabling the xDB will limit the functionality of your Sitecore installation, not only with regards to Experience Analytics. Certain features will be unavailable, e.g. the rules engine (even for non-analytics based rules).

Also, certain modules (WFFM) requires an xDB connection unless you implement a custom data store for form submission data.

1
  • 2
    Sitecore 8.1 now comes with a SQL data store for form results, and you can set the config to use sqlFormsDataProvider instead: citizensitecore.com/2016/05/11/…
    – jammykam
    Commented Oct 4, 2016 at 16:04
0

C:\inetpub\wwwroot\[local]\App_Config\Sitecore\Marketing.xDB\Sitecore.Xdb

Set these 2 values to false:

<setting name="Xdb.Enabled" value="false" />
<setting name="Xdb.Tracking.Enabled" value="false" />

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.