Microsoft’s Azure Monitor Enhances Container Insights with Multi-Line Logging

Microsoft Azure

Key Takeaways:

  • Microsoft has rolled out Multi-Line Logging support for Azure Monitor – Container Insights.
  • This Multi-Line Logging feature allows IT administrators to collect and store multiple lines of log data into a single entry.
  • This capability could be particularly beneficial for identifying and resolving issues in containerized applications.

Microsoft has announced that Multi-Line Logging support is generally available in Azure Monitor – Container Insights. The new feature enables IT administrators to collect and store multiple lines of log data in a single entry for streamlined analysis of containerized applications.

Azure Monitor is a service that allows organizations to collect, analyze, and monitor data from cloud and on-premises environments. Its Container Insights feature provides detailed insights into the performance and health of applications running in containers. This capability lets administrators collect container logs as well as memory and processor metrics from controllers, containers, and nodes.

Microsoft mentioned that logs are crucial for monitoring and resolving issues in containerized applications. However, the challenge lies in analyzing logs that are spread over multiple lines. For example, when an error occurs in a .NET or Go application, the relevant stack trace could be spread across several log entries.

“With this feature enabled, previously split container logs are stitched together and sent as single entries to the ContainerLogV2 table. This will also help customers save on cost as it is reducing the metadata added on multiple lines. Customers are able see container log lines up to 64 KB (up from the existing 16 KB limit). If the stitched log line is larger than 64 KB, it gets truncated due to Log Analytics limits,” Microsoft explained.

Microsoft's Azure Monitor Enhances Container Insights with Multi-Line Logging
Multi-Line Enabled

Why you should use Multi-Line Logging?

Microsoft has introduced a new feature that allows IT administrators to capture stack traces for applications developed in programming languages, such as .NET, Go, Python, and Java. This feature consolidates all the records into a single one, making it easier to analyze logs and quickly understand the context and details of the error. Microsoft also plans to support more languages and formats in the future.

To get started with Multi-Line Logging, Microsoft recommends that organizations should ensure that the agent is updated to version 3.1.6 or later. The company has provided a step-by-step guide to enable this feature, which can be found in the official blog post.