Chef π
Chef is a configuration management technology used to manage infrastructure on physical or virtual machines. Chef uses cookbooks to define a scenario.
Cookbooks are fundamental working units of Chef, which consists of all the details related to working units, having the capability to modify configuration and the state of any system configured as a node on Chef infrastructure. Cookbooks can run multiple tasks.
Prerequisites π
You need the following resources to use Chef:
Double-check exposed ports to make sure your environment doesnβt have conflicts. You can change ports in the Collector configuration. See Exposed ports and endpoints for more information.
Linux π
The following Linux distributions and versions:
Amazon Linux: 2
CentOS, Red Hat, Oracle: 7, 8
Debian: 9, 10, 11
SUSE: 12, 15 (Note: Only for Collector versions 0.34.0 or higher. Log collection with Fluentd not currently supported.)
Ubuntu: 18.04, 20.04, 22.04
Windows π
The following Windows versions. All versions require using PowerShell 3.0 or newer.
Windows Server 2019 64-bit
Windows Server 2022 64-bit
Getting started π
Download the Chef cookbook from the Chef Supermarket, which is the site for community cookbooks.
To install the Collector and Fluentd, include the splunk_otel_collector::default
recipe in the run_list
, and set the attributes on the nodeβs run_state
. The following is an example configuration that shows how to configure the required splunk_access_token
attribute and some optional attributes:
{
"splunk-otel-collector": {
"splunk_access_token": "<SPLUNK_ACCESS_TOKEN>",
"splunk_realm": "<SPLUNK_REALM>",
}
}
Attributes for Linux π
For Linux, the cookbook accepts the attributes described in the following table:
Name |
Description |
Default value |
---|---|---|
|
Version of the Collector package to install, for example, |
None |
|
The Splunk access token to authenticate requests. This attribute is required. |
None |
|
Which realm to send the data to, for example, |
None |
|
Sets the Splunk ingest URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk API URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk trace endpoint URL explicitly instead of the URL inferred by the |
|
|
The path to the Smart Agent bundle directory. The default path is provided by the Collector package. If the specified path is changed from the default value, the path should be an existing directory on the node. The |
|
|
The path to the collectd configuration directory for the Smart Agent bundle. The default path is provided by the Collector package. If the specified path is changed from the default value, the path should be an existing directory on the node. The |
|
|
Total memory in MIB to allocate to the Collector; automatically calculates the ballast size. The |
|
|
Sets the ballast size for the Collector explicitly instead of the value calculated from the |
|
|
The source path to the Collector configuration YAML file. This file is copied to the |
|
|
Destination path of the Collector configuration file on the node. The |
|
|
The Collector configuration object. Everything underneath this object gets directly converted to YAML and becomes the Collector configuration file. Using this option preempts |
|
|
Sets the user or group ownership for the Collector service. The user or group is created if they do not exist. |
|
|
The Collector package repository stage to use. Can be |
|
|
Whether to install or manage Fluentd and dependencies for log collection. On Linux, the dependencies include |
|
|
Version of the td-agent (Fluentd) package to install |
|
|
Source path to the Fluentd configuration file. This file is copied to the |
|
|
Destination path to the Fluentd configuration file on the node. Only applicable if |
|
Configure auto instrumentation for Java (Linux only) π
You can automatically instrument your Java applications along with the Collector installation. Auto instrumentation removes the need to install and configure the Java agent separately. See Configure automatic instrumentation for Java for more information.
The following table shows the variables that can be configured for this Chef cookbook:
Name |
Description |
Default value |
---|---|---|
|
Whether to install or manage Splunk OpenTelemetry Zero Configuration Auto Instrumentation for Java. When set to |
|
|
Version of the |
|
|
By default, the |
|
|
Path to the Splunk OpenTelemetry Java agent. The default path is provided by the |
|
|
Configure the OpenTelemetry instrumentation resource attributes, for example, |
|
|
Explicitly sets the service name for the instrumented Java application, for example, |
|
|
Set to |
|
|
Prevents the preloader from sending the |
|
|
Activates or deactibvates AlwaysOn CPU Profiling. |
|
|
Activates or deactivates AlwaysOn Memory Profiling. |
|
|
Activates or deactivates JVM metrics. |
|
Attributes for Windows π
For Windows, the cookbook accepts the attributes described in the following table:
Name |
Description |
Default value |
---|---|---|
|
Version of the Collector package to install, for example, |
None |
|
The Splunk access token to authenticate requests. This attribute is required. |
None |
|
Which realm to send the data to, for example, |
None |
|
Sets the Splunk ingest URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk API URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk trace endpoint URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk HEC endpoint URL explicitly instead of the URL inferred by the |
|
|
Sets the Splunk HEC authentication token if different than |
|
|
The path to the Smart Agent bundle directory. The default path is provided by the Collector package. If the specified path is changed from the default value, the path should be an existing directory on the node. The |
|
|
The path to the collectd configuration directory for the Smart Agent bundle. The default path is provided by the Collector package. If the specified path is changed from the default value, the path should be an existing directory on the node. The |
|
|
Total memory in MIB to allocate to the Collector; automatically calculates the ballast size. The |
|
|
Sets the ballast size for the Collector explicitly instead of the value calculated from the |
|
|
The source path to the Collector configuration YAML file. This file is copied to the |
|
|
Destination path of the Collector configuration file on the node. The |
|
|
The Collector configuration object. Everything underneath this object gets directly converted to YAML and becomes the Collector configuration file. Using this option preempts |
|
|
Sets the user or group ownership for the Collector service. The user or group is created if they do not exist. |
|
|
The Collector package repository stage to use. Can be |
|
|
Whether to install or manage Fluentd and dependencies for log collection. On Linux, the dependencies include |
|
|
Version of the td-agent (Fluentd) package to install |
|
|
Source path to the Fluentd configuration file. This file is copied to the |
|
|
Whether to install or manage Splunk OpenTelemetry Zero Configuration Auto Instrumentation for Java. When set to |
|
|
Version of the |
|
|
By default, the |
|
|
Path to the Splunk OpenTelemetry Java agent. The default path is provided by the |
|
|
Configure the OpenTelemetry instrumentation resource attributes, for example, |
|
|
Explicitly sets the service name for the instrumented Java application, for example, |
|