why am I getting: "HTTP Error 500.30 error" when publishing the Blazor server-side site?

SaeedP

Well-known member
Joined
Oct 21, 2020
Messages
96
Programming Experience
3-5
Hello,

I've made my web app on Blazor server-side and I'm trying to publish it on a windows server. I tried different methods to publish but all came to the same conclusion.

HTTP Error 500.30 - ANCM In-Process Start Failure

Why am I having this problem? You can see the result on mangoscarf.com.

regards,

Saeed
 
I said enable both of them. See post #12.
 
But both of these methods should be written in web.confing:

C#:
<aspNetCore ...>
  <handlerSettings>
    <handlerSetting name="debugLevel" value="file" />
    <handlerSetting name="debugFile" value="c:\temp\ancm.log" />
  </handlerSettings>
</aspNetCore>

and:

C#:
<aspNetCore processPath="dotnet"
      arguments=".\MyApp.dll"
      stdoutLogEnabled="false"
      stdoutLogFile=".\logs\stdout"
      hostingModel="InProcess">
  <environmentVariables>
    <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Development" />
  </environmentVariables>
</aspNetCore>

While blazor server side doesn't have web.cofig file!
 
If you are publishing your Blazor Server App correctly, you should have one. It should be in the bin\Release\net5.0\publish directory if you are publishing to a folder. If you are publishing to IIS using a web deploy package, it'll be compressed in the deployment file.

Anyway, based on your post #10, that file at the bottom of the screenshot looks to be your web.config file.
 
If you are publishing your Blazor Server App correctly, you should have one. It should be in the bin\Release\net5.0\publish directory if you are publishing to a folder. If you are publishing to IIS using a web deploy package, it'll be compressed in the deployment file.

Anyway, based on your post #10, that file at the bottom of the screenshot looks to be your web.config file.
I understood what you say. After the project was published I will place these codes in web.config file then what should happen to log.
I mean I should I run a command or what?
 
Then you restart the app pool and try to reproduce the problem.
 
Then you restart the app pool and try to reproduce the problem.
Hello Skydriver,

I made these changes to the web.config:

C#:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <location path="." inheritInChildApplications="false">
    <system.webServer>
      <handlers>
        <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      </handlers>
      <aspNetCore processPath="dotnet" arguments=".\InstaSite1.dll" stdoutLogEnabled="true" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" >

        <environmentVariables>
          <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Development" />
        </environmentVariables>

      </aspNetCore>
    </system.webServer>
  </location>
</configuration>

Thanks. I understood what you say.

regards,
Saeed
 
Last edited:
But both of these methods should be written in web.confing:

C#:
<aspNetCore ...>
  <handlerSettings>
    <handlerSetting name="debugLevel" value="file" />
    <handlerSetting name="debugFile" value="c:\temp\ancm.log" />
  </handlerSettings>
</aspNetCore>

and:

C#:
<aspNetCore processPath="dotnet"
      arguments=".\MyApp.dll"
      stdoutLogEnabled="false"
      stdoutLogFile=".\logs\stdout"
      hostingModel="InProcess">
  <environmentVariables>
    <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Development" />
  </environmentVariables>
</aspNetCore>

While blazor server side doesn't have web.cofig file!
Sorry for taking the time but have two questions:
1. I used this code but can't find any log file. Where should I look for it exactly?
Here is my code:

C#:
?xml version="1.0" encoding="utf-8"?>
<configuration>
  <location path="." inheritInChildApplications="false">
    <system.webServer>
      <handlers>
        <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      </handlers>

      <aspNetCore processPath="dotnet" arguments=".\BlazorPublishTest.dll" stdoutLogEnabled="true" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" >

      <environmentVariables>
        <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Development" />
      </environmentVariables>

        <handlerSettings>
          <handlerSetting name="debugLevel" value="file" />
          <handlerSetting name="debugFile" value="c:\temp\ancm.log" />
        </handlerSettings>

      </aspNetCore>


    </system.webServer>
  </location>
</configuration>
2.I noticed in my blazor sites Bootstrap doesn't work. Even I deployed the Microsft sample page for blazor and uploaded it, even there Bootstrap doesn't work!
Do you think what should be the reason? the site: mangoscarf.com
 
Last edited:
On lines 9 and 17, you specified where you want your log files. How can you say that you don't know where to look for your log files? Did you not understand the code that you wrote/copied?
 
Last I checked, people had to jump through lots of hoops to get Bootstrap to work with Blazor. It's because of the way Blazor works. There some solutions float out there for how to get the two frameworks to work together. Did you follow one of those solutions? Can you share a link to the documentation you used to try to make it work?
 
No, I didn't think it may need a solution and used non of them. Because I read Microsoft sample for Blazor and taught it works with bootstrap!
on there Bootstrap is used! but when I publish it even that sample doesn't work.

As a final question: Do you think there is no problem that the index file does not exist? but it the main file exists?

regards,
 
You maybe confusing ASP.NET MVC with Blazor. Again, please provide a link to the Microsoft sample Blazor app that uses Bootstrap.

No, there no need for an index file. Everything that is in the publish folder is everything that needs to be deployed to get a running program.
 
Last edited:
I mean the one when you start a project with blazor, starts working. The name is the weather forecast.
 
Back
Top Bottom