From 5e3a74aa52f112cf85bf65f832acbf7f54b2c682 Mon Sep 17 00:00:00 2001 From: kongfei Date: Fri, 11 Aug 2023 16:48:17 +0800 Subject: [PATCH] do not collect docker metrics --- .goreleaser.yaml | 4 --- k8s/daemonset.yaml | 82 ---------------------------------------------- 2 files changed, 86 deletions(-) diff --git a/.goreleaser.yaml b/.goreleaser.yaml index 743e9c71..46c7916b 100644 --- a/.goreleaser.yaml +++ b/.goreleaser.yaml @@ -154,7 +154,6 @@ dockers: - conf/input.kernel_vmstat/kernel_vmstat.toml - conf/input.netstat/netstat.toml - conf/input.net/net.toml - - conf/input.docker/docker.toml - conf/input.kubernetes/kubernetes.toml - conf/input.processes/processes.toml use: buildx @@ -183,7 +182,6 @@ dockers: - conf/input.kernel_vmstat/kernel_vmstat.toml - conf/input.netstat/netstat.toml - conf/input.net/net.toml - - conf/input.docker/docker.toml - conf/input.kubernetes/kubernetes.toml - conf/input.processes/processes.toml use: buildx @@ -212,7 +210,6 @@ dockers: - conf/input.kernel_vmstat/kernel_vmstat.toml - conf/input.netstat/netstat.toml - conf/input.net/net.toml - - conf/input.docker/docker.toml - conf/input.kubernetes/kubernetes.toml - conf/input.processes/processes.toml use: buildx @@ -241,7 +238,6 @@ dockers: - conf/input.kernel_vmstat/kernel_vmstat.toml - conf/input.netstat/netstat.toml - conf/input.net/net.toml - - conf/input.docker/docker.toml - conf/input.kubernetes/kubernetes.toml - conf/input.processes/processes.toml use: buildx diff --git a/k8s/daemonset.yaml b/k8s/daemonset.yaml index a03deb68..22e8503d 100644 --- a/k8s/daemonset.yaml +++ b/k8s/daemonset.yaml @@ -177,76 +177,6 @@ data: # devices = ["sda", "sdb", "vd*"] --- kind: ConfigMap -metadata: - name: input-docker -apiVersion: v1 -data: - docker.toml: | - # # collect interval - # interval = 15 - - [[instances]] - # # append some labels for series - # labels = { region="cloud", product="n9e" } - - # # interval = global.interval * interval_times - # interval_times = 1 - - ## Docker Endpoint - ## To use TCP, set endpoint = "tcp://[ip]:[port]" - ## To use environment variables (ie, docker-machine), set endpoint = "ENV" - endpoint = "unix:///var/run/docker.sock" - - ## Set to true to collect Swarm metrics(desired_replicas, running_replicas) - gather_services = false - gather_extend_memstats = false - - container_id_label_enable = true - container_id_label_short_style = false - - ## Containers to include and exclude. Globs accepted. - ## Note that an empty array for both will include all containers - container_name_include = [] - container_name_exclude = [] - - ## Container states to include and exclude. Globs accepted. - ## When empty only containers in the "running" state will be captured. - ## example: container_state_include = ["created", "restarting", "running", "removing", "paused", "exited", "dead"] - ## example: container_state_exclude = ["created", "restarting", "running", "removing", "paused", "exited", "dead"] - # container_state_include = [] - # container_state_exclude = [] - - ## Timeout for docker list, info, and stats commands - timeout = "5s" - - ## Specifies for which classes a per-device metric should be issued - ## Possible values are 'cpu' (cpu0, cpu1, ...), 'blkio' (8:0, 8:1, ...) and 'network' (eth0, eth1, ...) - ## Please note that this setting has no effect if 'perdevice' is set to 'true' - perdevice_include = [] - - ## Specifies for which classes a total metric should be issued. Total is an aggregated of the 'perdevice' values. - ## Possible values are 'cpu', 'blkio' and 'network' - ## Total 'cpu' is reported directly by Docker daemon, and 'network' and 'blkio' totals are aggregated by this plugin. - ## Please note that this setting has no effect if 'total' is set to 'false' - total_include = ["cpu", "blkio", "network"] - - ## Which environment variables should we use as a tag - ##tag_env = ["JAVA_HOME", "HEAP_SIZE"] - - ## docker labels to include and exclude as tags. Globs accepted. - ## Note that an empty array for both will include all labels as tags - docker_label_include = [] - docker_label_exclude = ["annotation*", "io.kubernetes*", "*description*", "*maintainer*", "*hash", "*author*"] - - ## Optional TLS Config - # use_tls = false - # tls_ca = "/etc/telegraf/ca.pem" - # tls_cert = "/etc/telegraf/cert.pem" - # tls_key = "/etc/telegraf/key.pem" - ## Use TLS but skip chain & host verification - # insecure_skip_verify = false ---- -kind: ConfigMap metadata: name: input-kubernetes apiVersion: v1 @@ -595,8 +525,6 @@ spec: name: input-disk - mountPath: /etc/categraf/conf/input.diskio name: input-diskio - - mountPath: /etc/categraf/conf/input.docker - name: input-docker - mountPath: /etc/categraf/conf/input.kubernetes name: input-kubernetes - mountPath: /etc/categraf/conf/input.prometheus @@ -623,8 +551,6 @@ spec: - mountPath: /hostfs name: hostrofs readOnly: true - - mountPath: /var/run/docker.sock - name: docker-socket dnsPolicy: ClusterFirstWithHostNet serviceAccountName: n9e-categraf hostNetwork: true @@ -656,10 +582,6 @@ spec: defaultMode: 420 name: input-diskio name: input-diskio - - configMap: - defaultMode: 420 - name: input-docker - name: input-docker - configMap: defaultMode: 420 name: input-kubernetes @@ -708,7 +630,3 @@ spec: path: /var/run/utmp type: "" name: hostroutmp - - hostPath: - path: /var/run/docker.sock - type: Socket - name: docker-socket