Azure Site (Windows) ASP.NET Core 2.2 stdout logging not working and 502.5

0

I have an ASP.NET Core 2.2 site deployed to an Azure Site (App Service? Web Site?) running Windows (10, powershell says). I've installed the ASP.NET Core 2.2 service extension that contains the ancmv2 (I know where the actual DLL is) but I'm not 100% sure it works, so I'm specifying the old ANCM in the web.config.

I have supplied a web.config: <?xml version="1.0" encoding="utf-8"?> <configuration> <location path="." inheritInChildApplications="false"> <system.webServer> <handlers> <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" /> </handlers> <aspNetCore processPath="dotnet" arguments=".\MyApp.dll" stdoutLogEnabled="true" stdoutLogFile="\\?\%HOME%\LogFiles\stdout"
forwardWindowsAuthToken="false" /> </system.webServer> </location> </configuration>

Note that I've tried \?\D:\home\LogFiles\stdout, \?\%home%\LogFiles\stdout, as well as plain "D:\home\LogFiles\stdout" but nothing has worked. Recently.

However, not only do I get a 502.5 when browsing the app, in the eventlog.xml in the LogFiles directory I get the following:

Warning: Could not create stdoutLogFile \\?\home\Logfiles\stdout_12384_201922410542.log, ErrorCode = -2147024893.

I mean, the 502.5 is annoying and stuff, but I would have a chance of fixing it myself if only it gave me console logging. As an additional clue - this is the only other log entry I get:

Application 'MACHINE/WEBROOT/APPHOST/MYAPP' with physical root 'D:\home\site\wwwroot\' failed to start process with commandline '%LAUNCHER_PATH% %LAUNCHER_ARGS%', ErrorCode = '0x80070002' : 0.

This leads me to believe my web.config isn't being read at all, that it would have some dodgy default web.config that it tries to use instead. I have no supporting evidence of this, and Google has nothing for me - but given the thousands of things I've changed, including DELETING the web.config completely without errors changing much, this starts to seem plausible to me.

EDIT - there is no tag for ASP.NET Core. That feels like a pretty huge omission. sadly I don't have the power to rectify.

windows
web.config
azure-web-apps
502-error
stdout
asked on Server Fault Feb 24, 2019 by hrillo666

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0