Comprehensive and Detailed Explanation:
When using Managed Service for Prometheus, metrics may not appear in Cloud Monitoring if PodMonitoring is misconfigured. The most likely issue is that the PodMonitoring configuration does not reference a valid port.
PodMonitoring is required to collect metrics from workloads in GKE.
If the port is incorrect or missing, metrics won’t be scraped.
????Why not other options?
A (Check quota limits)❌→ If quotas were exceeded, you’d see explicit errors, but the question states no errors were encountered.
B (Grafana installation check)❌→ Grafana is not required for Prometheus metric collection.
C (monitoring.servicesViewer IAM role issue)❌→ This role allows viewing metrics, but does not affect metric collection.
????Official Reference:
Managed Service for Prometheus - PodMonitoring
GKE Monitoring Troubleshooting
Submit