Azure Web 应用程序未处理的异常

Azure web app unhandled exception

我已经在 Azure 上部署了一个 MVC5 应用程序作为 Web 应用程序。我需要配置 Web 应用程序,以便它在抛出未处理的异常时写入日志。日志应包含异常消息。是否可以在 Azure Web 应用程序中执行?有没有人如何配置这个?谢谢。

您只需为您的 Web 应用程序启用 'Detailed Error Messages'。 This article 提供有关各种日志记录选项的详细信息。

错误文件在 /LogFiles/DetailedErrors/ 下创建(最好通过 Kudu Console 访问)。