Watcher to track specific Drive space

Hello I wanted to create a watcher to track my space on a specific drive (D:/) or even machine later. I am not really experienced with them and I read the documentation and followed some examples but it is not working well. This was my first idea but somehow I get the message:

[parse_exception] could not parse [compare] condition for watch [inlined]. unknown comparison operator [ctx.payload.system.filesystem.used.pct]

When I try to simulate I can not understand why my watcher seems to be invalid.

{
  "trigger": {
    "schedule": {
      "interval": "30m"
    }
  },
  "input" : {
    "search" : {
      "request" : {
        "indices" : [ "metricbeat-*" ]
      },
	  "extract": [ "system.filesystem.used.pct", "beat.name", "system.filesystem.mount_point" ]
    }
  },
  "condition": {
    "compare": {
          "compare": {"ctx.payload.system.filesystem.used.pct" : { "gte" : 0.33 },"system.filesystem.mount_point":"D://"}
    }
  },
  "actions" : {
	"email_me": {
		"email" : {
			"to" : "philipp.lippold@abc.com",
			"subject" : "{{ctx.payload.beat.name}} {{ctx.payload.system.filesystem.mount_point}} {{ctx.payload.system.filesystem.used.pct}}",
			"body" : "nothing here",
			"priority" : "high"
		}
	}
  }
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.