create vm instance error :e2 instances do not support onHostMaintenance=TERMINATE unless they are preemptible

8,963 views
Skip to first unread message

Zhiyong Weng

unread,
Jun 3, 2021, 12:13:00 PM6/3/21
to google-c...@googlegroups.com
Hi,

I try to create e2 instance from template, but always get error:

```e2 instances do not support onHostMaintenance=TERMINATE unless they are preemptible.```

already set Preemptibility = OFF, On host maintenance = **Migrate VM instance**,  the error message is very confusing...

Digil (Google Cloud Platform Support)

unread,
Jun 8, 2021, 12:39:55 PM6/8/21
to Google Cloud Developers
If I understand this issue correctly, you have been using an instance template which have been already set with 'availability policies' (ie Preemptibility as 'off' & On host maintenance as 'Terminate VM instance'), right? If that's the scenario, since the instance template is immutable, the subsequent instance creation using different 'availability policies' might also fail. 

To solve the above mentioned situation, I would recommend you to try the following:
1. Create a new instance template  based on the existing template. But, while creating the new template, make sure to update the  'availability policies' (ie Preemptibility as 'off' & On host maintenance as 'Terminate VM instance') as per your choice

Note: If you were experiencing something different, feel free to report it as a defect using Google Cloud Platform's issue tracker. While opening the issue report, try to provide the complete reproduction(*important*) steps with the details of the error you were getting & the documents you were using.

max

unread,
Jun 9, 2021, 3:03:54 AM6/9/21
to Digil (Google Cloud Platform Support), Google Cloud Developers
after creating a new template,  the issue gone
Not sure it is a defect or not, but I know you are awesome 

Thank you 🙏 

--
You received this message because you are subscribed to the Google Groups "Google Cloud Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-dev/3e423806-2db9-4885-848c-becc57b250d0n%40googlegroups.com.

jinguruxxx

unread,
Aug 2, 2021, 11:03:09 AM8/2/21
to Google Cloud Developers
I have a similar problem relating to an email i received recently from GCP:

 [Action Required] To continue receiving your Free Tier discount, upgrade your F1-Micro VM to an E2-Micro VM by September 1, 2021

I stopped my f1-micro instance and then changed machine to E2-Micro as advised - but i keep getting this message (similar to the thread).

"Operation type [setMachineType] failed with message "e2 instances do not support onHostMaintenance=TERMINATE unless they re preemptible"

Unfortunately, the attached links in the notice were not so helpful. 
My availability policies have not changed in the last couple of years and remain as:

Availability policies
Preemptibility
Off (recommended)
On host maintenance
Migrate VM instance (recommended)
Automatic restart
On (recommended)
Any advice would be greatly appreciated!


Thanks

Will Njundong

unread,
Aug 4, 2021, 4:56:57 PM8/4/21
to Google Cloud Developers
I was in the exact same position as ^ jingu...@gmail.com

I just went back to my instance list, started and stopped the instance then went back into edit mode and it worked the second time. No clue whether this is reproducible.
Reply all
Reply to author
Forward
0 new messages