Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Heartbeat] Add docs for rootless pings #15194

Merged
merged 6 commits into from
Dec 19, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions heartbeat/docs/heartbeat-options.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ options that are specific to that monitor type.
The type of monitor to run. One of:

* `icmp`: Uses an ICMP (v4 and v6) Echo Request to ping the configured hosts.
Requires root access. See <<monitor-icmp-options>>.
Requires special permissions or root access. See <<monitor-icmp-options>>.
* `tcp`: Connects via TCP and optionally verifies the endpoint by sending and/or
receiving a custom payload. See <<monitor-tcp-options>>.
* `http`: Connects via HTTP and optionally verifies that the host returns the
Expand Down Expand Up @@ -231,7 +231,15 @@ the output document. By default, `keep_null` is set to `false`.

These options configure {beatname_uc} to use ICMP (v4 and v6) Echo Requests to check
the configured hosts. These options are valid when the <<monitor-type,`type`>> is
`icmp`.
`icmp`. Please not that on most platforms one must execute Heartbeat with elevated permissions
andrewvc marked this conversation as resolved.
Show resolved Hide resolved
to perform ICMP pings.

On Linux regular users may perform pings if the right file capabilities are set. You can run
andrewvc marked this conversation as resolved.
Show resolved Hide resolved
`sudo setcap cap_net_raw+eip /path/to/heartbeat` to grant {beatname_uc} ping capabilities on Linux.
Alternatively, one may grant ping permissions the user {beatname_uc} runs as. To grant ping permissions
andrewvc marked this conversation as resolved.
Show resolved Hide resolved
in this way run `sudo sysctl -w net.ipv4.ping_group_range='myuserid myuserid'`.
andrewvc marked this conversation as resolved.
Show resolved Hide resolved

On other platforms running {beatname_uc} as root or administrator may be required to execute pings.
andrewvc marked this conversation as resolved.
Show resolved Hide resolved

[float]
[[monitor-icmp-hosts]]
Expand Down