FIXED: Initialize action failed for Initialize on class EPiServer.Web.InitializationModule

I just thought I'd share an error I solved. The error is kind of hard to fix because there is very little clues to pinpoint where the error is located. You find the error and log from the solution on the bottom of the page.

Why I got this error

Because of problems with versioning on assemblies in my bin folder I emptied the folder because all assemblies are populated using nuget modules. Because the modules I use, depends on the nuget packages EPiServer.CMS.Core (6.1.379.0) og EPiServer.Framework (6.2.267.1).

Solution

Because the modules included these nuget packages I thought Episerver was installed completely, but after a long debugging time I found that 3 files where missing.

The files that is not installed are:

EPiServer.Licensing.dll
EPiServer.Data.Cache.dll
EPiServer.Shell.UI.dll.

Why these files is not included, I don't know. I might be because the nuget packages have the version 6.1.379.0 and 6.2.267.1 while the files missing have the version 6.2.267.500.

Additionally there was connection problems with the database I used.

The error is as follows:

Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
[NullReferenceException: Object reference not set to an instance of an object.]
   EPiServer.Data.DataInitialization.InitializeCacheProvider() +428
   EPiServer.Data.DataInitialization.Initialize(InitializationEngine context) +113
   EPiServer.Framework.Initialization.InitializationEngine.InitializeModules() +425
   EPiServer.Framework.Initialization.InitializationEngine.Initialize(HostType hostType) +196
   EPiServer.Framework.Initialization.InitializationModule.Initialize(HostType hostType) +266
   EPiServer.Framework.Initialization.InitializationModule.FrameworkInitialization(HostType hostType) +86
   EPiServer.Global..ctor() +89
   EPiServer.Templates.Global..ctor() +28
   ASP.global_asax..ctor() in c:\Users\ig01\AppData\Local\Temp\Temporary ASP.NET Files\root\e7cd8ab3\2f6a245a\App_global.asax.zgx075jk.0.cs:0

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
   System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) +0
   System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) +113
   System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) +232
   System.Activator.CreateInstance(Type type, Boolean nonPublic) +83
   System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes, StackCrawlMark& stackMark) +1136
   System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +128
   System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture) +18
   System.Web.HttpRuntime.CreateNonPublicInstance(Type type, Object[] args) +60
   System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +260
   System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +296

[HttpException (0x80004005): Exception has been thrown by the target of an invocation.]
   System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +9873912
   System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +101
   System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +254

Log4net reports that the error is:
Initialize action failed for Initialize on class EPiServer.Data.DataInitialization, EPiServer.Data, Version=6.2.267.1, Culture=neutral, PublicKeyToken=8fe83dea738b45b7
System.NullReferenceException: Object reference not set to an instance of an object.
InitializationState: transition from Initializing to InitializeFailed.
 
