0

I'm trying to run my dotnet core app in IIS Clustered environment. It runs perfectly when shared configuration is disabled. But soon I enable shared configuration, the application fails to start, and gives error:

HTTP Error 500.21 - Internal Server Error

Handler "ExtensionlessUrl-Integrated-4.0" has a bad module "ManagedPipelineHandler" in its module list

I had been looking for the solution since few days, but nothing worked for me. Mostly posts at SO ask to install/reinstall .NET 4/4.5 etc, but this isn't applicable in my case, as it is already updated.

Following are the concerned section of my configuration (I can provide more if needed)

Web.config:

...    
<handlers>
  <remove name="WebDAV" />
  <remove name="ExtensionlessUrl-Integrated-4.0" />
  <add name="ExtensionlessUrl-Integrated-4.0" path="*." verb="GET,HEAD,POST,DEBUG,DELETE,PUT" type="System.Web.Handlers.TransferRequestHandler" />
</handlers> ...

Shared applicationHost.config:

<handlers>
...
 <add name="ExtensionlessUrlHandler-ISAPI-4.0_32bit" path="*." verb="GET,HEAD,POST,DEBUG" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersionv4.0,bitness32" responseBufferLimit="0" />
 <add name="ExtensionlessUrlHandler-ISAPI-4.0_64bit" path="*." verb="GET,HEAD,POST,DEBUG" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersionv4.0,bitness64" responseBufferLimit="0" />
 <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="GET,HEAD,POST,DEBUG" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" responseBufferLimit="0" />
 <add name="StaticFile" path="*" verb="*" modules="StaticFileModule,DefaultDocumentModule,DirectoryListingModule" resourceType="Either" requireAccess="Read" />
</handlers>
...
...
<modules>
  ...
  <add name="ApplicationInitializationModule" lockItem="true" />
  <add name="AspNetCoreModule" />
  <add name="RewriteModule" />
  <add name="ApplicationRequestRouting" />
</modules>

Is there something I am missing? The app runs fine when disable shared configuration of IIS, or when run through .exe. So I believe the required features are installed. Is there any feature/package specifically required for shared configuration case? Please guide.

Zeeshan
  • 2,884
  • 3
  • 28
  • 47
  • Have you changed your anonymous user and application pool to a domain user that have permission to access the shared path? Besides, have you tried this %windir%\\Microsoft.NET\\Framework64\\v4.0.30319\\aspnet\_regiis.exe -i? – Jokies Ding Jun 25 '20 at 09:43
  • #1. Yes, the domain user has permissions. #2. Yes, but it said something like 'operation is not valid because it is already up to date' (not exact words). I doubt this registration thing is only for older versions of IIS, ans SO posts which mention of this are from around 2012, 2014, etc. – Zeeshan Jun 25 '20 at 12:57

0 Answers0