Let’s say I have a Kubernetes cluster with nodes kube01, kube02 and so on. The cluster is called kube and I’m using the Kubernetes agent. Like every other Linux machine there’s also the default Linux CheckMK agent.
For every node in Kubernetes I have two hosts in CheckMK:
One is for the Linux CheckMK agent and is called kube01
One is for the Kubernetes agent and called node_kube_kube01
I’d like to merge them into one host and created a rule “Hostname translation for piggybacked hosts” for that. However I have the following issues now:
All checks Interface .* vanished
The check " Kernel Performance" becomes UNKN with summary: item 'Process Creations' not unique (found 2 times)**UNKN**, Process Creations: 22.79/s, item 'Context Switches' not unique (found 2 times)**UNKN**, Context Switches: 18908.46/s, item 'Major Page Faults' not unique (found 2 times)**UNKN**, Major Page Faults: 0.03/s, item 'Page Swap in' not unique (found 2 times)**UNKN**, Page Swap in: 0.00/s, item 'Page Swap Out' not unique (found 2 times)**UNKN**, Page Swap Out: 0.00/s
The nodes are no longer visible on the default Kubernetes dashboard:
This is what you get when you have the full agent on your kubernetes hosts and also use the special agent for that kubernetes cluster. That duplicates a small subset of the services of this node and you have two hosts in CheckMK for a single node now.
For every node in Kubernetes I have two hosts in CheckMK:
One is for the Linux CheckMK agent and is called kube01
One is for the Kubernetes agent and called node_kube_kube01
If you managed to install the agent directly on the Kubernetes node (which is actually a privilege to be honest and not everybody is allowed to do so ) ,then its quite obvious that you will get more data and can supplement it furhter using the power of the native agent like you do on a classic Linux host. YOu just need to define appropriate labels to set the correct context of the nodes. Have a look at the propoerties of the node dashlet in order to determine the right combination.
Also, since you are able to install the agent directly on the K8 nodes, then I would say then don’t create the node host from the Piggyback data instead only create the other Kubernetes resources and the Kubernetes nodes can be created manually or automatically via the push mode of the agent.
When you want to combine the data from both the Piggyback and agent , then this won’t work as the data will result in a conflict and crash because the Checkmk agent is also executed as a daemonset in those nodes + you are running a direct agent on the linux host.