Further information in the log:
2012-10-18 11:32:29,664 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning AjaxMin, Version=4.42.4387.23950, Culture=neutral, PublicKeyToken=21ef50ce11b5d80f since it lacks any refererences to MEF.
2012-10-18 11:32:29,667 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Antlr4.StringTemplate, Version=4.0.6.9004, Culture=neutral, PublicKeyToken=null since it lacks any refererences to MEF.
2012-10-18 11:32:29,669 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Autofac.Configuration, Version=2.5.2.830, Culture=neutral, PublicKeyToken=17863af14b0044da since it lacks any refererences to MEF.
2012-10-18 11:32:29,671 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Autofac, Version=2.5.2.830, Culture=neutral, PublicKeyToken=17863af14b0044da since it lacks any refererences to MEF.
2012-10-18 11:32:29,674 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Brevity, Version=1.1.0.0, Culture=neutral, PublicKeyToken=null since it lacks any refererences to MEF.
2012-10-18 11:32:29,676 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Castle.Core, Version=3.0.0.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc since it lacks any refererences to MEF.
2012-10-18 11:32:29,678 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning dotless.Core, Version=1.3.1.0, Culture=neutral, PublicKeyToken=96b446c9e63eae34 since it lacks any refererences to MEF.
2012-10-18 11:32:29,680 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EcmaScript.NET.modified, Version=0.1.1.0, Culture=neutral, PublicKeyToken=7d53ba4f537753a5 since it lacks any refererences to MEF.
2012-10-18 11:32:29,685 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPi247.TMCore.Templates.XmlSerializers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null since it lacks any refererences to MEF.
2012-10-18 11:32:29,687 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.BaseLibrary, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,690 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.ImageLibrary, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,692 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.Implementation, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,694 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.Log.Analyzers, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,695 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.Log.Core, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,697 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.Lucene, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,698 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.Scheduler.WKTL, Version=5.1.422.4, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,701 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning EPiServer.XmlRpc, Version=6.1.379.0, Culture=neutral, PublicKeyToken=8fe83dea738b45b7 since it lacks any refererences to MEF.
2012-10-18 11:32:29,703 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821 since it lacks any refererences to MEF.
2012-10-18 11:32:29,705 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed since it lacks any refererences to MEF.
2012-10-18 11:32:29,706 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning serviceclient, Version=2.3.0.0, Culture=neutral, PublicKeyToken=da294bc4e1ae447d since it lacks any refererences to MEF.
2012-10-18 11:32:29,709 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning App_global.asax.zgx075jk, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null since it lacks any refererences to MEF.
2012-10-18 11:32:29,711 DEBUG [27] EPiServer.Framework.Initialization.InitializationModule.get_Catalog - Not scanning App_Browsers.avnijcf_, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null since it lacks any refererences to MEF.
2012-10-18 11:32:30,717 INFO [27] EPiServer.Framework.Initialization.InitializationEngine.set_InitializationState - InitializationState: transition from PreInitialize to Initializing.
2012-10-18 11:32:30,737 ERROR [27] EPiServer.Framework.Initialization.InitializationEngine.InitializeModules - Initialize action failed for Initialize on class EPiServer.Data.DataInitialization, EPiServer.Data, Version=6.2.267.1, Culture=neutral, PublicKeyToken=8fe83dea738b45b7
 
 
 
 

 

Problems with XForms when upgrading to CMS 6 R2

If you have problems with xforms read Paul Smiths blogpost:

Problems with XForms when upgrading to CMS 6 R2

ToMappedLink not working with special characters

When populating an asp repeater with links using "ToMappedLink()" title information will not decode special characters on title property. The browser will not show the special character.

Links should therefore be written manually in order to render the title properly

Spell checking in TinyMce.

On previos versions of Episerver, tinymce used Microsoft word for spell checking.
In version 6 it is recommended to use plugins in the browser for spell checking.

For Internet Explorer you have to install IEspell to enable spell checking:
http://download.cnet.com/ieSpell/3000-12512_4-10208550.html?part=dl-ieSpell&subj=uo&tag=button

For firefox users, spell checker is already installed, but for norwegian users
you have to install norwegian dictionary:
https://addons.mozilla.org/en-US/firefox/addon/norsk-bokm%C3%A5l-ordliste/
When this is installed, spell checking should be enabled when using right click
in the tinymce editor.

Access denied

Due to the change of operations service provider, our intranet didn't work no more.
All our computers are registered in a new domain and all users have new usernames.

Our intranet showed the error below saying "Access denied". I tried to change access rights
in web.config to the new domain groups and change access rights in Episerver admin to the new groups but nothing it didn't work.

The resolution was to delete all old history of previous access rights and add "[domain]\Domain Users" instead to inherit to all subpages.

The conclusion is that when access rights is corrupted it's best to start from scratch and add new user rights.


Error message:

Access denied

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: EPiServer.Core.AccessDeniedException: Access denied

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[AccessDeniedException: Access denied]
   EPiServer.PageBase.GetPage(PageReference pageLink) +242
   EPiServer.Web.WebControls.PageTreeData.GetExpandedPages(PageReference pageLink) +191
   EPiServer.Web.WebControls.PageTreeData.get_OpenPages() +101
   EPiServer.Web.WebControls.PageTreeData.get_OpenTopPage() +57
   EPiServer.Web.WebControls.MenuList.CreateChildControls() +318
   EPiServer.Web.WebControls.PageTreeData.DataBind() +269
   Baktrappa.Templates.baktrappa.units.GlobalMenu.OnLoad(EventArgs e) +272
   System.Web.UI.Control.LoadRecursive() +50
   System.Web.UI.Control.LoadRecursive() +141
   System.Web.UI.Control.LoadRecursive() +141
   System.Web.UI.Control.LoadRecursive() +141
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627

Welcome to my Episerver blog

Welcome to my episerver blog.
Here I will post relevant knowledge for my self regarding Episerver.