Scalyr K8 agent by default omits pod logs from certain systems namespaces such as kube-system
or kube-public
. If the pod logs you're interested in are not collected by the agent's default, you could set a dummy value (ex. test123) to the SCALYR_K8S_IGNORE_NAMESPACES parameter
in the Scalyr's configMap and the Scalyr agent would ingest all pod logs from the node.
Furthermore, you can also use the SCALYR_K8S_INCLUDE_NAMESPACES
option to restrict which namespaces for which logs and events are collected. The value should be a comma-separated list of the namespaces for which you wish to collect logs and events. Note that the option must be used in conjunction with enabling all pod logs via SCALYR_K8S_IGNORE_NAMESPACES
.
For example, to configure the Scalyr Agent to only collect from the frontends
and database
namespaces, you'll need to
- Edit configmap "scalyr-config" and add a dummy value to "k8s_ignore_namespaces".
SCALYR_K8S_IGNORE_NAMESPACES: test123
- Add the namespace you want to collect to the configMap
SCALYR_K8S_INCLUDE_NAMESPACES: frontends,database
- Restart the Scalyr agent to apply the changes.
Comments
0 comments
Please sign in to leave a comment.