apache / apache/libcloud

Unable to find a name for a VHD to use for instance

未关闭
#1,471 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
stale
主要语言
Python
星标
2.1k
派生
931
平均合并
1 天 2 小时
30 天内合并 PR
4

描述

Hi,

I'm trying to create a simple instance on Azure and I'm getting the exception as attached bellow.
I tried to consult with Azure support but they didn't find something problematic with all definitions that related to my Azure account.

Please note that I'm getting the location, the size and the image properly from the defined driver.

**from libcloud.compute.types import Provider
from libcloud.compute.providers import get_driver

cls = get_driver(Provider.AZURE_ARM)
driver = cls(tenant_id=tenant_id,
subscription_id=subscription_id,
key=app_id, secret=secret)
loc = [l for l in driver.list_locations() if l.id == default_zone ][0]
size = [s for s in driver.list_sizes(location=loc) if s.name == base_instance_size ][0]
ami = driver.get_image('Canonical:UbuntuServer:16.04-LTS:latest', location=loc)
node = driver.create_node("test_node",
... size=size,
... image=ami,
... location=loc,
... ex_resource_group=resource_group,
... ex_storage_account=storage_account,
... ex_network='iavn1011126702',
... ex_subnet='iasub1011126702',
... auth=None)**

Traceback (most recent call last):
File "", line 9, in
File "/usr/local/lib/python3.6/dist-packages/libcloud/compute/drivers/azure_arm.py", line 600, in create_node
ex_blob_container=ex_blob_container)
File "/usr/local/lib/python3.6/dist-packages/libcloud/compute/drivers/azure_arm.py", line 2298, in _get_instance_vhd
("\n - ".join(errors)))
libcloud.common.types.LibcloudError: 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>
- 'Unexpected status code: 400'>">

what can be the problem here?

Thanks,
Moshik.

贡献指南

打开贡献指南

调研方向

从 libcloud/compute/drivers/azure_arm.py 中的 create_node 和 _get_instance_vhd 开始,然后跟踪返回状态 400 的 AzureBlobsStorageDriver 调用。重现所示的 Azure ARM 实例创建流程,并确定失败的 VHD 名称或 blob 请求;当原因明确到可以采取具体行动,且实例创建路径能够正确处理该问题时,即完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
azure, python
领域
cloud
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
需要澄清
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。