Skip to content

percona/telemetry-agent

Repository files navigation

usage: ./call-home.sh OPTIONS

Collects telemetry information and sends it to a Telemetry service. The data collection
may be disabled via setting an environment variable [PERCONA_TELEMETRY_DISABLE=1].

The script validates only if mandatory parameters are provided.
It does not check the validity and itegritiy of provided parameters.

The data will be sent to https://check.percona.com/v1/telemetry/GenericReport in a JSON format.

OPTIONS can be:

  -h  Show this message

  -f  [PERCONA_PRODUCT_FAMILY]              Product family identifier.                                  [REQUIRED]
  -v  [PERCONA_PRODUCT_VERSION]             Product version.                                            [REQUIRED]
  -s  [PERCONA_OPERATING_SYSTEM]            Operating system identifier.                                [Default: autodetected with fallback to "unknown"]
  -d  [PERCONA_DEPLOYMENT_METHOD]           Deployment method.                                          [REQUIRED]
  -i  [PERCONA_INSTANCE_ID]                 Instance id                                                 [Default: autogenerated]
  -j  [PERCONA_TELEMETRY_CONFIG_FILE_PATH]  Path of the file where to store the unique ID of this node. [Default: /usr/local/percona/telemetry_uuid]
  -u  [PERCONA_TELEMETRY_URL]               Percona Telemetry Service endpoint                          [Default: https://check.percona.com/v1/telemetry/GenericReport]
  -c  [PERCONA_CONNECT_TIMEOUT]             Default timeout for the curl to establish connection.       [Default: 5]
  -t  [PERCONA_SEND_TIMEOUT]                Default timeout for the whole curl command.                 [Default: 10]

Note that -d PERCONA_PRODUCT_FAMILY can be set to any string, but only the following ones will be accepted
by Percona Telemetry service (there is no validation of the script side):

PRODUCT_FAMILY_PS
PRODUCT_FAMILY_PXC
PRODUCT_FAMILY_PXB
PRODUCT_FAMILY_PSMDB
PRODUCT_FAMILY_PBM
PRODUCT_FAMILY_POSTGRESQL
PRODUCT_FAMILY_PMM
PRODUCT_FAMILY_EVEREST
PRODUCT_FAMILY_PERCONA_TOOLKIT

For example,
on a CentOS7, you may run the script as:

././call-home.sh -f "PRODUCT_FAMILY_PS" -v "8.0.33" -s "$(cat /etc/redhat-release)" -i "13f5fc62-35b4-4716-b3e6-96c761fc204d" -j /tmp/percona.telemetry -u https://check.percona.com/v1/telemetry/GenericReport -c 1 -t 2

on Ubuntu, you may run the script as:
././call-home.sh -f "PRODUCT_FAMILY_PS" -v "8.0.33" -s "$(cat /etc/issue)" -i "13f5fc62-35b4-4716-b3e6-96c761fc204d" -j /tmp/percona.telemetry -u https://check.percona.com/v1/telemetry/GenericReport -c 1 -t 2