Sitecore Log File Generation Issue on Azure PaaS

After deploying the Sitecore application on Azure PaaS, I noticed that the physical log files are absent from our PROD CM app service. I can find log files on the day of deployment, but for the subsequent days, the log files are not present on the PROD CM app service.

It appears that whenever I perform a deployment, the old worker process (w3wp) retains an exclusive lock on the log file while shutting down, simultaneously, a new w3wp process is created and attempts to access the same log file. Since the file cannot be used by both processes at the same time, the logging appenders for the new w3wp may not initialize correctly, resulting in no further logging.

For better visibility and clarity, I have raised the concern to Sitecore over a support ticket.

Solution:

The behavior I reported was registered as a bug in the Sitecore bug-tracking system. The bug specifically affects the log file appender after an application pool recycle, which happens after my deployment.

As Workaorund, I need to modify the appendToFile value="false" and also add countDirection value="1" like the below Sitecore configuration:

This will create a new log file on the app pool and the application restart with a sequential number added to the end.

To track the future status of this bug report, please use reference number #383771.

Sitecore developers are currently considering a fix for this issue in the next major release of Sitecore and we can use the reference number to track the future status of the bug report.

azure-cdn-sitecore

Happy Sitecoreing ðŸ˜Š

Comments

Popular posts from this blog

Sitecore Installation Error: Failed to Start Service 'Sitecore Marketing Automation Engine'

Import CSV Data in Sitecore Using PowerShell: Part-3

Sitecore Technology MVP Journey 2022