Sitecore db connection issue

 

We faced the below error after installing the sitecore jss module 12.0 for sitecore 9.2.

Note: the sitecore we use is below 9.0. But we installed jss 12.0. This error was face when reactjs.net package was installed.

Please suggest.

Server Error in '/' Application.


Could not load file or assembly 'Microsoft.Extensions.DependencyInjection.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

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.IO.FileLoadException: Could not load file or assembly 'Microsoft.Extensions.DependencyInjection.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

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.


Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.Extensions.DependencyInjection.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' could not be loaded.

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].


Stack Trace:

[FileLoadException: Could not load file or assembly 'Microsoft.Extensions.DependencyInjection.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)]
   System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type) +0
   System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName) +96
   System.Type.GetType(String typeName) +62
   Sitecore.DependencyInjection.<>c.<GetServicesConfigurators>b__2_0(XmlNode x) +114
   System.Linq.WhereSelectEnumerableIterator`2.MoveNext() +241
   Sitecore.DependencyInjection.BaseServicesConfiguratorFactory.Configure(IServiceCollection serviceCollection) +193
   Sitecore.DependencyInjection.BaseServicesConfiguratorFactory.Configure(IServiceCollection serviceCollection) +171
   Sitecore.DependencyInjection.BaseServiceProviderBuilder.ConfigureServiceCollection() +142
   Sitecore.DependencyInjection.ServiceLocator.ConfigureServiceProvider() +225
   Sitecore.DependencyInjection.ServiceLocator.get_ServiceProvider() +513
   Sitecore.DependencyInjection.SitecorePerRequestScopeModule..ctor() +13

[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) +142
   System.Activator.CreateInstance(Type type, Boolean nonPublic) +107
   System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes, StackCrawlMark& stackMark) +1476
   System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +186
   System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture) +28
   System.Web.HttpRuntime.CreateNonPublicInstance(Type type, Object[] args) +80
   System.Web.HttpApplication.BuildIntegratedModuleCollection(List`1 moduleList) +234
   System.Web.HttpApplication.GetModuleCollection(IntPtr appContext) +1153
   System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +139
   System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +168
   System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +277
   System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +369

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

 


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4075.0

  • For Sitecore 9.0 You can not use JSS module 12.0
    use Sitecore JavaScript Services 11.x and take the version that match with your Sitecore version.

    The error says you have a decency to the Microsoft.Extensions.DependencyInjection.Abstractions, Version=2.1.1.0 (that is the version Sitecore 9.2 use) Sitecore 9.0 come with  version 1.0.0 of that .dll

    Restore you Sitecore to before the JSS install.
    If you do not have a backup.
    Uninstall the jss module 12.0. that is easy to say, but sins there is no uninstall and your Sitecore is broken.
    delete this files, and you Sitecore should work, the package also installed some items in the Sitecore database. so this is not a complete uninstall.


    You can do that by deleting this files:

    02/04/2020 12:00 PM <DIR> Sitecore
    05/22/2019 10:59 AM 366 Sitecore.JavaScriptServices.MediaRequestHandler.jssconfig
    1 File(s) 366 bytes

    Directory of C:\tmp\jss12\App_Config\Sitecore

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> JavaScriptServices
    05/22/2019 10:59 AM <DIR> LayoutService
    02/04/2020 12:00 PM <DIR> Services.GraphQL
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\App_Config\Sitecore\JavaScriptServices

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 2,408 Sitecore.JavaScriptServices.Apps.config
    05/22/2019 10:59 AM 2,742 Sitecore.JavaScriptServices.Apps.Legacy.disabled
    05/22/2019 10:59 AM 14,669 Sitecore.JavaScriptServices.AppServices.config
    05/22/2019 10:59 AM 754 Sitecore.JavaScriptServices.AppServices.ImportHost.config
    05/22/2019 10:59 AM 7,656 Sitecore.JavaScriptServices.Configuration.config
    05/22/2019 10:59 AM 416 Sitecore.JavaScriptServices.ExampleApp.config.example
    05/22/2019 10:59 AM 574 Sitecore.JavaScriptServices.Forms.config
    05/22/2019 10:59 AM 1,361 Sitecore.JavaScriptServices.Globalization.config
    05/22/2019 10:59 AM 1,100 Sitecore.JavaScriptServices.Media.config
    05/22/2019 10:59 AM 668 Sitecore.JavaScriptServices.Media.Whitelist.config.example
    05/22/2019 10:59 AM 2,437 Sitecore.JavaScriptServices.Tracker.config
    05/22/2019 10:59 AM 3,073 Sitecore.JavaScriptServices.ViewEngine.config
    05/22/2019 10:59 AM 2,567 Sitecore.JavaScriptServices.ViewEngine.Http.config
    05/22/2019 10:59 AM 1,664 Sitecore.JavaScriptServices.ViewEngine.Http.InstanceConfig.example
    05/22/2019 10:59 AM 2,687 Sitecore.JavaScriptServices.ViewEngine.Node.config
    05/22/2019 10:59 AM 2,163 Sitecore.JavaScriptServices.ViewEngine.Node.InstanceConfig.example
    05/22/2019 10:59 AM 482 Sitecore.JavaScriptServices.VisitorIdentification.config
    17 File(s) 47,421 bytes

    Directory of C:\tmp\jss12\App_Config\Sitecore\LayoutService

    05/22/2019 10:59 AM <DIR> .
    05/22/2019 10:59 AM <DIR> ..
    05/22/2019 10:59 AM 882 Sitecore.LayoutService.Analytics.config
    05/22/2019 10:59 AM 9,748 Sitecore.LayoutService.config
    05/22/2019 10:59 AM 3,470 Sitecore.LayoutService.Jss.config
    05/22/2019 10:59 AM 1,629 Sitecore.LayoutService.Mvc.config
    4 File(s) 15,729 bytes

    Directory of C:\tmp\jss12\App_Config\Sitecore\Services.GraphQL

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 11,644 Sitecore.Services.GraphQL.config
    05/22/2019 10:59 AM 18,020 Sitecore.Services.GraphQL.Content.config
    05/22/2019 10:59 AM 3,680 Sitecore.Services.GraphQL.Content.Core.config.example
    05/22/2019 10:59 AM 3,810 Sitecore.Services.GraphQL.Content.Master.config.example
    05/22/2019 10:59 AM 3,700 Sitecore.Services.GraphQL.Content.Web.config.example
    05/22/2019 10:59 AM 1,694 zSitecore.JavaScriptServices.GraphQL.config
    6 File(s) 42,548 bytes

    Directory of C:\tmp\jss12\bin

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 43,520 GraphQL-Parser.dll
    05/22/2019 10:59 AM 337,408 GraphQL.dll
    05/22/2019 10:59 AM 162,736 Sitecore.JavaScriptServices.AppServices.dll
    05/22/2019 10:59 AM 34,224 Sitecore.JavaScriptServices.Configuration.dll
    05/22/2019 10:59 AM 14,256 Sitecore.JavaScriptServices.Core.dll
    05/22/2019 10:59 AM 31,152 Sitecore.JavaScriptServices.Forms.dll
    05/22/2019 10:59 AM 20,400 Sitecore.JavaScriptServices.Globalization.dll
    05/22/2019 10:59 AM 33,200 Sitecore.JavaScriptServices.GraphQL.dll
    05/22/2019 10:59 AM 18,864 Sitecore.JavaScriptServices.Install.dll
    05/22/2019 10:59 AM 20,400 Sitecore.JavaScriptServices.Media.dll
    05/22/2019 10:59 AM 28,592 Sitecore.JavaScriptServices.Tracker.dll
    05/22/2019 10:59 AM 74,160 Sitecore.JavaScriptServices.ViewEngine.dll
    05/22/2019 10:59 AM 27,568 Sitecore.JavaScriptServices.ViewEngine.Http.dll
    05/22/2019 10:59 AM 33,200 Sitecore.JavaScriptServices.ViewEngine.Node.dll
    05/22/2019 10:59 AM 49,584 Sitecore.JavaScriptServices.ViewEngine.NodeServices.dll
    05/22/2019 10:59 AM 13,232 Sitecore.LayoutService.Analytics.dll
    05/22/2019 10:59 AM 69,040 Sitecore.LayoutService.dll
    05/22/2019 10:59 AM 40,368 Sitecore.LayoutService.Mvc.dll
    05/22/2019 10:59 AM 130,480 Sitecore.Services.GraphQL.Content.dll
    05/22/2019 10:59 AM 1,902,000 Sitecore.Services.GraphQL.dll
    05/22/2019 10:59 AM 61,872 Sitecore.Services.GraphQL.NetFxHost.dll
    05/22/2019 10:59 AM 113,944 System.Reactive.Core.dll
    05/22/2019 10:59 AM 22,808 System.Reactive.Interfaces.dll
    05/22/2019 10:59 AM 709,400 System.Reactive.Linq.dll
    24 File(s) 3,992,408 bytes

    Directory of C:\tmp\jss12\sitecore

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> Copyrights
    02/04/2020 12:00 PM <DIR> shell
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\sitecore\Copyrights

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 1,116 .NET Core_MIT.TXT
    05/22/2019 10:59 AM 1,094 .NET Standard_MIT.txt
    05/22/2019 10:59 AM 574 AspNetKatana_Apache 2.0.txt
    05/22/2019 10:59 AM 593 aspnet_Apache 2.0.txt
    05/22/2019 10:59 AM 1,077 JavaScriptViewEngine_MIT.txt
    5 File(s) 4,454 bytes

    Directory of C:\tmp\jss12\sitecore\shell

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> Override
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\sitecore\shell\Override

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> Applications
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\sitecore\shell\Override\Applications

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> Layouts
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\sitecore\shell\Override\Applications\Layouts

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    02/04/2020 12:00 PM <DIR> DeviceEditor
    0 File(s) 0 bytes

    Directory of C:\tmp\jss12\sitecore\shell\Override\Applications\Layouts\DeviceEditor

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 4,244 DeviceEditor.xml
    1 File(s) 4,244 bytes

    Directory of C:\tmp\jss12\Views

    02/04/2020 12:00 PM <DIR> .
    02/04/2020 12:00 PM <DIR> ..
    05/22/2019 10:59 AM 97 JssApp.cshtml
    1 File(s) 97 bytes