Get startedGet started for free

Lab Review: Resource Monitoring

1. Lab Review: Resource Monitoring

In this lab you got an overview of Cloud Monitoring. You learned how to monitor your project, create alerts with multiple conditions, add charts to dashboards, create resource groups, and create uptime checks for your services. Monitoring is critical to your application's health, and Cloud Monitoring provides a rich set of features for monitoring your infrastructure, visualizing the monitoring data, and triggering alerts and events for you. You can stay for a lab walkthrough, but remember that Google Cloud's interface can change, so your environment might look slightly different. Welcome to the lab walkthrough for resource monitoring with Stackdriver. At this point I have logged into the GCP console with the credentials that the Qwiklabs lab has provided me. And in the first task I am going to verify that the proper Vms had been set up for me using deployment manager in this lab. And as you can see, there are three Vms. 3 engine X stacks right here. So now that I verified that my instances are running and were created for me, I am going to go to stackdriver monitoring which will open in a new tab. And then it is going to set up the workspace for my project. And this can take a few minutes. So just be patient or go get a cup of coffee and come back. Once your workspace has been set up for you, you are going to be redirected to the monitoring overview page. There are some questions in the labs that are going to ask you some questions and those are just making sure that your understanding and actually reading. But you don't have to fill those out in order to get the full score for the labs. So in task two, we're going to create a dashboard, so I'm going to go here. To monitoring overview when I click create dashboard. I am going to name it my dashboard instead of untitled hit enter. And then I'm going to add a chart. For the title, I am going to say this is my chart. And I am going to find GCE. VM instance. For metrics, I am going to select CPU utilization. CPU utilization and for filter. Where is filter here? I'm going to add a filter. There are various options you can filter by resource label by metadata label. I'm not going to add any filters, I want to see everything. And then we click here on view options. There's a couple of chart modes. There's color mode X Ray mode. You can preview it on the right. Stats mode and like that. So I actually like the X Ray mode, so I'm going to go ahead and click that. And then you're going to hit save to add the chart to your dashboard. There it is, looking nice. So then we also have a metrics explorer which allows you to examine resources and metrics without having to create a chart on the dashboard. So if I go to resources metrics explorer. Find resource type in metric, I can type any metric or resource name. So let's say I do CPU utilization. And as you can see I didn't have to add this, but I could still explore it. Again, you'll have another question in the lab, but that is to prompt your understanding. So now, I'm going to create an alert and add the first condition. So I'm going to go here and create a policy. And I'm going to click add condition. Here I'm going to do GCE VM instance. And for metrics, I'm going to use CPU usage. For condition, I'm going to say is above threshold. Of one minute, the threshold is 20. And then I'm going to hit save. And I'm going to add another condition. And then what said do I do it for another VM? So if I do this one. Maybe I do it for another metric going to, do you? Stu reserved course. And then above 15. I'm going to head, save. So now in policy triggers I'm going to trigger when all conditions are met. Then I'm going to configure the notifications so that I can be actually told that this has triggered. And I'm going to click here. Email, and I'm going to add some email going to do fake email. I want you guys spamming me. And then add. That has been added. And then I'm going to stick, skip the documentation step, but in reality this is a pretty important part of your notification. You want to say. What happened, why whoever it is that's getting notified is being alerted and a best practices to actually tell them how to maybe fix it. because otherwise that's not a very useful notification if they don't know how they can fix it. And then you're going to name it, and this is my. I first alerting policy. And then I'm going to hit save. This is a checkpoint in the lab where you can check your progress that you have created an alerting policy. The next task you are going to create some groups here. Create group, I'm going to give it a name. VM instances. Name, I am going to select. Contains and I'm going to type engine X. And I'm going to save group. And you can see it's showing me instances. All three of my instances because the name matches Anjanette stack. And again, you're going to have another. Question to make sure that your understanding and reading all of the extra tidbits that are available in the lab. So now, we're going to go back to the Dashboard. You're going to go to uptime checks. Overview and then we're going to add an uptight and check. So in here we're going to add a title, so my first uptime check were using HTTP. It is to check an instance in, applies to a group and I'm going to select group I created which is VM instances and I'm going to check every one minute. I'm going to hit save. You could also hit test for it and make sure that it works. I'm going to say no thanks. I don't want to create the alert policy right now. So this is the last piece where you can hit check my progress. It's going to make sure that you created that uptime check, and if so, you're going to get the full points for the lab. So in this lab, we got to walk through monitoring your projects, creating a stackdriver workspace which gets created for you. Creating some alerts with multiple condition, adding some charts to a dashboard, and creating resource groups, and finally we created an uptime check for your services. Hope you enjoyed it.

2. Let's practice!

Create Your Free Account

or

By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.