OpenTelemetry Agent - .NET Linux Installation
Installation Wizard
To help with the installation process, vFunction offers an Installation Wizard. This Wizard provides additional information about the Prerequisites as well as steps for deploying the OpenTelemetry Agent to your environment.
Please contact support@vfunction.com or your vFunction Contact(s) for the password to start using this Wizard.
Installation Steps
- Configure OpenTelemetry .NET Instrumentation for your App
NOTE: These steps are taken from OpenTelemetry .NET Automatic Instrumentation. Alternatively, you can manually configure instrumentation.
# Download the bash script
curl -sSfL https://github.com/open-telemetry/opentelemetry-dotnet-instrumentation/releases/latest/download/otel-dotnet-auto-install.sh -O
# Install core files
sh ./otel-dotnet-auto-install.sh
# Enable execution for the instrumentation script
chmod +x $HOME/.otel-dotnet-auto/instrument.sh
- Configure the .NET Startup Parameters
- Find-and-replace $PROTOCOL with http or https based on the VF Server configuration
- Find-and-replace $VF_SERVER_ADDRESS with the URL for login to your organization’s vFunction Server
- Find-and-replace $VF_APP_ID with the Application UUID created with the Installation Instructions provided after creating the Distributed Application in the vFunction Server UI
OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf
OTEL_EXPORTER_OTLP_ENDPOINT=$PROTOCOL://$VF_SERVER_ADDRESS/api/unauth/otlp
OTEL_TRACES_EXPORTER=otlp
OTEL_METRICS_EXPORTER=none
OTEL_LOGS_EXPORTER=none
OTEL_EXPORTER_OTLP_HEADERS=X-VF-APP=$VF_APP_ID
- Restart the application including the Startup Parameters and OpenTelemetry Instrumentation Script
export OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf
export OTEL_EXPORTER_OTLP_ENDPOINT=https://$VF_SERVER_ADDRESS/api/unauth/otlp
export OTEL_TRACES_EXPORTER=otlp
export OTEL_METRICS_EXPORTER=none
export OTEL_LOGS_EXPORTER=none
export OTEL_EXPORTER_OTLP_HEADERS=$VF_APP_ID
export OTEL_SERVICE_NAME=MyService
. $HOME/.otel-dotnet-auto/instrument.sh
dotnet run