Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

adding another project to monitoring project scope

i create a monitoring project and trying to add another project where my GCE VMs are. I am using my owner account. in my monitoring peoject, I go to monitoring/metric scope and try to add my other project in there bu keep getting error

 

Failed to add 1 project to this Metrics Scope

 

any idea?

Solved Solved
1 7 895
1 ACCEPTED SOLUTION

Okay, so Stackdriver has two types of project:

* Scoping Project - project for which you can assign other projects
* Monitored Projects - projects monitored by alerting policies configured at Scoping Project.

Be sure, that monitoring.googleapis.com has been enabled on scoping project. Once enabled, execute following command 

gcloud beta monitoring metrics-scopes create projects/MONITORED_PROJECT_ID --project=SCOPING_PROJECT_ID

Or try to add projects via UI. Should work.

 

View solution in original post

7 REPLIES 7

Hello @gcp888  ,Welcome on Google Cloud Community.

Did you've tried to assign to your user Monitoring Admin role at project ( Scoping Project)  where you want to add other projects ( Monitored Projects) ?

 

--
cheers,
DamianS
LinkedIn medium.com Cloudskillsboost

wouldnt owner permissions allow this? i am using the owner account on both projects

Basically Owner does not contain own all permissions, this is why I've asked about Monitoring Admin. Are you able to paste screenshot with the exact alert ? Additionally, are you able to check what Logs Explorer says about that ? 

gcp888_0-1721743031681.png

 

 

here is the screenshot

 

from the monitoring project I am not able to add the other projects where y resources are. but from the resource project I am able to add the monitoring project which is not what I want. I want to do the opposite

Okay, so Stackdriver has two types of project:

* Scoping Project - project for which you can assign other projects
* Monitored Projects - projects monitored by alerting policies configured at Scoping Project.

Be sure, that monitoring.googleapis.com has been enabled on scoping project. Once enabled, execute following command 

gcloud beta monitoring metrics-scopes create projects/MONITORED_PROJECT_ID --project=SCOPING_PROJECT_ID

Or try to add projects via UI. Should work.

 

thanks that was it. API was not enabled. 

Top Solution Authors