Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
540 views
in Technique[技术] by (71.8m points)

google cloud platform - Cannot start GCE VM instance "The zone does not have enough resources"

I am trying to restart an instance that has been shut down for about a week, however it will not start, I get the error message:

Starting VM instance 'gc-custom-europe-west2-xxxxxxxxxxxxxxxxxxxx' failed. Error: The zone 'projects/XXX/zones/europe-west2-c' does not have enough resources available to fulfill the request. Try a different zone, or try again later.

There are no incidents reported that I can see, could anyone advise please?

question from:https://stackoverflow.com/questions/65884360/cannot-start-gce-vm-instance-the-zone-does-not-have-enough-resources

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You can control status of Google Cloud at Google Cloud Status Dashboard, but this isn't an issue, let me provide you some explanations:

  1. When you stop an instance it releases some resources like vCPU and memory.

  2. When you start an instance (or change it) it requests resources like vCPU and memory back and if there's not enough resources available in the zone you'll get an error message:

     Error: Starting VM instance "INSTANCE_NAME" failed. Error: The zone 'projects/XXXX/zones/ZONE' does not have enough resources available to fulfill the request. Try a different zone, or try again later.
    

    more information available in the documentation:

    If you receive a resource error (such as ZONE_RESOURCE_POOL_EXHAUSTED or ZONE_RESOURCE_POOL_EXHAUSTED_WITH_DETAILS) when requesting new resources, it means that the zone cannot currently accommodate your request. This error is due to Compute Engine resource obtainability, and is not due to your Compute Engine quota.

  3. Resource availability are depending from users requests and therefore are dynamic.

There are a few ways to solve such issue without moving it to another zone:

  1. Move your VM instance to another zone.
  2. Wait for a while and try to start your VM instance again.
  3. Reserve resources for your VM by following documentation to avoid such issue in future (extra payment required):

Create reservations for Virtual Machine (VM) instances in a specific zone, using custom or predefined machine types, with or without additional GPUs or local SSDs, to ensure resources are available for your workloads when you need them. After you create a reservation, you begin paying for the reserved resources immediately, and they remain available for your project to use indefinitely, until the reservation is deleted.

To protect data on your VM you can create a snapshot before making any changes.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...