没有数据时出现StackDriver警报 [英] StackDriver alert when there's no data

查看:75
本文介绍了没有数据时出现StackDriver警报的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在StackDriver中针对实例/正常运行时间"指标设置了警报策略.在小于1的情况下发出警报,持续1分钟.

然后我删除了实例,并且没有警报.

是不是因为在接下来的时间窗口中数据不是0而是没有,所以没有警报发送?

解决方案

我转载了您的情况

如果删除了实例,则不会生成警报,这是预期的行为,因为资源(VM)不再存在.

只有虚拟机实例启动并运行时,才会生成正常运行时间警报.

似乎您正在尝试删除实例后发送警报,如果是这种情况,可以使用Stackdriver Logging中基于日志的指标来完成,该指标可在Stackdriver Monitoring中用于生成警报.以下链接将在这方面帮助您创建计数器指标基于日志的指标界面

I've set up an alerting policy in StackDriver on the "instance/uptime" metrics. To alert when it's less 1 for 1 minute.

Then I deleted the instance, and had no alerts.

Is it so because at the following time window the data isn't 0 rather none, so no alerts are sent?

解决方案

I reproduced your situation

If the instance is deleted, there's no alerts being generated, this is expected behavior since the resource (VM) doesn't exist anymore.

Uptime alerts are generated when only VM instances are up and running.

It seems you are trying to send alert when instances are deleted, if this is the case, this can be done with log-based metrics in Stackdriver Logging which can be used in Stackdriver Monitoring to generate alerts. The following links will assist in this regards Creating Counter Metrics and Logs-based metrics interface

这篇关于没有数据时出现StackDriver警报的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