github.com/netdata/go.d.plugin@v0.58.1/modules/k8s_kubelet/integrations/kubelet.md (about) 1 <!--startmeta 2 custom_edit_url: "https://github.com/netdata/go.d.plugin/edit/master/modules/k8s_kubelet/README.md" 3 meta_yaml: "https://github.com/netdata/go.d.plugin/edit/master/modules/k8s_kubelet/metadata.yaml" 4 sidebar_label: "Kubelet" 5 learn_status: "Published" 6 learn_rel_path: "Data Collection/Kubernetes" 7 most_popular: True 8 message: "DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE" 9 endmeta--> 10 11 # Kubelet 12 13 14 <img src="https://netdata.cloud/img/kubernetes.svg" width="150"/> 15 16 17 Plugin: go.d.plugin 18 Module: k8s_kubelet 19 20 <img src="https://img.shields.io/badge/maintained%20by-Netdata-%2300ab44" /> 21 22 ## Overview 23 24 This collector monitors Kubelet instances. 25 26 27 28 29 This collector is supported on all platforms. 30 31 This collector supports collecting metrics from multiple instances of this integration, including remote instances. 32 33 34 ### Default Behavior 35 36 #### Auto-Detection 37 38 This integration doesn't support auto-detection. 39 40 #### Limits 41 42 The default configuration for this integration does not impose any limits on data collection. 43 44 #### Performance Impact 45 46 The default configuration for this integration is not expected to impose a significant performance impact on the system. 47 48 49 ## Metrics 50 51 Metrics grouped by *scope*. 52 53 The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels. 54 55 56 57 ### Per Kubelet instance 58 59 These metrics refer to the entire monitored application. 60 61 This scope has no labels. 62 63 Metrics: 64 65 | Metric | Dimensions | Unit | 66 |:------|:----------|:----| 67 | k8s_kubelet.apiserver_audit_requests_rejected | rejected | requests/s | 68 | k8s_kubelet.apiserver_storage_data_key_generation_failures | failures | events/s | 69 | k8s_kubelet.apiserver_storage_data_key_generation_latencies | 5_µs, 10_µs, 20_µs, 40_µs, 80_µs, 160_µs, 320_µs, 640_µs, 1280_µs, 2560_µs, 5120_µs, 10240_µs, 20480_µs, 40960_µs, +Inf | observes/s | 70 | k8s_kubelet.apiserver_storage_data_key_generation_latencies_percent | 5_µs, 10_µs, 20_µs, 40_µs, 80_µs, 160_µs, 320_µs, 640_µs, 1280_µs, 2560_µs, 5120_µs, 10240_µs, 20480_µs, 40960_µs, +Inf | percentage | 71 | k8s_kubelet.apiserver_storage_envelope_transformation_cache_misses | cache misses | events/s | 72 | k8s_kubelet.kubelet_containers_running | total | running_containers | 73 | k8s_kubelet.kubelet_pods_running | total | running_pods | 74 | k8s_kubelet.kubelet_pods_log_filesystem_used_bytes | a dimension per namespace and pod | B | 75 | k8s_kubelet.kubelet_runtime_operations | a dimension per operation type | operations/s | 76 | k8s_kubelet.kubelet_runtime_operations_errors | a dimension per operation type | errors/s | 77 | k8s_kubelet.kubelet_docker_operations | a dimension per operation type | operations/s | 78 | k8s_kubelet.kubelet_docker_operations_errors | a dimension per operation type | errors/s | 79 | k8s_kubelet.kubelet_node_config_error | experiencing_error | bool | 80 | k8s_kubelet.kubelet_pleg_relist_interval_microseconds | 0.5, 0.9, 0.99 | microseconds | 81 | k8s_kubelet.kubelet_pleg_relist_latency_microseconds | 0.5, 0.9, 0.99 | microseconds | 82 | k8s_kubelet.kubelet_token_requests | total, failed | token_requests/s | 83 | k8s_kubelet.rest_client_requests_by_code | a dimension per HTTP status code | requests/s | 84 | k8s_kubelet.rest_client_requests_by_method | a dimension per HTTP method | requests/s | 85 86 ### Per volume manager 87 88 These metrics refer to the Volume Manager. 89 90 This scope has no labels. 91 92 Metrics: 93 94 | Metric | Dimensions | Unit | 95 |:------|:----------|:----| 96 | k8s_kubelet.volume_manager_total_volumes | actual, desired | state | 97 98 99 100 ## Alerts 101 102 103 The following alerts are available: 104 105 | Alert name | On metric | Description | 106 |:------------|:----------|:------------| 107 | [ kubelet_node_config_error ](https://github.com/netdata/netdata/blob/master/health/health.d/kubelet.conf) | k8s_kubelet.kubelet_node_config_error | the node is experiencing a configuration-related error (0: false, 1: true) | 108 | [ kubelet_token_requests ](https://github.com/netdata/netdata/blob/master/health/health.d/kubelet.conf) | k8s_kubelet.kubelet_token_requests | number of failed Token() requests to the alternate token source | 109 | [ kubelet_token_requests ](https://github.com/netdata/netdata/blob/master/health/health.d/kubelet.conf) | k8s_kubelet.kubelet_token_requests | number of failed Token() requests to the alternate token source | 110 | [ kubelet_operations_error ](https://github.com/netdata/netdata/blob/master/health/health.d/kubelet.conf) | k8s_kubelet.kubelet_operations_errors | number of Docker or runtime operation errors | 111 | [ kubelet_operations_error ](https://github.com/netdata/netdata/blob/master/health/health.d/kubelet.conf) | k8s_kubelet.kubelet_operations_errors | number of Docker or runtime operation errors | 112 113 114 ## Setup 115 116 ### Prerequisites 117 118 No action required. 119 120 ### Configuration 121 122 #### File 123 124 The configuration file name for this integration is `go.d/k8s_kubelet.conf`. 125 126 127 You can edit the configuration file using the `edit-config` script from the 128 Netdata [config directory](https://github.com/netdata/netdata/blob/master/docs/configure/nodes.md#the-netdata-config-directory). 129 130 ```bash 131 cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata 132 sudo ./edit-config go.d/k8s_kubelet.conf 133 ``` 134 #### Options 135 136 The following options can be defined globally: update_every, autodetection_retry. 137 138 139 <details><summary>Config options</summary> 140 141 | Name | Description | Default | Required | 142 |:----|:-----------|:-------|:--------:| 143 | update_every | Data collection frequency. | 1 | no | 144 | autodetection_retry | Recheck interval in seconds. Zero means no recheck will be scheduled. | 0 | no | 145 | url | Server URL. | http://127.0.0.1:10255/metrics | yes | 146 | timeout | HTTP request timeout. | 1 | no | 147 | username | Username for basic HTTP authentication. | | no | 148 | password | Password for basic HTTP authentication. | | no | 149 | proxy_url | Proxy URL. | | no | 150 | proxy_username | Username for proxy basic HTTP authentication. | | no | 151 | proxy_password | Password for proxy basic HTTP authentication. | | no | 152 | method | HTTP request method. | GET | no | 153 | body | HTTP request body. | | no | 154 | headers | HTTP request headers. | | no | 155 | not_follow_redirects | Redirect handling policy. Controls whether the client follows redirects. | no | no | 156 | tls_skip_verify | Server certificate chain and hostname validation policy. Controls whether the client performs this check. | no | no | 157 | tls_ca | Certification authority that the client uses when verifying the server's certificates. | | no | 158 | tls_cert | Client TLS certificate. | | no | 159 | tls_key | Client TLS key. | | no | 160 161 </details> 162 163 #### Examples 164 165 ##### Basic 166 167 A basic example configuration. 168 169 ```yaml 170 jobs: 171 - name: local 172 url: http://127.0.0.1:10255/metrics 173 174 ``` 175 ##### HTTPS with self-signed certificate 176 177 Do not validate server certificate chain and hostname. 178 179 180 <details><summary>Config</summary> 181 182 ```yaml 183 jobs: 184 - name: local 185 url: http://127.0.0.1:10250/metrics 186 tls_skip_verify: yes 187 188 ``` 189 </details> 190 191 192 193 ## Troubleshooting 194 195 ### Debug Mode 196 197 To troubleshoot issues with the `k8s_kubelet` collector, run the `go.d.plugin` with the debug option enabled. The output 198 should give you clues as to why the collector isn't working. 199 200 - Navigate to the `plugins.d` directory, usually at `/usr/libexec/netdata/plugins.d/`. If that's not the case on 201 your system, open `netdata.conf` and look for the `plugins` setting under `[directories]`. 202 203 ```bash 204 cd /usr/libexec/netdata/plugins.d/ 205 ``` 206 207 - Switch to the `netdata` user. 208 209 ```bash 210 sudo -u netdata -s 211 ``` 212 213 - Run the `go.d.plugin` to debug the collector: 214 215 ```bash 216 ./go.d.plugin -d -m k8s_kubelet 217 ``` 218 219