azure - 在 Azure 中配置容器应用程序失败并出现 "Conflict"的合理原因是什么?为什么没有日志写入分析工作区?

标签 azure azure-container-apps

配置失败的确切状态消息是:

{
    "status": "Failed",
    "error": {
        "code": "90008",
        "message": "Failed to provision revision for container app '***********'. Error details: Operation expired."
    }
}

当我尝试使用以下命令从日志分析获取数据时:

az monitor log-analytics query --workspace **************** --analytics-query "ContainerAppConsoleLogs_CL | where ContainerAppName_s == '******' | project ContainerAppName_s, Log_s, TimeGenerated"

我得到=> BadArgumentError:请求有一些无效的属性 这可能与日志分析工作区的自定义日志中没有创建自定义表有关(假设)。

使用二头肌脚本自动部署。我在 Debug模式下运行该命令以获得最多的输出,但它没有提供太多额外的有用信息:

az deployment group create --resource-group rg-radix-samples-shop --template-file .\main.bicep --debug

最有用的部分是,这可能会给内部人员一些额外的信息:

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/arm.py", 
line 109, in handle_template_based_exception        
AttributeError: 'OperationFailed' object has no attribute 'error'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\knack/cli.py", line 231, in invoke
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 657, in execute
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 720, in _run_jobs_serially
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 712, in _run_job
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/arm.py", 
line 112, in handle_template_based_exception        
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/arm.py", 
line 104, in raise_subdivision_deployment_error     
azure.cli.core.azclierror.DeploymentError: {"status":"Failed","error":{"code":"DeploymentFailed","message":"At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/DeployOperations for usage details.","details":[{"code":"Conflict","message":"{\r\n  \"status\": \"Failed\",\r\n  \"error\": {\r\n  
  \"code\": \"ResourceDeploymentFailure\",\r\n    \"message\": \"The resource operation completed with terminal provisioning state 'Failed'.\",\r\n    \"details\": [\r\n      {\r\n        \"code\": \"DeploymentFailed\",\r\n        \"message\": \"At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/DeployOperations for usage details.\",\r\n    
    \"details\": [\r\n          {\r\n            \"code\": \"Conflict\",\r\n            \"message\": \"{\\r\\n  \\\"status\\\": \\\"Failed\\\",\\r\\n  \\\"error\\\": {\\r\\n    \\\"code\\\": \\\"ResourceDeploymentFailure\\\",\\r\\n    \\\"message\\\": \\\"The 
resource operation completed with terminal provisioning state 'Failed'.\\\",\\r\\n    \\\"details\\\": [\\r\\n      {\\r\\n        \\\"code\\\": \\\"90008\\\",\\r\\n        \\\"message\\\": \\\"Failed to provision revision for container app '************'. Error details: Operation expired.\\\"\\r\\n  
    }\\r\\n    ]\\r\\n  }\\r\\n}\"\r\n          }\r\n        ]\r\n      }\r\n    ]\r\n  }\r\n}"}]}}    

所以我基本上有两个问题:

  • 什么可能导致配置失败?
  • 为什么没有日志写入我的分析工作区(或任何地方)以便我可以诊断正在发生的情况?

预先感谢您的帮助

最佳答案

错误消息似乎已更改(也许有所改进?)。错误代码仍然相同,但消息包含更多信息,即它无法拉取 docker 镜像。最后是docker镜像名字有错别字(数字)。

关于azure - 在 Azure 中配置容器应用程序失败并出现 "Conflict"的合理原因是什么?为什么没有日志写入分析工作区?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/70203053/

相关文章:

visual-studio - 从 Visual Studio 上传 Azure Blob

azure - Azure 容器应用程序的可用性

azure - 创建 Azure 应用服务 yaml 文件后无法编辑配置

azure - Application Insight 如何自动捕获传入的 Http 请求?

java - 如何通过 Java SDK 在 Azure Key Vault 中创建 key ?

java - @PropertySource 无法 Autowiring 所需的类(Spring Boot 2.3.8.RELEASE)

azure - 在 Azure 容器应用程序上运行一次性作业

azure - 如何在Azure容器应用程序中引用 secret ?

azure - 如何从 Azure 容器应用程序读取环境变量

azure - Azure 可以使用 PUT 而不是 PATCH 通过 SCIM 更新资源吗?