0

I am attempting to deploy new services to Azure App Service and am getting the following error message on the services:

Error 500.37 screenshot

After doing some research, it seems the most common approach to this problem is to increase the startupTimeLimit, which I have done a couple times and is not resolving this issue.

Here is the section of the web.config file containing the startupTimeLimit increase:

      <aspNetCore processPath="bin\Debug\netcoreapp3.1\TemplateService.Api.exe" arguments="" stdoutLogEnabled="false" hostingModel="InProcess" startupTimeLimit="900">
        <environmentVariables>
          <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Development" />
        </environmentVariables>
      </aspNetCore>

I originally attempted to increase to 300 seconds but that didn't fix it, so I went ahead and upped it to 900 seconds just to see if I could get past this error (which I didn't).

Are there any other ways to resolve this issue if this increase is not fixing it?

BenTen
  • 333
  • 1
  • 5
  • 17
  • If my reply is helpful, please accept it as answer(click on the mark option beside the reply to toggle it from greyed out to fill in.), see https://meta.stackexchange.com/questions/5234/how-does-accepting-an-answer-work – Jason Pan Sep 10 '21 at 07:03

1 Answers1

0

Please restore your web.config to its original state. The settings of

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

are not required.

I can't tell you the reason directly, but I can help you find the error log of the problem. When you see the error log, you can search for it by google to solve the problem.

Troubleshooting

Method 1.

Add ASPNETCORE_ENVIRONMENT=Development on portal, not web.config file. It will show more details in page.

enter image description here

Method 2.

Add stdoutLogFile=".\logs\stdout" in web.config file. And you can find log file in scm site.

For more details, you can read: Enabling ASP.NET Core stdout log (Windows Server).

If you also can't find the reason, you need to use method 3.

Method 3.

① You can Collect .NET Profiler Trace on portal.

For more details, you can refer my answer in below post.

Azure - Unhandled Exception: System.IO.FileNotFoundException

enter image description here

② And you also can check application event logs.

enter image description here

Jason Pan
  • 15,263
  • 1
  • 14
  • 29