Bug 1835725 - DNS operator reports "No DNS resource exists" when the DNS exists but its DaemonSet is not available
Summary: DNS operator reports "No DNS resource exists" when the DNS exists but its Dae...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Networking
Version: 4.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 4.5.0
Assignee: Andrew McDermott
QA Contact: Hongan Li
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-05-14 11:53 UTC by Miciah Dashiel Butler Masters
Modified: 2022-08-04 22:39 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
When the dnses.operator.openshift.io/default object exists but its corresponding DaemonSet is not available, clusteroperators/dns reports the "Available" condition with status "False" (which is correct), reason "NoDNS" (which is wrong), and message "No DNS resource exists" (which was also wrong). Under these conditions the status will now report "Not all desired DNS DaemonSets available".
Clone Of:
Environment:
Last Closed: 2020-07-13 17:38:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-dns-operator pull 166 0 None closed Bug 1835725: computeOperatorDegradedCondition: Fix "NoDNS" check 2020-11-09 06:04:20 UTC
Red Hat Product Errata RHBA-2020:2409 0 None None None 2020-07-13 17:39:01 UTC

Description Miciah Dashiel Butler Masters 2020-05-14 11:53:32 UTC
Description of problem:

When the dnses.operator.openshift.io/default object exists but its corresponding DaemonSet is not available, clusteroperators/dns reports the "Available" condition with status "False" (which is correct), reason "NoDNS" (which is wrong), and message "No DNS resource exists" (which is also wrong).


Version-Release number of selected component (if applicable):

The erroneous logic was added in OpenShift 4.2: https://github.com/openshift/cluster-dns-operator/pull/109/commits/540ab8bca50b50880a4eb44feaddee8352f565bf


How reproducible:

Readily.


Steps to Reproduce:


1. Launch a cluster.

2. Delete the default DNS's DaemonSet:

    oc -n openshift-dns delete daemonsets/dns-default

3. Check the clusteroperator:

    oc get clusteroperators/dns -o yaml


Actual results:

The clusteroperator reports the following: "No DNS resource exists":

      - lastTransitionTime: "2020-05-14T11:52:05Z"
        message: No DNS resource exists
        reason: NoDNS
        status: "True"
        type: Degraded


Expected results:

The clusteroperator should report the following: "Not all desired DNS DaemonSets available".


Additional info:

Observed in CI: https://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/pr-logs/pull/openshift_router/113/pull-ci-openshift-router-master-e2e-aws/373

Comment 4 Hongan Li 2020-05-28 08:32:24 UTC
verified with 4.5.0-0.nightly-2020-05-27-202943 and the issue has been fixed.

status:
  conditions:
  - lastTransitionTime: "2020-05-28T08:26:34Z"
    message: Not all desired DNS DaemonSets available
    reason: NotAllDNSesAvailable
    status: "True"
    type: Degraded

Comment 5 errata-xmlrpc 2020-07-13 17:38:49 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:2409


Note You need to log in before you can comment on or make changes to this bug.