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

[Linux] Fix system-probe enablement conditions #336

Merged
merged 11 commits into from
Mar 30, 2021

Conversation

KSerrania
Copy link
Contributor

@KSerrania KSerrania commented Mar 25, 2021

What does this PR do?

Fixes the logic around starting / stopping the system-probe service, with different paths depending on the Agent version:

  • before 6/7.18.0: the datadog-agent-sysprobe service is independent from the datadog-agent service and is started / stopped / restarted by the role, depending on the system_probe_config.enabled variable
  • between 6/7.18.0 and 6/7.24.0: the datadog-agent-sysprobe service depends on datadog-agent, therefore only the datadog-agent service needs to be restarted on configuration changes. The system_probe_config.enabled variable still defines that behavior.
  • since 6/7.24.1: the network_config.enabled variable defines if the service should be started or not. The system_probe_config.enabled variable is still supported for backwards compatibility, but is not recommended in the documentation anymore.

Makes sure the role doesn't crash when system_probe_config has a None or empty value.

Additional notes

TODO: update documentation on how to enable system-probe modules depending on the Agent version (link to the public docs).

@KSerrania KSerrania requested a review from a team as a code owner March 25, 2021 14:07
@KSerrania KSerrania force-pushed the kserrania/fix-system-probe-linux branch from e040d77 to da83266 Compare March 25, 2021 14:18
@KSerrania KSerrania requested a review from a team as a code owner March 26, 2021 15:39
Once modification is complete, follow the steps below:
**Note**: This configuration works with Agent 6.24.1+ and 7.24.1+. For older Agent versions, refer to [the public documentation][8] on how to enable system-probe.

On Linux, once this modification is complete, follow the steps below if you installed an Agent version older than 6.18.0 or 7.18.0:
Copy link
Contributor Author

@KSerrania KSerrania Mar 26, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added this because on later versions, this should not be needed since the datadog-agent-sysprobe service is tied to the datadog-agent service.

Another option would be to automate these steps, but I'm not sure it's worth spending time on it given that this only affects a small number of old versions.

@KSerrania KSerrania merged commit d5409c4 into master Mar 30, 2021
@KSerrania KSerrania deleted the kserrania/fix-system-probe-linux branch March 30, 2021 10:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants