azure - 无法在 Azure 上部署 Flatcar 操作系统

标签 azure azure-vm vhd azure-linux

我尝试在 Azure 上部署 flatcar 镜像,但无法部署它。以下是我执行的步骤

  1. 我从 https://stable.release.flatcar-linux.net/amd64-usr/current/flatcar_production_azure_image.vhd.bz2 下载了最新的 Azure 支持的 VHD .
  2. 我已将此 VHD 上传到 Azure 存储 Blob,并按照 Azure 指南的建议将其转换为镜像
  3. 我尝试从此镜像创建虚拟机。 VM 创建成功,但我们可以在创建 VM 时看到一个错误,并且 VM 创建显示为失败(即使实际上是成功的)。以下是我看到的错误:
{
  "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": "VMExtensionHandlerNonTransientError",
      "message": "The handler for VM extension type 'Microsoft.Azure.Diagnostics.LinuxDiagnostic' has reported terminal failure for VM extension 'LinuxDiagnostic' with error message: '[ExtensionOperationError] Non-zero exit code: 1, /var/lib/waagent/Microsoft.Azure.Diagnostics.LinuxDiagnostic-3.0.141/diagnostic.py -install\n[stdout]\n\n\n[stderr]\n  File \"/var/lib/waagent/Microsoft.Azure.Diagnostics.LinuxDiagnostic-3.0.141/diagnostic.py\", line 54\n    print 'A local import (e.g., waagent) failed. Exception: {0}\\n' \\\n          ^\nSyntaxError: invalid syntax\n'.\r\n    \r\n'Install handler failed for the extension. More information on troubleshooting is available at https://aka.ms/VMExtensionLinuxDiagnosticsTroubleshoot'"
    }
  ]
}

我尝试浏览提供的链接,但没有多大帮助。 我还尝试了另一种选择,如下

  1. 通过 Azure 市场部署 flatcar 虚拟机
  2. 从此虚拟机捕获通用镜像
  3. 使用上述步骤中创建的镜像部署虚拟机

即使使用这种方法,我也会遇到同样的错误。

最佳答案

目前,waagent(Azure Linux 代理)不支持 python 3.x,因此存在此语法错误。您的操作系统上需要安装 python 2.x 才能避免此问题。

关于azure - 无法在 Azure 上部署 Flatcar 操作系统,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73477180/

相关文章:

azure - 无法在 Azure 中创建竞价实例 VM

azure - 使用托管标识和 REST API 从 VM 调用 Azure 函数

amazon-web-services - 如何从 AWS S3 存储中的 VHD 创建 AMI

c# - 检索 Azure 用户访问的持久 token

azure - 逻辑应用失败,但调用此逻辑应用的 ADF 中的 Web 事件具有成功状态

asp.net - Web 角色内部服务器错误 (500.22)

带有 SAS token 的 Java Azure SB 连接

java - 停止在自定义 Azure-VM 中运行的 Java 进程

vhd - Lattice Diamond 显示综合退出为 9

oracle - Oracle VM Manager 支持哪些硬盘驱动器文件格式?