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

Promtail missing short-lived pod logs #3458

Closed
nmiculinic opened this issue Mar 9, 2021 · 2 comments
Closed

Promtail missing short-lived pod logs #3458

nmiculinic opened this issue Mar 9, 2021 · 2 comments
Labels
stale A stale issue or PR that will automatically be closed.

Comments

@nmiculinic
Copy link
Contributor

Describe the bug

We have a short-lived container. It's created, it executes quite quickly (thing echo "sss"; exit 1) and when the pod phase reaches completed a controller deletes the pod.

The promtail hasn't shipped the pod's logs to the loki. It hasn't added it as a target, nor started tailing the log file before the log file was deleted (we're using docker with json-log logging driver)

To Reproduce
Steps to reproduce the behavior:

  1. Started Promtail (SHA or version) to tail '...': v2.1.0
  2. Start short-lived container

Expected behavior
Promtail tailing the short-lived container logfile and shipping it out

Environment:

  • Infrastructure: [e.g., Kubernetes, bare-metal, laptop]: k8s, EKS
  • Deployment tool: [e.g., helm, jsonnet]: helm, promtail
@stale
Copy link

stale bot commented Jun 3, 2021

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 Jun 3, 2021
@stale stale bot closed this as completed Jun 11, 2021
@ipleten
Copy link

ipleten commented Aug 31, 2021

I wonder why it was closed as it's still an issue. I assume it's due to sync time with k8s API. I wonder if it's possible to get data from logs and parse them after Pod was terminated?
Having this logs is extra helpful to investigate pod startup failures (like Jenkins JNLP agent, DNS resolution troubles etc.)
Update: see #775

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale A stale issue or PR that will automatically be closed.
Projects
None yet
Development

No branches or pull requests

2 participants