Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

encounter panic when turning on AutoKubernetesLabels #1524

Closed
reidlai opened this issue Jan 15, 2020 · 1 comment · Fixed by #1717
Closed

encounter panic when turning on AutoKubernetesLabels #1524

reidlai opened this issue Jan 15, 2020 · 1 comment · Fixed by #1717
Labels
help wanted We would love help on these issues. Please come help us! keepalive An issue or PR that will be kept alive and never marked as stale. type/bug Somehing is not working as expected

Comments

@reidlai
Copy link

reidlai commented Jan 15, 2020

Describe the bug
When turning on AutoKubernetesLabels, fluent-bit log returns panic as follow

Expected behavior
Successfully see all logs in Loki

Environment:

  • Infrastructure: minikube v1.6.2
  • Deployment tool: kustomize

Screenshots, Promtail config, or terminal output

kubectl logs output

[2020/01/15 08:28:55] [ info] [filter_kube] https=1 host=kubernetes.default.svc port=443
[2020/01/15 08:28:55] [ info] [filter_kube] local POD info OK
[2020/01/15 08:28:55] [ info] [filter_kube] testing connectivity with API server...
[2020/01/15 08:28:55] [ info] [filter_kube] API server connectivity OK
[2020/01/15 08:28:55] [ info] [sp] stream processor started
panic: interface conversion: interface {} is map[string]interface {}, not map[interface {}]interface {}

fluent-bit.conf:

[SERVICE]
    Flush        1
    Daemon       Off
    Log_Level    info
    Parsers_File parsers.conf

[INPUT]
  Name tail
  Path /var/log/containers/*.log
  Parser docker
  Tag kube.*
  Refresh_Interval 5
  Mem_Buf_Limit 5MB
  Skip_Long_Lines On
  DB /run/fluent-bit/flb_kube.db

[INPUT]
  Name systemd
  Tag host.*
  Systemd_Filter _SYSTEMD_UNIT=docker.service
  Systemd_Filter _SYSTEMD_UNIT=kubelet.service
  Systemd_Filter _SYSTEMD_UNIT=node-problem-detector.service
  Max_Entries 1000
  Read_From_Tail true
  Strip_Underscores false

[FILTER]
  Name kubernetes
  Match kube.*
  Kube_Tag_Prefix kube.var.log.containers.
  Kube_URL https://kubernetes.default.svc:443
  Kube_CA_File /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
  Kube_Token_File /var/run/secrets/kubernetes.io/serviceaccount/token
  Merge_Log On
  K8S-Logging.Parser Off

[OUTPUT]
  Name loki
  Match kube.*
  Url http://loki.gohub-gohub.svc:3100/api/prom/push
  # Labels {job="fluent-bit"}
  # RemoveKeys kubernetes,stream
  AutoKubernetesLabels true
  # LabelMapPath /fluent-bit/etc/labelmap.json
  # LineFormat json
  # LogLevel warn

parsers.conf:

[PARSER]
  Name         docker
  Format       json
  Time_Key     time
  Time_Format  %Y-%m-%dT%H:%M:%S.%L
@stale
Copy link

stale bot commented Feb 14, 2020

This issue has been automatically marked as stale because it has not had any activity in the past 30 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale A stale issue or PR that will automatically be closed. label Feb 14, 2020
@cyriltovena cyriltovena added help wanted We would love help on these issues. Please come help us! keepalive An issue or PR that will be kept alive and never marked as stale. kind/bug labels Feb 17, 2020
@stale stale bot removed the stale A stale issue or PR that will automatically be closed. label Feb 17, 2020
@chaudum chaudum added the type/bug Somehing is not working as expected label Jun 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted We would love help on these issues. Please come help us! keepalive An issue or PR that will be kept alive and never marked as stale. type/bug Somehing is not working as expected
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants