Supported telemetry types
The Apache Mesos integration supports these telemetry types:Prerequisites
The Apache Mesos integration has the following prerequisites:- Make the HTTP API of each Mesos master and agent, and the HTTP server of each
Aurora scheduler, reachable from the CXDOT Collector. By default, masters listen on
port
5050and agents listen on port5051. An Aurora scheduler listens on the port that its-http_portflag sets. - Allow unauthenticated read access to each master and agent. The CXDOT Collector
doesn’t send credentials, so a master or agent that runs with
--authenticate_http_readonly=truerejects its requests. Mesos allows unauthenticated read access by default.
Configure
The Apache Mesos integration is enabled by default and collects from the masters, agents, and schedulers that you list. In a typical deployment, the CXDOT Collector runs on each Mesos node and collects from the Mesos processes on that node. To configure the Apache Mesos integration, follow these steps:-
On each agent node, list the local agent and set
cluster_name. For example, add the following to the Collector configuration file on an agent node:The CXDOT Collector reportscluster_nameas themesos.clusterattribute on every metric. The Collector doesn’t read the cluster name from Mesos, so set the same value on every node in one cluster. The Collector adds the node’shost.nameto every metric, which identifies the node when every endpoint islocalhost. -
On each master node, list the local master and set
cluster_name. For example, add the following to the Collector configuration file on a master node:Configure every master node, not only the current leader. Every master reports its own process and host metrics, but only the elected leading master reports cluster-wide metrics, such as task, agent, framework, and resource counts. Configuring every master keeps cluster-wide metrics arriving after Mesos elects a new leader, and still reports one copy of them. -
Optional: Collect from Aurora schedulers. On each scheduler node, list the local
scheduler at the port that its
-http_portflag sets, and setcluster_nameto the value you set for the Mesos cluster that the schedulers run on. For example:Configure every scheduler node. Every scheduler reports its own process metrics, but only the leading scheduler reports cluster metrics, such as task counts, resource offers, preempted tasks, and cron activity. -
Optional: Report per-framework, per-role, and per-task metrics. Set
frameworksandroleson master nodes andtaskson agent nodes. For example, the following values on a master node report per-framework metrics for themarathonframework and per-role metrics for theproductionrole:On an agent node,tasks: [checkout]underagentreports the allocated resources of each task whose name containscheckout. These metrics are off by default because each framework name, role name, and matching task adds time series. Framework and role names must match exactly. Task name fragments match any part of a task name, ignoring case. To report every framework or every role instead, setmaster.all_frameworksormaster.all_rolestotrue.
mesos key, with a master, agent, or aurora
block for each process.
To collect from a node that doesn’t run the CXDOT Collector, list that node’s address
instead of localhost in another node’s configuration. List each master, agent, and
scheduler for only one Collector, because a target that two Collectors list reports
its metrics twice. If you run the Collector in Kubernetes instead, list each node’s
address under config.integrations.mesos in the Helm values file for your CXDOT
Collector.
Validate
To validate the Apache Mesos integration, follow these steps:-
In Metrics Explorer, run the following query:
Confirm that the query returns one time series for each master, agent, and scheduler that you configured, identified by
host.nameand the URL in thecxdot.integration.targetattribute, and that each one reports1. -
In Metrics Explorer, run the following query:
Confirm that the result matches the number of active agents in each cluster.
Troubleshooting
- A target reports
0forcxdot.integration.target.health: Confirm that the endpoint is reachable from the CXDOT Collector, allows unauthenticated read access, and is listed under the role its process runs. A master listed underagent.endpoints, or an agent listed undermaster.endpoints, reports0. - An Aurora scheduler reports
0forcxdot.integration.target.health: Confirm that the port in its endpoint matches the-http_portflag that the scheduler runs with. A scheduler started without-http_portlistens on a random port that can change each time it restarts. To test the endpoint, request/vars.jsonfrom it, such ascurl http://localhost:8081/vars.json, and confirm that it returns a successful status code. - Per-task metrics don’t appear: Confirm that a fragment in
agent.tasksmatches part of the task name and that the task is active. When the fragments match more tasks on one agent thanagent.max_tasksallows, the CXDOT Collector reports no per-task metrics for that agent and reportscxdot.integration.target.healthas0for it. - Per-framework or per-role metrics don’t appear with
all_frameworksorall_rolesset: When the elected master reports more framework names thanmaster.max_frameworks, or more roles thanmaster.max_roles, the CXDOT Collector reports none of those metrics and reportscxdot.integration.target.healthas0for the master.
Configuration reference
Configure one Apache Mesos integration instance with the following settings. In Helm values, place these settings underconfig.integrations.mesos. In a Collector configuration file, place
them under cxdot.integrations.mesos.
Optional settings
-
enabledType:boolean. Optional. Default:true. Whether to enable this Apache Mesos integration instance. If true, the Collector runs the instance. If false, the Collector doesn’t run it. -
collection_intervalType:duration. Optional. Default:2m. How often the Collector collects metrics from each master, agent, and Aurora scheduler. -
timeoutType:duration. Optional. Default:1m. Maximum time for one collection from a master, agent, or Aurora scheduler. The Collector caps the timeout atcollection_interval. -
tlsType:object. Optional. TLS settings for masters, agents, and Aurora schedulers whose endpoints arehttpsURLs. The Collector doesn’t use these settings for an endpoint inhost:portform, which it reaches over HTTP. The Collector verifies server certificates by default. -
tls.ca_fileType:string. Optional. Path to a PEM-encoded certificate authority (CA) certificate file used to verify the server certificates of masters, agents, and Aurora schedulers. If omitted, the Collector uses the system certificate authority pool. -
tls.ca_pemType:string. Optional. PEM-encoded certificate authority certificate content used to verify the server certificates of masters, agents, and Aurora schedulers. -
tls.cert_fileType:string. Optional. Path to the PEM-encoded client certificate file to present when masters, agents, and Aurora schedulers require mutual TLS authentication. -
tls.cert_pemType:string. Optional. PEM-encoded client certificate content to present when masters, agents, and Aurora schedulers require mutual TLS authentication. -
tls.cipher_suitesType:array of string. Optional. TLS cipher suites that the Collector can use, in preference order. If omitted, the Collector uses the secure defaults from the Go TLS library. For supported names, see https://go.dev/src/crypto/tls/cipher_suites.go. -
tls.curve_preferencesType:array of string. Optional. Elliptic curves that the Collector can use for an elliptic curve Diffie-Hellman ephemeral handshake, in preference order. If omitted, the Collector uses the Go TLS library defaults. -
tls.include_system_ca_certs_poolType:boolean. Optional. Whether to add certificates from the system certificate authority pool to the configured certificate authorities. If true, the Collector trusts both sources. If false, the Collector trusts only the configured certificate authorities. -
tls.insecureType:boolean. Optional. Whether to ignore the other TLS settings when no certificate authority is configured. If true and neitherca_filenorca_pemis set, the Collector connects to HTTPS endpoints with default TLS settings and verifies their certificates against the system certificate authority pool. If false, the Collector applies the configured TLS settings. The scheme of each endpoint, not this setting, decides whether the Collector uses TLS. -
tls.insecure_skip_verifyType:boolean. Optional. Whether to skip verification of the server certificates of masters, agents, and Aurora schedulers. If true, the connection is encrypted but isn’t authenticated and is vulnerable to man-in-the-middle attacks. If false, the Collector verifies the certificates. -
tls.key_fileType:string. Optional. Path to the PEM-encoded client private key file used withcert_filefor mutual TLS authentication. -
tls.key_pemType:string. Optional. PEM-encoded client private key content used withcert_pemfor mutual TLS authentication. -
tls.max_versionType:string. Optional. Maximum TLS protocol version the Collector can use. If omitted, the Collector uses the maximum version supported by the Go TLS library. -
tls.min_versionType:string. Optional. Minimum TLS protocol version the Collector can use. If omitted, the minimum version is TLS 1.2. -
tls.reload_intervalType:duration. Optional. How often the Collector reloads certificate and key files. If omitted, the Collector doesn’t reload the files. -
tls.server_name_overrideType:string. Optional. Server name to verify in the certificates of masters, agents, and Aurora schedulers instead of the endpoint hostname. Use this setting when the certificate name differs from the endpoint hostname. -
tls.tpmType:object. Optional. Trusted platform module settings for the TLS private key. -
tls.tpm.authType:string. Optional. Authorization value for the trusted platform module key. -
tls.tpm.enabledType:boolean. Optional. Whether to use a trusted platform module for the TLS private key. If true, the Collector loads the key from the configured device or socket. If false, the Collector uses the configured key file or in-memory key. -
tls.tpm.owner_authType:string. Optional. Owner authorization value for the trusted platform module. -
tls.tpm.pathType:string. Optional. Path to the trusted platform module device or Unix domain socket, such as/dev/tpm0or/dev/tpmrm0. -
masterType:object. Optional. Settings for collecting from Mesos masters. Every master reports its own process and host metrics. Only the elected leading master reports cluster-wide metrics, because a standby master’s copies of them are stale or zero. Listing every master therefore reports one copy of the cluster-wide metrics. -
master.enabledType:boolean. Optional. Default:true. Whether to collect from Mesos masters. If true, the Collector collects from the masters inmaster.endpoints. If false, the Collector doesn’t collect from any master. -
master.endpointsType:array of object. Optional. Default:[]. Masters to collect from. Each entry is the IP address or hostname of one master, as the Collector reaches it, and the port of the master’s HTTP API, which is5050by default. Don’t include a path. The Collector reaches an entry inhost:portform over HTTP. To reach a master over HTTPS, give the full URL, such ashttps://mesos-master-1.example.com:5050. List every master so that cluster-wide metrics continue after a new leader is elected. -
master.endpoints[].endpointType:string. Required. Master endpoint as eitherhost:portor a full HTTP or HTTPS URL without a path. Forhost:port, the Collector uses HTTP. -
master.cluster_nameType:string. Optional. Minimum length:1. Value of themesos.clusterattribute on every metric from a master. Required whenmaster.endpointslists a master. The Collector doesn’t read the cluster name from Mesos, so set the same value for every master and agent in one cluster. -
master.frameworksType:array of string. Optional. Default:[]. Exact names of the frameworks for which the elected master reports per-framework task counts and allocated resources. Frameworks that share a name are reported together. When empty, the Collector reports no per-framework metrics unlessall_frameworksistrue. Each name adds time series. -
master.all_frameworksType:boolean. Optional. Default:false. Whether to report per-framework metrics for every framework registered with the elected master. If true,frameworksmust be empty, and each distinct framework name adds four time series. Frameworks that share a name are reported together, but a cluster that registers a framework under a new name for every job adds time series with each job. If false, the Collector reports per-framework metrics only for the names inframeworks. -
master.max_frameworksType:integer. Optional. Default:1000. Minimum:1. Maximum number of distinct framework names that one collection reports whenall_frameworksistrue. When the elected master reports more, the Collector reports no per-framework metrics from that collection and reportscxdot.integration.target.healthas0for the master. The collection’s other metrics are still reported. -
master.rolesType:array of string. Optional. Default:[]. Exact names of the roles for which the elected master reports per-role framework counts, weights, and allocated resources. When empty, the Collector reports no per-role metrics and doesn’t request role information unlessall_rolesistrue. Each name adds time series. -
master.all_rolesType:boolean. Optional. Default:false. Whether to report per-role metrics for every role that the elected master lists, including the default role*. If true,rolesmust be empty, and each role adds up to five time series. If false, the Collector reports per-role metrics only for the names inroles. -
master.max_rolesType:integer. Optional. Default:1000. Minimum:1. Maximum number of roles that one collection reports whenall_rolesistrue. When the elected master lists more, the Collector reports no per-role metrics from that collection and reportscxdot.integration.target.healthas0for the master. The collection’s other metrics are still reported. -
agentType:object. Optional. Settings for collecting from Mesos agents. -
agent.enabledType:boolean. Optional. Default:true. Whether to collect from Mesos agents. If true, the Collector collects from the agents inagent.endpoints. If false, the Collector doesn’t collect from any agent. -
agent.endpointsType:array of object. Optional. Default:[]. Agents to collect from. Each entry is the IP address or hostname of one agent, as the Collector reaches it, and the port of the agent’s HTTP API, which is5051by default. Don’t include a path. Entries take the samehost:portand URL forms asmaster.endpoints. -
agent.endpoints[].endpointType:string. Required. Agent endpoint as eitherhost:portor a full HTTP or HTTPS URL without a path. Forhost:port, the Collector uses HTTP. -
agent.cluster_nameType:string. Optional. Minimum length:1. Value of themesos.clusterattribute on every metric from an agent. Required whenagent.endpointslists an agent. The Collector doesn’t read the cluster name from Mesos, so set the same value for every master and agent in one cluster. -
agent.tasksType:array of string. Optional. Default:[]. Task name fragments that select tasks for per-task metrics. For each active task on an agent whose name contains a fragment, ignoring case, the Collector reports the task’s allocated CPUs, memory, and disk, labeled with the task name, task ID, and framework ID. A nonempty list adds a request for the agent’s full state to every collection. When empty, the Collector reports no per-task metrics. A blank fragment is rejected because it matches every task. -
agent.max_tasksType:integer. Optional. Default:1000. Minimum:1. Maximum number of active tasks thatagent.taskscan select on one agent. When the fragments match more tasks, the Collector reports no per-task metrics for that agent and reportscxdot.integration.target.healthas0for it. -
auroraType:object. Optional. Settings for collecting from Apache Aurora schedulers. Every scheduler reports its own process metrics. Only the leading scheduler reports cluster metrics, such as task counts, resource offers, preempted tasks, and cron activity, so listing every scheduler reports one copy of them. -
aurora.enabledType:boolean. Optional. Default:true. Whether to collect from Apache Aurora schedulers. If true, the Collector collects from the schedulers inaurora.endpoints. If false, the Collector doesn’t collect from any scheduler. -
aurora.endpointsType:array of object. Optional. Default:[]. Aurora schedulers to collect from. Each entry is the IP address or hostname of one scheduler, as the Collector reaches it, and the port of its HTTP server, which its-http_portflag sets. Don’t include a path. Entries take the samehost:portand URL forms asmaster.endpoints. List every scheduler so that cluster metrics continue after a new leader is elected. -
aurora.endpoints[].endpointType:string. Required. Aurora scheduler endpoint as eitherhost:portor a full HTTP or HTTPS URL without a path. Forhost:port, the Collector uses HTTP. -
aurora.cluster_nameType:string. Optional. Minimum length:1. Value of themesos.clusterattribute on every metric from an Aurora scheduler. Required whenaurora.endpointslists a scheduler. Aurora doesn’t report the Mesos cluster that it runs on, so set themaster.cluster_nameof that cluster to select scheduler and cluster metrics together.