Member-only story

Get notified when your GCP Compute Engine crashes due to HostError

Rajathithan Rajasekar
3 min readNov 16, 2020

--

credits: unsplash photos , photo taken by taylor vick

In this post, we are going to discuss about the host-error failures that may occur to your GCP Compute Engines in case of a google cloud hardware or software infrastructure failure. Even though we have uptime metrics in stackdriver for compute instances , there is no readily available metric in stackdriver as of today to notify us on HostError failures. It is also important to set your compute engines availability policy to mitigate these events , so they get restarted automatically on a different host .

In order to get notified for these events , you need to configure a custom log metric .

Since these are very rare occurrences you might not have a prior event to capture the logs for this, so let’s see how this can be configured.

Step 1:

Go to Log-based-metrics under Logging.

Log-based-metrics under Logging

Step 2:

Click on “CREATE METRIC”

Step 3:

(GCP recently upgraded their logs viewer ) If you are in the legacy logs viewer , click on the drop down on the right to convert it to an advanced filter , Enter the log…

--

--

Rajathithan Rajasekar
Rajathithan Rajasekar

Written by Rajathithan Rajasekar

I like to write code in Python . Interested in cloud , dataAnalysis, computerVision, ML and deepLearning. https://rajathithanrajasekar.medium.com/membership

No responses yet