google/cloudprober

Datagram socket PING broken in MacOS

Rohithbala9 opened this issue · 7 comments

It's failing for all the PING probes for MacOS

#TYPE total counter
total{ptype="ping",probe="tools_asset_ping",dst="google.com"} 20 1618199752241

#TYPE success counter
success{ptype="ping",probe="tools_asset_ping",dst="google.com"} 0 1618199752241

@SAIROHITH can you add more details.

  1. Did it start breaking recently?
  2. Which version of cloudprober are you using?
  3. What's the probe configuration?

#537 may be relevant. We haven't cut a new release after that. Can you try with the master docker image tag if you're using docker image?

I have started working with cloudprober recently. I'm using v0.11.1 version.
probe {
name: "tools_asset_ping"
type: PING
targets {
host_names: "google.com"
}
interval_msec: 5000 # 5s
timeout_msec: 1000 # 1s
}
yeah #537 is similar. So I can expect a fixed one with the new release.
Still didn't use it with docker image, will try that.

If it's #537, then only unprivileged ping will be broken. You can specify the following option to use privileged ping and run it as root:

probe {
  ...
  ping_probe {
     use_datagram_socket: false
  }
  ...
}

More explanation of this option:

// Use datagram socket for ICMP.

And, yes I need to cut a release soon.

Thank you, could access it as privileged ping.

New release has been cut. Closing this one now.