Azure App Service Console Logs not getting published to log analytics workspace

Senthil, Puviarasu 0 Reputation points
2024-05-10T20:44:38.9466667+00:00

We have our Springboot Java application running in Azure App Service Linux platform.

We have enabled Diagnostic settings in Azure App Service for Azure App Service Console Logs to be sent to Log Analytics Workspace**.** We have also set the App Service Logs to FileSystem.

Even after these settings, our application logs are not available in Log Analytics workspace. With SSH, we could see the console logs available in log files we configured in our Log4j properties.

Note: Only the application console logs are not available in Log analytics workspace. We could see the container logs under /home/LogFiles/default_docker.log in Log Analytics Workspace.

Do we need any further setting for the Application console logs to be available in log analytics workspace?

Thanks in advance!

Diagnostic Setting: Screenshot 2024-05-10 at 3.35.02 PM App Service Logs:

Screenshot 2024-05-10 at 3.35.32 PM

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,026 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. hossein jalilian 4,205 Reputation points
    2024-05-11T00:50:29.96+00:00

    Thanks for posting your question in the Microsoft Q&A forum.

    To troubleshoot this issue, consider the following steps:

    • Verify that your application's log level is set to a level that will include the console logs (DEBUG, INFO,...). ensure that the log verbosity is set appropriately to capture the desired level of detail in the logs.
    • Check your application's log configuration (log4j.properties, logback.xml) and ensure that the console appender is properly configured to log to the desired output.
    • Confirm that the console logs are being written to the correct location specified in the Diagnostic settings

    Create a simple Spring Boot application and deploy it to the Azure App Service. enable the Diagnostic settings and check if the console logs are being captured in the Log Analytics workspace. this will help you determine if the issue is specific to your application or a general configuration problem.


    Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful

    1 person found this answer helpful.
    0 comments No comments