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

add UnexpectedAdmissionError to kube_pod_status_reason metric #1145

Conversation

qw1mb0
Copy link
Contributor

@qw1mb0 qw1mb0 commented May 16, 2020

What this PR does / why we need it:
Add UnexpectedAdmissionError reason to kube_pod_status_reason metric

Which issue(s) this PR fixes:
Fixes #1114

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels May 16, 2020
@qw1mb0 qw1mb0 force-pushed the add-unexpected-admission-error-pod-reason branch from 9132a0f to bdb2e92 Compare May 16, 2020 18:19
Copy link
Member

@lilic lilic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, can you link to where this Pod Status Reason is used in upstream k8s api, haven't been able to find it that well

@tariq1890
Copy link
Contributor

@qw1mb0
Copy link
Contributor Author

qw1mb0 commented May 21, 2020

Yes, kubelet report this reason

@qw1mb0
Copy link
Contributor Author

qw1mb0 commented May 22, 2020

In the cluster, it looks like this (kubernetes 1.16):

# kubectl -n kube-system  get pod coredns-578bdc569f-g87nk -o json | jq '.status'
{
  "message": "Pod Unexpected error while attempting to recover from admission failure: preemption: error finding a set of pods to preempt: no set of running pods found to reclaim resources: [(res: pods, q: 1), ]",
  "phase": "Failed",
  "reason": "UnexpectedAdmissionError",
  "startTime": "2020-04-19T19:30:12Z"
}

Copy link
Member

@lilic lilic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Thanks!

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lilic, qw1mb0

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels May 25, 2020
@k8s-ci-robot k8s-ci-robot merged commit 0bfc298 into kubernetes:master May 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Monitoring UnexpectedAdmissionError
4 participants