Sh: check-http.rb: command not found

1. What have you already tried? Please include links to gists and/or code blocks (if relatively small)

Hi, I am attempting to monitor external websites and began by following the instructions: Monitor external resources with proxy requests and entities - Sensu Docs

I registered the assets:

$ sensuctl asset list
         Name                                                      URL                                                 Hash
 ──────────────────── ────────────────────────────────────────────────────────────────────────────────────────────── ─────────
  sensu-plugins-http   //                1277b1d
  sensu-plugins-http   //                642643d
  sensu-plugins-http   //                33a9f42
  sensu-ruby-runtime   //    8d768d1
  sensu-ruby-runtime   //   cbee191
  sensu-ruby-runtime   //    a28952f
  sensu-ruby-runtime   //    338b88b

I created the check:

$ sensuctl check list
        Name                      Command                Interval   Cron   Timeout   TTL   Subscriptions   Handlers                  Assets                   Hooks   Publish?   Stdin?   Metric Format   Metric Handlers
 ────────────────── ─────────────────────────────────── ────────── ────── ───────── ───── ─────────────── ────────── ─────────────────────────────────────── ─────── ────────── ──────── ─────────────── ─────────────────
  check-sensu-site   check-http.rb -u         60                0     0   proxy                      sensu-plugins-http,sensu-ruby-runtime           true       false

I added the proxy subscription to the agent.yml file and restarted the agent.

I validated the check:

$ sensuctl entity list
               ID                 Class    OS                   Subscriptions                            Last Seen
 ─────────────────────────────── ─────── ─────── ──────────────────────────────────────────── ───────────────────────────────
  ip-#-#-#-#.ec2.internal   agent   linux   proxy,entity:ip-#-#-#-#.ec2.internal   2021-04-09 17:52:08 +0000 UTC
  sensu-site                      proxy           entity:sensu-site                            N/A

I then inquire if Sensu is monitoring with the check, but get the error in the Output field:

sensuctl event info sensu-site check-sensu-site
=== sensu-site - check-sensu-site
Entity:    sensu-site
Check:     check-sensu-site
Output:    sh: check-http.rb: command not found
Status:    127
History:   127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127
Silenced:  false
Timestamp: 2021-04-09 17:32:41 +0000 UTC
UUID:      0ccd9eed-019b-4d57-a7b4-46f903935779

I also find the following in the system logs, but not sure what it means:

Apr  9 16:55:39 ip-#-#-#-# sensu-agent: {"asset":"sensu-ruby-runtime","component":"asset-manager","entity":"ip-#-#-#-#.ec2.internal","filter":["entity.system.os == 'linux'","entity.system.arch == 'amd64'","entity.system.platform_family == 'rhel'","parseInt(entity.system.platform_version.split('.')[0]) == 6"],"level":"debug","msg":"entity not filtered, not installing asset build","time":"2021-04-09T16:55:39Z"}

I searched through the forum and found related issues, but nothing that helped.

What am I missing?

2. Tell us about your setup, this should include OS, version of Sensu, version of Sensu components (redis, rabbitmq), plugin versions (if applicable), anything special about your setup such as an airgapped network or strict ACLs

sensu backed (Docker) in K8s: 5.21.5
sensuctl (CentOS 7.9): 5.21.5
sensu agent (CentOS 7.9): 5.21.5

3. Is there a Github issue related to your issue?


4. Is there anything else that can help us effectively help you?


update your sensu-plugins-http asset definition with the newer version. The 5.1.1 release didn’t have explicit support for centos just rhel in the filtering rules.

sensuctl asset add sensu-plugins/sensu-plugins-http:6.0.0 -r sensu-plugins-http --namespace default```

Thank you @jspaleta. This fixed the issue on our centos and rhel agents.