Configuration translation rules and tool π
translatesfx
is a command-line tool provided by Splunk Observability Cloud that helps you translate your existing Smart Agent YAML configuration file into a configuration that can be used by the Collector.
Caution
With translatesfx
you can automate most of the configuration changes when migrating from the Smart Agent to the Splunk OpenTelemetry Collector. Evaluate and test any configuration produced by translatesfx
carefully before releasing it into production environments.
Configuration translation rules π
To transform a Smart Agent configuration file into a Collector config file, you need to map the original parameters using the Collectorβs configuration syntax.
See the samples below:
Original Smart Agent config π
signalFxAccessToken: {"#from": "env:SFX_ACCESS_TOKEN"}
ingestUrl: {"#from": "ingest_url", default: "https://ingest.signalfx.com"}
apiUrl: {"#from": "api_url", default: "https://api.signalfx.com"}
traceEndpointUrl: {"#from": 'trace_endpoint_url', default: "https://ingest.signalfx.com/v2/trace"}
intervalSeconds: 10
logging:
level: info
monitors:
- {"#from": "monitors/*.yaml", flatten: true, optional: true}
- type: memory
Collector config output π
receivers:
smartagent/cpu:
type: cpu
smartagent/load:
type: load
smartagent/memory:
type: memory
exporters:
signalfx:
access_token: ${SFX_ACCESS_TOKEN}
realm: us1
service:
pipelines:
metrics:
receivers:
- smartagent/cpu
- smartagent/load
- smartagent/memory
exporters:
- signalfx
Note
Learn more in the GitHub documentation on translatefx
.
Use the configuration translation tool π
There are two approaches to using translatesfx
, either from the command line or from the GUI.
From the command line π
To run the tool from the command line, download the executables from the releases page . The executables are also contained in the RPM, MSI, and Debian packages as well as the Docker images (version 0.36.1 and higher).
The translatesfx
command requires a Smart Agent configuration file as the first argument, and accepts a directory as the optional second argument, which is the working directory used by any Smart Agent #from file expansion directives. The translatesfx
command uses this working directory to resolve any relative paths to files referenced by any #from directives at runtime.
% translatesfx <sfx-file> [<file expansion working directory>]
If this working directory argument is omitted, translatesfx expands relative file paths using the current working directory:
% translatesfx path/to/sfx/<config-filename>.yaml
% translatesfx /etc/signalfx/sa-config.yaml
When translatesfx runs, it sends the translated Collector configuration to the standard output. To write the contents to disk, redirect this output to a new Collector configuration file:
% translatesfx /etc/signalfx/sa-config.yaml > /etc/signalfxotel-config.yaml
From the GUI π
Access the Smart Agent configuration converter at https://bossofopsando11y.com/configurator/saconverter .
Paste your Smart Agent configuration in the
section of the GUI.
The corresponding translated Collector configuration file is populated in the OpenTelemetry YAML section.
