我可以在Kubernetes Pod中运行Google Monitoring Agent吗? [英] Can I run Google Monitoring Agent inside a Kubernetes Pod?
问题描述
似乎 Google监测代理(由 Stackdriver em>)应安装在每个节点(即每个计算实例,即每台计算机)的一个 Kubernetes 集群中。
然而,新的插件,例如 Nginx , Redis , ElasticSearch ...,需要这些代理知道这些服务的IP。这意味着要运行并设置 kube-proxy
,这意味着要在Pod上运行 Google监视代理。
这两个冲突:一方面,代理监控整台机器,另一方面监控在一台或多台机器上运行的服务。
可以这些Stackdriver插件可用于 Google Container Engine (GKE)/ Kubernetes群集?
每台机器(内存,CPU,磁盘......)都可以在每个节点上安装代理程序(即在您的GKE集群的每个计算实例上)。请注意,它不适用于自动缩放,因为重新创建的节点不会安装代理。要监视服务(请求数/ s,客户端连接...)可以将代理插件安装在另一个容器中,例如Nginx Pod运行两个容器:
注意:尚未完全测试。
It seems that the Google Monitoring Agent (powered by Stackdriver) should be installed on each Node (i.e. each compute instance, i.e. each machine) of a Kubernetes cluster.
However the new plugins, like Nginx, Redis, ElasticSearch..., need those agents to know the IP of these services. This means having kube-proxy
running and set up which should mean running that Google Monitoring Agent on a Pod.
These two conflict: On one side that agent monitors the entire machine, on the other it monitor services running on one or more machines.
Can these Stackdriver plugins work on a Google Container Engine (GKE) / Kubernetes cluster?
To monitor each machine (memory, CPU, disk...) it's possible to install the agent on each node (i.e. on each Compute Instance of your GKE cluster). Note that it'll not work with auto-scaling in the sense that re-created nodes won't have the agent installed.
To monitor services (number of requests/s, client connection...) it's possible to install the agent plugin in another container so that for example Nginx Pod run two containers:
- Nginx
- Google Monitoring Agent together with the Nginx plugin
Note: Not fully tested yet.
这篇关于我可以在Kubernetes Pod中运行Google Monitoring Agent吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!