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

kubectl drain errors if a pod has already been deleted #28

Closed
derekwaynecarr opened this issue Jun 9, 2017 · 0 comments · Fixed by kubernetes/kubernetes#47270
Closed

Comments

@derekwaynecarr
Copy link
Member

Kubernetes version (use kubectl version):
kubernetes/master

What happened:
kubectl drain of a node threw an error when a pod was already deleted.

What you expected to happen:
kubectl drain should not error if the pod it attempts to delete is already deleted

How to reproduce it (as minimally and precisely as possible):
create a pod, run kubectl drain on the node, delete the pod prior to drain completing on that node.

Anything else we need to know:
nope. i have a pr prepared with a fix.

k8s-github-robot pushed a commit to kubernetes/kubernetes that referenced this issue Jun 16, 2017
Automatic merge from submit-queue (batch tested with PRs 47523, 47438, 47550, 47450, 47612)

Ignore 404s on evict

One of our upgrades failed with 
```
error: error when evicting pod \"boo-2-deploy\": pods \"boo-2-deploy\" not found"
```

@derekwaynecarr since you already fixed half of it 

cc: @kubernetes/sig-cli-bugs 

I failed terribly at adding a unit test mostly because draining involves discovery for the eviction API and the fake client stuff for discovery are far from functional - will spawn a separate issue about it.

fyi @jupierce

related: kubernetes/kubectl#28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant