英文:
Is it possible to let to GCP choose availability zone for a new VM?
问题
During a new VM launch, gcloud allows you to choose region+zone, for instance, '--zone=us-central1-a'. Occasionally, my 'gcloud compute instances create' fails with the following error 'code: ZONE_RESOURCE_POOL_EXHAUSTED_WITH_DETAILS'. I.e. chosen zone doesn't have enough capacity for my instance type. It will be nice to have the ability to ask GCP to launch a new VM in a certain region, in any availability zone (as we have in another cloud provider). But I couldn't find such a feature. Update: I'm using these VMs in my CI on-demand workflows (with Tesla T4 GPU, custom type with 8,12,24 CPUs, in europe-west4-a).
英文:
During a new VM launch, gcloud allows you to choose region+zone, for instance, '--zone=us-central1-a'.
Occasionally, my 'gcloud compute instances create' fails with the following error 'code: ZONE_RESOURCE_POOL_EXHAUSTED_WITH_DETAILS'. I.e. chosen zone doesn't have enough capacity for my instance type. It will be nice to have the ability to ask GCP to launch a new VM in a certain region, in any availability zone (as we have in another cloud provider). But I couldn't find such a feature.
Update: I'm using these VMs in my CI on-demand workflows (with Tesla T4 GPU, custom type with 8,12,24 CPUs, in europe-west4-a).
答案1
得分: 3
ZONE_RESOURCE_POOL_EXHAUSTED 是您在请求新的 Compute Engine 资源或创建新的预留时可能遇到的常见资源错误之一。请参考此官方文档以解决这些错误。不幸的是,GCP 没有提供在特定区域启动新的虚拟机而不是在可用性区域中启动的功能,您需要手动检查可用性区域并进行部署。
为了避免这种资源错误,您可以提前创建Compute Engine 预留。预留可帮助确保在需要资源时资源是可用的。
根据这个预留文档,
有了预留,95% 的虚拟机在不到 120 秒内启动。每个预留都为具有相同属性的一个或多个虚拟机提供保证。创建预留后,预留资源立即可用,并保持可用状态,直到您删除预留。同样,您创建预留后立即开始支付预留资源的费用,当您不再需要预留时,可以删除预留以停止产生费用。在虚拟机使用预留时,不会产生额外费用。
此外,这也是一个有效的请求,您可以在公共问题跟踪器上提出功能请求,并描述您的问题。该问题跟踪器是一个供最终用户报告错误和请求改进 Google 云产品的论坛。Google 的产品工程团队将在这个实施上进行工作。
英文:
ZONE_RESOURCE_POOL_EXHAUSTED is one of the common resource errors that you might encounter when you request new Compute Engine resources or create new reservations. Refer to this official doc to resolve these errors and Unfortunately GCP doesn't have this feature to ask gcp to launch a new VM in a certain region, in any availability zone rather than we need to check manually availability zones and need to deploy.
In order to avoid this kind of resource errors you can create Compute Engine reservations ahead of when you need the resources. Reservations help ensure that resources are available when you need them.
As per this Reservations doc,
> With reservations, 95% of VMs start in less than 120 seconds. Each
> reservation provides assurance for one or more VMs with the same
> properties. After you create a reservation, the reserved resources are
> available immediately and remain available until you delete the
> reservation. Similarly, you begin paying for the reserved resources
> immediately, and, when you no longer need a reservation, you can
> delete the reservation to stop incurring charges for it. While a VM is
> consuming a reservation, it does not incur separate charges.
As, this is also a valid request and you can raise a feature request at Public Issue Tracker report with the description of your issue . This Issue Tracker is a forum for end users to report bugs and request features to improve google cloud products. Product engineering from Google will work on this implementation.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论