Score:5

Compute Engine System service account service permissions issue

us flag

I am trying to setup an instance schedular for my VM instance to start and end at particular time. I am getting an error permission related to my google service account when trying to add the vm instance to the scheduler. I have added this roles (Compute Instance Administrator (Version 1),Compute administrator) to my service account via IAM but still getting the same error. the error message is "Compute Engine System service account service-xxx needs to have [compute.instances.start, compute.instances.stop] permissions applied in order to perform this operation"

Anyone who has faced similar issue please suggest on how to fix it?

Br, Ramkrishna

John Hanley avatar
cn flag
Which role did you add? Edit your question and list the roles that the service account has. You can find this information in the Google Cloud Console -> IAM.
Ramkrishna Singh avatar
us flag
included the roles added for the default service account
Score:10
cn flag

There are two types of service accounts for Compute Engine.

  1. The default service account is assigned to the instance.
  2. The Compute Engine Service Agent is used by Google services to manage your resources.

You assigned the role to the wrong service account. The Agent needs the role added.

The Compute Engine Service Agent has the following format:

[email protected]

Solution:

  • Login to the Google Cloud Console
  • To to IAM & Admin
  • Select IAM in the left panel
  • Click the box Include Google-provided role grants on the right side of the window. This enables showing Google-managed service accounts.
  • Locate the service account. Press CTRL-F5 to open a search box. Enter the text compute-system.
  • Click the pencil icon to edit the service account.
  • Click ADD ANOTHER ROLE
  • In the role filter enter Compute. Select Compute Instance Admin (v1).
  • Click SAVE

Wait a few minutes before trying to use the new permissions.

Compute Engine Service Agent

Scheduling a VM instance to start and stop

Ramkrishna Singh avatar
us flag
Thanks manage to resolve it with the steps mentioned below
ng flag
Thanks! saved my day! that checkbox is really tricky one to notice!!
Antti Rytsölä avatar
cn flag
For once simple guide for google cloud. I don't understand how they've managed to mess up their guides so badly.
arvindwill avatar
br flag
Not sure why GCP docs are always confusing..Thank you lot
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.