HTTP Error 500.35 - ASP.NET Core does not support multiple apps in the same app pool
Common solutions to this issue:
Select a different app pool to host this app.
- Check the system event log for error messages
- Enable logging the application process' stdout messages
- Attach a debugger to the application process and inspect
When i have try to host my .NET 5 Core Applilcation in IIS,this types of error has been occured.
Solved this issue from .csproj file
Open the .csproj file and add the below property to apply the proper hosting model.
Solved this issue from web.config
In ASP.NET Core apps we don't have web.config so first, we have to publish your applilcation or app and in the published folder you can see there your web.config the file generated by .NET 5 Core. Now published the applicationi you have created earlier and open the config file.like as given below.
<?xml version="1.0" encoding="utf-8"?>
<location path="." inheritInChildApplications="false">
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
<aspNetCore processPath="dotnet" arguments=".\DotNetCoreApp.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="OutOfProcess" /> </system.webServer>
In the given above code i have mentioned earlier from .NET 5 Core , the In-process hosting model is the default model. So if you want to change it to other i.e. Out -of-process then you just need to change hostingModel="OutOfProcess".
- Close your solution
- Delete applicationhost.config in folder .vs or delete the whole .vs folder.
- The .vs is a hidden folder and is next to your solution file usually.
- Restart your solution again