Bug 1623352
| Summary: | Orphan propagationPolicy work as Background propagationPolicy for daemonset | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | weiwei jiang <wjiang> |
| Component: | oc | Assignee: | Maciej Szulik <maszulik> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Xingxing Xia <xxia> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 3.11.0 | CC: | aos-bugs, jokerman, mmccomas, tnozicka |
| Target Milestone: | --- | ||
| Target Release: | 3.11.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: |
Cause:
oc delete was not looking at propagation policy when removing Daemon Set.
Consequence:
Deleting DaemonSet with propagation policy set to orphan resulted in Pods being also removed.
Fix:
Consider the value of propagation policy set during DaemonSet removal.
Result:
Pods are not cleaned when propagation policy is set to orphan, when deleting DaemonSet.
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-12-21 15:23:17 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
I have traced it to: https://github.com/kubernetes/kubernetes/pull/64847/files#diff-7c126b9106a83157d89a336103eb3dbbR314 we just likely need another hack, if cascade=false, to avoid calling this hack :) Commit pushed to master at https://github.com/openshift/origin https://github.com/openshift/origin/commit/5686cdc2f4224838295f49e7cc7361c5f3b00052 Merge pull request #20793 from soltysh/bug1623352 UPSTREAM: 68007: Orphan DaemonSet when deleting with --cascade option set Waitting new puddle to have a try. Checked with # oc version oc v3.11.0-0.28.0 kubernetes v1.11.0+d4cacc0 features: Basic-Auth GSSAPI Kerberos SPNEGO Server https://ip-172-18-7-85.ec2.internal:8443 openshift v3.11.0-0.28.0 kubernetes v1.11.0+d4cacc0 And this issue has been fixed. Closing bugs that were verified and targeted for GA but for some reason were not picked up by errata. This bug fix should be present in current 3.11 release content. |
Description of problem: When I try to delete daemonset with `--cascade=false`, the request payload is Orphan propagationPolicy I0829 02:25:52.851509 56380 request.go:897] Request Body: {"propagationPolicy":"Orphan"} I0829 02:25:52.851558 56380 round_trippers.go:383] DELETE https://qe-wjiang-master-etcd-1:8443/apis/extensions/v1beta1/namespaces/default/daemonsets/hello-daemonset But all pods with ownerReference to this daemonset will be cleaned. Version-Release number of selected component (if applicable): # oc version oc v3.11.0-0.24.0 kubernetes v1.11.0+d4cacc0 features: Basic-Auth GSSAPI Kerberos SPNEGO Server https://qe-wjiang-master-etcd-1:8443 openshift v3.11.0-0.24.0 kubernetes v1.11.0+d4cacc0 How reproducible: Always Steps to Reproduce: 1. Create a daemonset oc create -f https://raw.githubusercontent.com/openshift-qe/v3-testfiles/master/daemon/daemonset.yaml 2. Wait the daemonset ready, and delete the daemonset with `--cascade=false` 3. Check if the pods will be deleted Actual results: 3. All pods will be cleaned Expected results: 3. All pods should not be deleted. Additional info: