简体   繁体   English

在 Azure 门户中跟踪 System.Diagnostics.Trace 日志

[英]Track System.Diagnostics.Trace logs in Azure portal

In my web application, I use在我的网络应用程序中,我使用

System.Diagnostics.Trace.WriteLine(...);

for diagnostics.用于诊断。 The application is published to an Azure deployment slot.应用程序发布到 Azure 部署槽。 I am wondering where I can find these logs in the Azure Portal (or Visual Studio's cloud explorer).我想知道在 Azure 门户(或 Visual Studio 的云资源管理器)中哪里可以找到这些日志。

You first need to activate the Application Logging:您首先需要激活应用程序日志:

  1. Go to your Web App.转到您的 Web 应用程序。
  2. Go to Monitoring / App Service logs .转至Monitoring / App Service logs
  3. Enable Application Logging and configure it.启用Application Logging并对其进行配置。

应用程序日志

This article can also be useful: https://stackify.com/azure-app-service-log-files/这篇文章也很有用: https : //stackify.com/azure-app-service-log-files/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM