Installing and Configuring Dynatrace Full-Stack Add-on for VMware Tanzu
This topic explains how to install and configure the Dynatrace Full-Stack Add-on for VMware Tanzu.
Note: The syntax for the Dynatrace manifest is identical for TAS and PKS. As such, if no detailed include/exclude rules are used the same manifest can be utilized for both TAS and PKS. In deployments utilizing Pivotal Operations Manager (OpsMan) 2.5 or greater where both TAS and PKS are configured by the same OpsMan instance, this means both TAS and PKS can be monitored simulatenously via a single deployment of the Dynatrace Full-Stack Add-on.
Create the Dynatrace Manifest
Follow these steps to create the Dynatrace manifest for your deployment:
- Create a Dynatrace manifest file called
runtime-config-dynatrace.yml
, using the code below as a template to get started.
Note: With Operations Manager 2.9, the use of properties at the add-on level has been deprecated. These properties have been moved to the job level.
releases:
- name: dynatrace-oneagent
version: 1.3.2
addons:
- name: dynatrace-oneagent-addon
jobs:
- name: dynatrace-oneagent
release: dynatrace-oneagent
properties:
dynatrace:
environmentid: <environmentId>
apitoken: <paas-token>
###
# optional properties below
###
# Replace with your Dynatrace Managed URL, including the environment ID.
# An example URL might look like the following
apiurl: https://{your-managed-cluster.com}/e/{environmentid}/api
# Set to 'all' if you want to accept all self-signed SSL certificates.
sslmode: all
# Specify a direct download URL for Dynatrace OneAgent.
# If this propery is set, BOSH will download OneAgent from this location.
downloadurl: https://direct-download-url-for-agent
# Specify the proxy to be used for communication.
proxy: https://your-proxy-url
# Specify in which hostgroup the VMs in this deployments belong
hostgroup: example_hostgroup
# Define host tags for the VMs in this deployment
hosttags: landscape=production team=my_team
# Define custom properties for the VMs in this deployment
hostprops: Department=Acceptance Stage=Sprint
# Enable cloud infrastructure monitoring mode.
# Set this to 1 to activate it
infraonly: 0
# Enable validation of the download via certificate
# Set this to true to active it
validatedownload: false
# Hand over any installer argument
# Use either this OR the hostgroup, hosttags, infraonly, proxy properties.
# Usage of 'installerargs' will overwrite the others!
# Usage of USER= and GROUP= arguments will change user and group for plugin and network agents
installerargs: USER=vcap GROUP=vcap
include:
deployments:
- name-of-your-deployment
stemcell:
- os: ubuntu-xenial
exclude:
lifecycle: errand
# optional: extra addon configuration for Windows cells
- name: dynatrace-oneagent-windows-addon
jobs:
- name: dynatrace-oneagent-windows
release: dynatrace-oneagent
properties:
dynatrace:
environmentid: <environmentId>
apitoken: <paas-token>
# All of the optional properties for the Linux addon shown above (for example, apiurl, hostgroup) can also be used here. include:
deployments:
- name-of-your-deployment
stemcell:
- os: windows1803
exclude:
lifecycle: errand
Replace the values listed in the template as follows:
releases: - version
: Specify the version number of your Dynatrace Full-Stack Add-on for VMware Tanzu download from Pivotal Network.jobs: - name
: Do not change the name of this job. It must bedynatrace-oneagent
for Linux VMs.include: stemcell - os<
: Change to the OS type of your linux stemcell(s).environmentid
: Replace with your Dynatrace environment ID.apitoken
: Replace with your PaaS token from the Dynatrace UI.apiurl
: If using Dynatrace Managed, replace with your Dynatrace Managed URL, including the environment ID. An example URL might look like the following:https://{your-managed-cluster.com}/e/{environmentid}/api
(Optional) The add-on supports additional configuration properties:
sslmode
: Set toall
if you want to accept all self-signed SSL certificates.downloadurl
: Specify a direct download URL for Dynatrace OneAgent. If this propery is set, BOSH will download OneAgent from this location.proxy
: Specify the proxy to be used for communication.hostgroup
: Specify hostgroup for VMs in this deployment.hosttags
: Specify host tags for VMs in this deployment.hostprops
: Specify custom properties for VMs in this deployment.infraonly
: Set to1
to enable cloud infrastructure monitoring mode. This disables all deep process monitoring.validatedownload
: Set totrue
to enable validation of the download via certificate.installerargs
: Supports Dynatrace installer arguments, suggested values include setting USER=vcap and GROUP=vcap to allow Dynatrace plugins to monitor HAProxy. Note, setting hostgroup, hosttags, infraonly, proxy properties here will override settings deployed elsewhere in runtime config.
If you also want to deploy Dynatrace to Windows Diego cells, configure a second add-on section for the
dynatrace-oneagent-windows
job. The properties forenvironmentid
,apitoken
, andapiurl
remain the same as with the normal Linux configuration.jobs: - name
: For Windows cells, this must bedynatrace-oneagent-windows
.include: stemcell - os
: Change to the OS type of your Windows stemcell(s).
Note: To modify the configuration of an existing deployment, you must update the manifest file and redeploy.
Download and Deploy the Dynatrace Full-Stack Add-on for VMware Tanzu
After deploying Ops Manager, do the following to download and deploy the Dynatrace Full-Stack Add-on for VMware Tanzu:
Download the Dynatrace Full-Stack Add-on for VMware Tanzu software binary from Pivotal Network to your local machine.
Copy the software binary to your Ops Manager instance.
$ scp -i PATH/TO/PRIVATE/KEY dynatrace-release.tar.gz ubuntu@YOUR-OPS-MANAGER-VM-IP:
Copy the Dynatrace manifest file to your Ops Manager instance.
$ scp -i PATH/TO/PRIVATE/KEY runtime-config-dynatrace.yml ubuntu@YOUR-OPS-MANAGER-VM-IP:
SSH into Ops Manager.
$ ssh -i PATH-TO-PRIVATE-KEY ubuntu@YOUR-OPS-MANAGER-VM-IP
On the Ops Manager VM, navigate to the software binary location in your working directory.
$ cd PATH-TO-BINARY
Log in to the BOSH Director.
-
On the Ops Manager VM, create an alias in the BOSH CLI for your BOSH Director IP address. For example:
$ bosh alias-env my-env -e 10.0.16.10
-
Log in to the BOSH Director, specifying the newly created alias.
For example:
$ bosh -e my-env login
-
On the Ops Manager VM, create an alias in the BOSH CLI for your BOSH Director IP address. For example:
Upload your release.
$ bosh -e my-env upload-release PATH-TO-BINARY/dynatrace-release.tar.gz
(Optional) From the command line, you can confirm that upload of the Dynatrace software binary is complete. You should see the Dynatrace binary file.
$ bosh -e my-env releases
Update your runtime configuration to include the Dynatrace Add-on for VMware Tanzu.
Note: If you installed other BOSH add-ons, you must merge the Dynatrace manifest into your existing add-on manifest. Append the contents of
runtime-config-dynatrace.yml
to your existing add-on YML file.$ bosh -e my-env update-runtime-config PATH/runtime-config-dynatrace.yml
Verify your runtime configuration changes match what you specified in the Dynatrace manifest file.
$ bosh -e my-env runtime-config
For example:Acting as user 'admin' on 'micro' releases: - {name: dynatrace-oneagent, version: 1.3.2} addons: - name: dynatrace-oneagent-addon jobs: - name: dynatrace-oneagent release: dynatrace-oneagent ...
Navigate to your Installation Dashboard in Ops Manager.
Click Apply Changes.
Advanced Configuration
This section explains advanced configuration of the Dynatrace Full-Stack Add-on for VMware Tanzu.
About the Hostgroup Property
Dynatrace utilizes host group functionality to automatically group hosts. Host groups make it easier to apply unique configurations within Dynatrace to groups of hosts. Functionality that can be configured based on host group includes anomaly detection and OneAgent updates. Host groups also change how process groups are detected. When the same process is running in two different host groups, Dynatrace will create one process group for each host group. Additionally, automatic tagging can make use of host groups.
For more information read the full host group documentation.
Hostgroup Property Examples
An example use of the hostgroup property is to create hostgroups for individual Pivotal Container Service (PKS) clusters
- Log in to the BOSH Director.
-
Log in to PKS.
For example:
$ pks login -a api.pks.somedomain.com -u someusername
-
Log in to PKS.
For example:
Determine the UUID for the PKS cluster (will begin with service-instance_)
-
For example:
$ pks cluster my-cluster
output snipped for brevity:UUID: a4604071-07df-49e7-92d1-2effc9e3fe42
-
For example:
Create a Dynatrace manifest file called
runtime-config-dynatrace.yml
, using the code below as a template to get started.
releases:
- {name: dynatrace-oneagent, version: 1.3.2}
addons:
- name: dynatrace-oneagent-addon
jobs:
- name: dynatrace-oneagent
release: dynatrace-oneagent
include:
deployments:
# enter the BOSH deployment name, in the format of service-instance_<UUID-OBTAINED-IN-PREVIOUS-STEP>
- service-instance_a4604071-07df-49e7-92d1-2effc9e3fe42
stemcell:
- os: ubuntu-xenial
exclude:
lifecycle: errand
properties:
dynatrace:
environmentid: <environmentid>
apitoken: <token>
# Specify a hostgroup for this PKS cluster
hostgroup: pks_cluster_xyz
Update your runtime configuration to include the Dynatrace Add-on for VMware Tanzu.
$ bosh -e my-env update-runtime-config PATH/runtime-config-dynatrace.yml
Navigate to your Installation Dashboard in Ops Manager.
Click Apply Changes.
Multiple Deployment Host Group Example
When applying host groups to multiple deployments, the entire addon block is duplicated with unique job names, see below example:
releases:
- {name: dynatrace-oneagent, version: 1.3.2}
addons:
- name: dynatrace-oneagent-addon-xyz
jobs:
- name: dynatrace-oneagent
release: dynatrace-oneagent
include:
deployments:
# enter the BOSH deployment name, in the format of service-instance_<UUID-OBTAINED-IN-PREVIOUS-STEP>
- service-instance_a4604071-07df-49e7-92d1-2effc9e3fe42
stemcell:
- os: ubuntu-xenial
exclude:
lifecycle: errand
properties:
dynatrace:
environmentid: <environmentid>
apitoken: <token>
# Specify a hostgroup for this PKS cluster
hostgroup: pks_cluster_xyz
- name: dynatrace-oneagent-abc
jobs:
- name: dynatrace-oneagent
release: dynatrace-oneagent
include:
deployments:
# enter the BOSH deployment name, in the format of service-instance_<UUID-OBTAINED-IN-PREVIOUS-STEP>
- service-instance_adee170c-21ba-4274-97a4-cab13ed07bb7
stemcell:
- os: ubuntu-xenial
exclude:
lifecycle: errand
properties:
dynatrace:
environmentid: <environmentid>
apitoken: <token>
# Specify a hostgroup for this PKS cluster
hostgroup: pks_cluster_abc