question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't enable Application Logging (Blob) on an Azure Function app

See original GitHub issue

I’m trying to enable application logging (level = information, storage settings = an application-logs blob container I just created) on my Azure Function app from the portal but I keep getting the following error:

Key Value
DESCRIPTION Failed to update web app logs settings for **************. There was an error processing your request. Please try again in a few moments.
STATUS Error
TIME Tuesday, February 7, 2017, 7:53:24 AM
CORRELATION IDS 40345302-5727-4f5d-9f28-7bd110a7f976

I tried first a few times without specifying storage information. When I realized I had not specified a blob container I thought it would work but it keeps failing.

It looks like this bug already happened in the past: #397

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:30 (26 by maintainers)

github_iconTop GitHub Comments

2reactions
0xcedcommented, Apr 11, 2017

Thanks, I can see my functions now. I have enabled the application logs and I can see them grow in my chosen blob container. I’m a bit confused though, I see only Sending response: 200.0 OK logs. I thought that the application logs were the one produced with the TraceWriter object provided to the functions.

If I manually run this test function, I don’t see either the info or the error log in the application logs (they are configured at the Information level):

public static void Run(string input, TraceWriter log)
{
    log.Info($"Hello from a test function with input {input}");
    log.Error("A dummy error occurred");
}

Is this expected or is there still something misconfigured somewhere?

0reactions
NikolaMandiccommented, Apr 27, 2018

@0xced you want System.Diagnostics.Trace.TraceError(“Message”); from https://stackoverflow.com/questions/35702341/asp-net-web-application-in-azure-how-to-log-errors

Read more comments on GitHub >

github_iconTop Results From Across the Web

Azure function apps logs not showing
The best way I have found to view the logs is to go into Application Insights for the function itself and then search...
Read more >
Configure monitoring for Azure Functions
Learn how to connect your function app to Application Insights for monitoring and how to configure data collection.
Read more >
Enable diagnostics logging - Azure App Service
To enable application logging for Windows apps in the Azure portal, navigate to your app and select App Service logs. Select On for...
Read more >
Enable streaming execution logs in Azure Functions
To view streaming logs in the portal, select the Platform features tab in your function app. Then, under Monitoring, choose Log streaming.
Read more >
Monitor executions in Azure Functions
Learn how to use Azure Application Insights with Azure Functions to monitor function executions.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found