|
| 1 | +--- |
| 2 | +content_type: "reference" |
| 3 | +title: Node Labels Populated By The Kubelet |
| 4 | +weight: 40 |
| 5 | +--- |
| 6 | + |
| 7 | +Kubernetes {{< glossary_tooltip text="nodes" term_id="node" >}} come pre-populated |
| 8 | +with a standard set of {{< glossary_tooltip text="labels" term_id="label" >}}. |
| 9 | + |
| 10 | +You can also set your own labels on nodes, either through the kubelet configuration or |
| 11 | +using the Kubernetes API. |
| 12 | + |
| 13 | +## Preset labels |
| 14 | + |
| 15 | +The preset labels that Kubernetes sets on nodes are: |
| 16 | + |
| 17 | +* [`kubernetes.io/arch`](/docs/reference/labels-annotations-taints/#kubernetes-io-arch) |
| 18 | +* [`kubernetes.io/hostname`](/docs/reference/labels-annotations-taints/#kubernetes-io-hostname) |
| 19 | +* [`kubernetes.io/os`](/docs/reference/labels-annotations-taints/#kubernetes-io-os) |
| 20 | +* [`node.kubernetes.io/instance-type`](/docs/reference/labels-annotations-taints/#nodekubernetesioinstance-type) |
| 21 | + (if known to the kubelet – Kubernetes may not have this information to set the label) |
| 22 | +* [`topology.kubernetes.io/region`](/docs/reference/labels-annotations-taints/#topologykubernetesioregion) |
| 23 | + (if known to the kubelet – Kubernetes may not have this information to set the label) |
| 24 | +* [`topology.kubernetes.io/zone`](/docs/reference/labels-annotations-taints/#topologykubernetesiozone) |
| 25 | + (if known to the kubelet – Kubernetes may not have this information to set the label) |
| 26 | + |
| 27 | +{{<note>}} |
| 28 | +The value of these labels is cloud provider specific and is not guaranteed to be reliable. |
| 29 | +For example, the value of `kubernetes.io/hostname` may be the same as the node name in some environments |
| 30 | +and a different value in other environments. |
| 31 | +{{</note>}} |
| 32 | + |
| 33 | +## {{% heading "whatsnext" %}} |
| 34 | + |
| 35 | +- See [Well-Known Labels, Annotations and Taints](/docs/reference/labels-annotations-taints/) for a list of common labels. |
| 36 | +- Learn how to [add a label to a node](/docs/tasks/configure-pod-container/assign-pods-nodes/#add-a-label-to-a-node). |
| 37 | + |
0 commit comments