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! Go to 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.
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 ?
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.