我可以使用 az cli 成功创建 VM 磁盘快照。 如何使用 az cli 将快照复制到 azure 存储帐户?
如何使用 az cli 将快照复制到 azure 存储帐户?
您可以使用以下命令通过 Azure CLI 将
VM snapshot
复制到 Azure 存储帐户。
首先,从门户复制虚拟机快照 URL:
Azure 门户 > 快照 > 选择快照 > 快照导出 > 生成 URL。
命令:
az storage blob copy start --account-name "venkat679" --destination-blob "abcd.vhd" --destination-container "test" --account-key "<Your account key>" --source-uri "<snapshoturl>"
输出:
{
"client_request_id": "bc99xxxxxee-a269-00155df677e8",
"copy_id": "xxxx",
"copy_status": "pending",
"date": "2024-04-04T06:15:30+00:00",
"etag": "\"0x8DC546EA152C803\"",
"last_modified": "2024-04-04T06:15:30+00:00",
"request_id": "8xxxxx,
"version": "2022-11-02",
"version_id": null
}
复制过程需要一些时间才能完成,一段时间后,它将反映在您的存储容器中。
传送门:
文件已成功复制到 Azure 存储容器。
参考: