Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Error when trying to setup 2nd ADXStudio Portal

(0) ShareShare
ReportReport
Posted on by 30

Hello,

We're attempting to setup a second ADXStudio portal to link in CRM - we copied the sample MasterPortal (removed the settings.xml) created the site in IIS, the app pool was created but using the same .NET CLR 4.0.30319 as on the other portal. We load the URL, input our connection settings to link to CRM, it asks what type of portal, we've chosen Customer Portal and Partner as separate tests, but get an Internal server error.  The event viewer shows issue with "Could not load file or assembly 'Microsoft.IdentityModel.Protocol.Extensions". Here is the error in detail:

Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 5/10/2017 4:37:25 PM
Event time (UTC): 5/10/2017 8:37:25 PM
Event ID: 45c12a7796104d46885d802b38a7512b
Event sequence: 2
Event occurrence: 1
Event detail code: 0

Application information:
Application domain: /LM/W3SVC/3/ROOT-3-131389222436577656
Trust level: Full
Application Virtual Path: /
Application Path: D:\Program Files (x86)\Adxstudio\XrmPortals\7.0.0021\Samples\MasterPortalMS\
Machine name: BLAH 

Process information:
Process ID: 7648
Process name: w3wp.exe
Account name: IIS APPPOOL\portalms

Exception information:
Exception type: TargetInvocationException
Exception message: Exception has been thrown by the target of an invocation.
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
at Owin.Loader.DefaultLoader.<>c__DisplayClass1.<LoadImplementation>b__0(IAppBuilder builder)
at Microsoft.Owin.Host.SystemWeb.OwinAppContext.Initialize(Action`1 startup)
at Microsoft.Owin.Host.SystemWeb.OwinHttpModule.InitializeBlueprint()
at System.Threading.LazyInitializer.EnsureInitializedCore[T](T& target, Boolean& initialized, Object& syncLock, Func`1 valueFactory)
at Microsoft.Owin.Host.SystemWeb.OwinHttpModule.Init(HttpApplication context)
at System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers)
at System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context)
at System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context)
at System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext)

Could not load file or assembly 'Microsoft.IdentityModel.Protocol.Extensions, Version=1.0.2.31, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
at Adxstudio.Xrm.AspNet.Cms.StartupSettingsManager`4.ToWsFederationOptions(CrmWebsiteSettingCollection settings, String defaultMetdataAddress, String defaultCaption, String defaultWtrealm, String defaultWreply, String[] defaultValidAudiences, Func`3 onRedirectToIdentityProvider, Func`2 onSecurityTokenValidated)
at Adxstudio.Xrm.AspNet.Cms.StartupSettingsManager`4.<ToAcsOptions>d__16.MoveNext()
at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
at Adxstudio.Xrm.AspNet.Cms.StartupSettingsManager`4.Initialize(TWebsite website)
at Adxstudio.Xrm.AspNet.Cms.StartupSettingsManager`4..ctor(TWebsite website, Func`3 regenerateIdentityCallback, PathString loginPath, PathString externalLoginCallbackPath)
at Site.Areas.Account.Models.ApplicationStartupSettingsManager..ctor(ApplicationWebsite website, Func`3 regenerateIdentityCallback, PathString loginPath, PathString externalLoginCallbackPath)
at Site.Startup.ConfigureAuth(IAppBuilder app)
at Site.Startup.Configuration(IAppBuilder app)

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


Request information:
Request URL: http://test.nowhere.com/
Request path: /
User host address: 192.168.x.x
User:
Is authenticated: False
Authentication Type:
Thread account name: IIS APPPOOL\portalms

Thread information:
Thread ID: 7
Thread account name: IIS APPPOOL\portalms
Is impersonating: False
Stack trace: at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
at Owin.Loader.DefaultLoader.<>c__DisplayClass1.<LoadImplementation>b__0(IAppBuilder builder)
at Microsoft.Owin.Host.SystemWeb.OwinAppContext.Initialize(Action`1 startup)
at Microsoft.Owin.Host.SystemWeb.OwinHttpModule.InitializeBlueprint()
at System.Threading.LazyInitializer.EnsureInitializedCore[T](T& target, Boolean& initialized, Object& syncLock, Func`1 valueFactory)
at Microsoft.Owin.Host.SystemWeb.OwinHttpModule.Init(HttpApplication context)
at System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers)
at System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context)
at System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context)
at System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext)

Any ideas to point me in the right direction?

Thanks,

Ed

*This post is locked for comments

  • Verified answer
    Eddieb Profile Picture
    Eddieb 30 on at
    RE: Error when trying to setup 2nd ADXStudio Portal

    This was resolved - we had to modify the web.config (update binding redirects) for the previous site - initially we only made changes on the new site.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,711 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,458 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans