Option-B is correct. https://cloud.google.com/monitoring/api/metrics_agent#agent-memory (By default Memory metrics is not collected). To double confirm. Just goto Console->Operations->Monitoring->Dashboards->VM Instances->Memory Tab (Assume you have VM running already). You will see a info message saying that No agents detected. Monitoring agents collect memory metrics, disk metrics, and more. Learn more about agents and how to manage them across multiple VMs.
Correct, see following link for more detail
https://stackoverflow.com/questions/43991246/google-cloud-platform-how-to-monitor-memory-usage-of-vm-instances
The best answer here is C. Use the Stackdriver Metrics Explorer.
Here's why:
Stackdriver Metrics Explorer: The Stackdriver Metrics Explorer is a powerful tool for visualizing and analyzing metrics collected from your Google Cloud resources. It allows you to view various metrics, including memory usage, over time. You can filter and group metrics based on different criteria, making it easy to identify trends and potential issues.
Let's look at why the other options are less suitable:
A. Install the Stackdriver Client Library: The Stackdriver Client Library is used for programmatically interacting with Stackdriver from your application code. While it can be used to collect and send metrics, it's not the primary tool for viewing memory usage.
B. Install the Stackdriver Monitoring Agent: The Stackdriver Monitoring Agent is responsible for collecting metrics from your Compute Engine instances. It's a necessary component for monitoring, but it doesn't provide a user interface for viewing metrics.
D. Use the Google Cloud Platform Console: The Google Cloud Platform Console provides a general overview of your resources, but it doesn't offer the same level of detail and flexibility as the Stackdriver Metrics Explorer for viewing memory usage.
B. Install the Stackdriver Monitoring Agent.
The Stackdriver Monitoring Agent allows you to collect more system-level and third-party application metrics than what is provided by default with Google Cloud's operations suite. By installing the agent on your Compute Engine instances, you can collect detailed memory usage metrics, which can then be viewed in the Google Cloud Console or through the Metrics Explorer in Google Cloud's operations suite (formerly Stackdriver).
I think option B and C are correct answer - you need to install stack driver manager on VM to push logs into stack driver and then you can use stack driver metrics to view the metrics.
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
StelSen
Highly Voted 3 years, 9 months agoRam02
3 years, 2 months agodxxdd7
Highly Voted 3 years, 10 months agothewalker
Most Recent 4 months, 1 week agothewalker
4 months, 1 week agosantoshchauhan
8 months, 3 weeks ago__rajan__
1 year, 2 months agotomato123
2 years, 3 months agonqthien041292
2 years, 7 months agosyu31svc
3 years, 4 months agodwbi_shrikant
3 years, 8 months agoelan1302
3 years, 9 months agosaurabh1805
4 years ago