Deploy the Collector with Ansible for Linux 🔗
Install the Ansible collection 🔗
The following Linux distributions and versions are supported:
Amazon Linux: 2, 2023. Log collection with Fluentd isn’t supported for Amazon Linux 2023.
CentOS, Red Hat, or Oracle: 7, 8, 9
Debian: 9, 10, 11
SUSE: 12, 15 for Collector version 0.34.0 or higher. Log collection with Fluentd isn’t supported.
Ubuntu: 16.04, 18.04, 20.04, and 22.04
Before installing the Ansible collection, do the following:
Find your Splunk access token.
Find your Splunk realm.
Check exposed ports to make sure your environment doesn’t have conflicts. Ports can be changed in the package’s configuration.
Ansible Galaxy is the Ansible official hub for sharing Ansible content. See Ansible Collection for the Splunk Distribution of OpenTelemetry Collector for more information about the playbook.
Run the following command to install the Ansible collection from Ansible Galaxy:
ansible-galaxy collection install signalfx.splunk_otel_collector
To use the role, include the signalfx.splunk_otel_collector.collector role
invocation in your playbook. Note that this role requires root access. The following example shows how to use the role in a playbook with minimal required configuration:
- name: Install the Splunk Distribution of OpenTelemetry Collector
hosts: all
become: yes
tasks:
- name: "Include splunk_otel_collector"
include_role:
name: "signalfx.splunk_otel_collector.collector"
vars:
splunk_access_token: YOUR_ACCESS_TOKEN
splunk_realm: SPLUNK_REALM
The following table describes the variables that can be configured for this role:
Variable |
Description |
---|---|
|
Replaces |
|
The Splunk access token to authenticate requests. This attribute is required. |
|
The realm to send the data to. This variable is set with this value for the service. The default value is |
|
The Splunk ingest URL, for example, |
|
The Splunk API URL, for example, |
|
The Splunk trace endpoint URL, for example, |
|
The Splunk HEC endpoint URL, for example, |
|
The version of the package to install, for example, |
|
The configuration file, created in YAML. This variable can be set to |
|
The custom configuration that is merged into the default configuration. |
|
The variable used to configure the |
|
This is the source path to a configuration file on your control host that is uploaded and set in place of the value set in |
|
The path to the bundle directory. The default path is provided by the package. If the specified path is changed from the default value, the path should be an existing directory on the node. This variable is set with this value for the service. The default location is |
|
The path to the collectd configuration directory for the bundle. The default path is provided by the package. If the specified path is changed from the default value, the path should be an existing directory on the node. This variable is set with this value for the service. The default location is |
|
The user or group ownership for the service. The user or group is created if they do not exist. The default value is |
|
The proxy address, respectively for |
|
The amount of allocated memory in MiB. The default value is |
|
|
|
The option to install or manage Fluentd and dependencies for log collection. The dependencies include |
|
The version of td-agent (Fluentd package) that is installed. The default value is |
|
The path to the Fluentd configuration file on the remote host. The default location is |
|
The source path to a Fluentd configuration file on your control host that is uploaded and set in place of the value set in |
Configure automatic discovery for back-end applications (Linux only) 🔗
You can automatically discover and instrument your back-end applications along with the Collector installation. Automatic discovery (formerly zero configuration auto instrumentation) removes the need to install and configure the SDKs separately. See Configure automatic discovery for back-end applications for more information.
The following table shows the variables that you can configure for this Ansible role:
Variable |
Description |
Default value |
---|---|---|
|
Installs or manages automatic discovery for Java, Node.js, and/or .NET back-end applications. When set to |
|
|
The automatic discovery SDKs to install and activate. Note: |
|
|
Determines the version of the |
|
|
By default, the |
|
|
By default, the |
None |
|
Determines the path to the Splunk OpenTelemetry Java agent. The default path is provided by the |
|
|
The path to the pre-installed |
|
|
Configures the OpenTelemetry instrumentation resource attributes, for example, |
None |
|
Explicitly sets the service name for the instrumented applications, for example, |
None |
|
Activates or deactivates AlwaysOn CPU Profiling. |
|
|
Activates or deactivates AlwaysOn Memory Profiling. |
|
|
Activates or deactivates JVM metrics. |
|
|
Sets the OTLP endpoint for collected metrics, traces, and logs by all activated SDKs. Only applicable if |
|
|
Sets the OTLP endpoint protocol for collected metrics, traces, and logs by all activated SDKs, for example |
|
|
Comma-separated list of exporters for collected metrics by all activated SDKs, for example |
|
|
Sets the exporter for collected logs by all activated SDKs, for example |
|
Next steps 🔗
After you have installed the package, see: