1
votes

Unable to log error in stdout log from ASP.NET Core 2.2 in Azure App Service. The stdout log files is created but empty.

The web.config configuration in <system.webServer>:

<aspNetCore processPath="dotnet" arguments=".\xxx.dll" stdoutLogEnabled="true" stdoutLogFile="\\?\%home%\LogFiles\stdout" hostingModel="InProcess" />      
1

1 Answers

6
votes

The problem can be solved by temporary removing the hostingModel="InProcess" then errors are logged in the stdout log files.

hostingModel="InProcess" removed:

<aspNetCore processPath="dotnet" arguments=".\xxx.dll" stdoutLogEnabled="true" stdoutLogFile="\\?\%home%\LogFiles\stdout" />