Failed to load container logs: Resource containerlog of type text not found

Ken Fly 46 Reputation points
2022-10-25T00:32:36.667+00:00

Previously I can access to application logs from logs tab of App service, Deployment Center

After last deployment, it suddenly only shows Failed to load container logs: Resource containerlog of type text not found from Deployment Center's Logs tab

I don't know what happened.

But I can still access to logs from Monitoring's Log stream.

So strange.

However, I have some app services with Log stream grayed out. Does anyone know why?

~~~~update~~~~

One of my app services, yesterday and this morning, it still shows Failed to load container logs: Resource container log of type text not found from Deployment Center's Logs tab
This afternoon, it suddenly work back to normal and show logs in Deployment Center's Logs tab. I absolutely did nothing to it.

But most of my app services, still show Failed to load container logs: Resource containerlog of type text not found

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,934 questions
{count} votes

Accepted answer
  1. VenkateshDodda-MSFT 24,951 Reputation points Microsoft Employee Moderator
    2022-11-07T07:42:53.18+00:00

    @Ken Fly Thanks for reaching to Microsoft Q&A. Apologize for the delay in responding on this.

    This issue has been identified and our product team has created a fix for this, and the fix will be released soon in the next update (no ETA).

    Work around suggested: At this moment the workaround is to access the container logs either from the kudu console or from the log stream feature in the portal.

    Alternatively, you can use this REST API to download the container logs file as zip file.

    Sample PS script fyi :

    $token = "xx"
    $headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
    $headers.Add("Accept", "application/zip")
    $token = $args[0]
    $headers.Add("Authorization", "Bearer ${token}")
    $headers.Add("Content-Type", "application/octet-stream")
    Invoke-RestMethod 'https://management.azure.com/subscriptions/exx/resourceGroups/xx/providers/Microsoft.Web/sites/xx/containerlogs/zip/download?api-version=2022-03-01' -Method 'POST' -Headers $headers -OutFile "C:\Users\xx\xx\logs.zip"

    Feel free to reach back to me if you have any further questions on this.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.