Skip to content

corefile: switch deprecated proxy plugin to forward plugin - #123

Merged
openshift-merge-robot merged 1 commit into
openshift:masterfrom
ironcladlou:forward-plugin
Jul 8, 2019
Merged

openshift-merge-robot merged 1 commit into
openshift:masterfrom
ironcladlou:forward-plugin

Conversation

@ironcladlou

@ironcladlou ironcladlou commented Jul 8, 2019 •

Copy link
Copy Markdown
Contributor

Switch the deprecated[1] proxy plugin to the forward plugin. The current
configuration used by the operator is drop-in compatible with the forward
plugin, and so this change should be completely transparent.

To support rolling out the Corefile change, add support for diffing and applying
changes to the Corefile configmap.

[1] coredns/coredns#2744

Should unblock openshift/coredns#15 (which removes the proxy plugin from CoreDNS).

/cc @celebdor

Switch the deprecated[1] `proxy` plugin to the `forward` plugin. The current
configuration used by the operator is drop-in compatible with the `forward`
plugin, and so this change should be completely transparent.

To support rolling out the Corefile change, add support for diffing and applying
changes to the Corefile configmap.

[1] coredns/coredns#2744
@openshift-ci-robot openshift-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jul 8, 2019
@ironcladlou

Copy link
Copy Markdown
Contributor Author

There may be an issue here with the daemonset image being updated before the configmap and th configmap change not coercing a rollout.

@ironcladlou

Copy link
Copy Markdown
Contributor Author

If the configmap changes at any time, should we coerce a rollout? Otherwise it becomes very unpredictable when the changes will be picked up (when CoreDNS pods happen to restart later on for various reasons).

@ironcladlou

Copy link
Copy Markdown
Contributor Author

@Miciah pointed out we're already using the reload plugin, so a change to the mounted contents should cause CoreDNS to restart internally. I'll test to make sure.

@ironcladlou

Copy link
Copy Markdown
Contributor Author

/retest

@ironcladlou

Copy link
Copy Markdown
Contributor Author

Confirmed that mutating the Corefile configmap causes a reload:

$ oc logs -f -n openshift-dns pods/dns-default-5nnrf -c dns
2019-07-08T17:33:24.947Z [INFO] CoreDNS-1.3.1
2019-07-08T17:33:24.947Z [INFO] linux/amd64, go1.10.3,CoreDNS-1.3.1linux/amd64, go1.10.3,
2019-07-08T17:33:24.947Z [INFO] plugin/reload: Running configuration MD5 = 6dfacbfa08660b953611ad25ea5c84fc
[INFO] Reloading
2019-07-08T17:48:20.695Z [INFO] plugin/reload: Running configuration MD5 = d9f1b0da2003417fa038d3bb0a8ccef4
[INFO] Reloading complete

}

func corefileChanged(current, expected *corev1.ConfigMap) (bool, *corev1.ConfigMap) {
if cmp.Equal(current.Data, expected.Data, cmpopts.EquateEmpty()) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This is fine, but out of curiosity, is there a reason not to use reflect.DeepEqual here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I want to say it was actually you who started proliferating the use of go-cmp into the operators 😁 — for the most part I try to just use it by default now for consistency and flexibility

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Ravi introduced the first use of go-cmp, and mostly we use it where reflect.DeepEqual is not flexible enough, but yeah, we're now using go-cmp more than reflect.DeepEqual, so it is reasonable to choose go-cmp over reflect.DeepEqual by default.

@Miciah

Miciah commented Jul 8, 2019

Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jul 8, 2019
@openshift-merge-robot
openshift-merge-robot merged commit 0f0f78a into openshift:master Jul 8, 2019
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: celebdor, ironcladlou, Miciah

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

The pull request process is described here

Details 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

wking added a commit to wking/cluster-dns-operator that referenced this pull request Oct 18, 2019
Using the Infof and 'old: %#v, new: %#v' precedents set by 8338eb5
(corefile: switch deprecated proxy plugin to forward plugin,
2019-07-08, openshift#123).  This will hopefully shed light on cases like [1]:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/build-log.txt | grep 'clusteroperator/dns changed Degraded'
  Oct 18 02:36:11.767 E clusteroperator/dns changed Degraded to True: NotAllDNSesAvailable: Not all desired DNS DaemonSets available
  Oct 18 02:36:17.197 W clusteroperator/dns changed Degraded to False: AsExpected: All desired DNS DaemonSets available and operand Namespace exists

Where the current logs are not very informative:

  $ curl https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocphttps://prow.svc.ci.openshift.org/vhttps://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94iew/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns-operator/pods/dns-operator-ccdb4b5f9-2qrz9/dns-operator/dns-operator/logs/current.log
  ...
  2019-10-18T02:35:25.3133104Z time="2019-10-18T02:35:25Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.641432392Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.767310473Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.108292034Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.196969585Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.018249079Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.092325372Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.377673018Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.489970054Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.32660449Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.411167811Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  ...

And while the event logs show some activity:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns/core/events.yaml |
  >   yaml2json |
  >   jq -r '
  >     [
  >       .items[] |
  >       .timePrefix = if .firstTimestamp == null or .firstTimestamp == "null"
  >         then
  >           .eventTime
  >         else
  >           .firstTimestamp + " - " + .lastTimestamp + " (" + (.count | tostring) + ")"
  >         end
  >     ] |
  >     sort_by(.timePrefix)[] |
  >     .timePrefix + " " + .metadata.namespace + " " + .message'
  ...
  2019-10-18T01:12:48Z - 2019-10-18T01:12:48Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:35:25.185779Z openshift-dns Successfully assigned openshift-dns/dns-default-bhkr7 to ip-10-0-147-35.ec2.internal
  2019-10-18T02:35:25Z - 2019-10-18T02:35:25Z (1) openshift-dns Created pod: dns-default-bhkr7
  2019-10-18T02:35:25Z - 2019-10-18T02:35:52Z (15) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:01Z - 2019-10-18T02:36:01Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Created container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Started container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Created container dns-node-resolver
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:36:11.619641Z openshift-dns Successfully assigned openshift-dns/dns-default-zlml2 to ip-10-0-132-20.ec2.internal
  2019-10-18T02:36:11Z - 2019-10-18T02:36:11Z (1) openshift-dns Created pod: dns-default-zlml2
  2019-10-18T02:36:11Z - 2019-10-18T02:36:38Z (14) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:48Z - 2019-10-18T02:36:48Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  ...

it is not obvious to me how that activity is leading to the
degradation.

We'd have a better UX if we bubbled the underlying DNS degradation
message(s) into the operator's degradation message, but that's a
bigger refactor than I have time for now.  When we get that, we can
roll this commit back, and get the details from the
Degraded-status-change events.  Once we start firing events; the
current "clusteroperator/dns changed Degraded" are from the test
suite's openshift/origin@9bc285f7f7 (Display status about cluster
operator in the monitor, 2019-02-15, openshift/origin#22062), and the
DNS operator does not use library-go's status controller and its
openshift/library-go@41805e145b (emit specific events for version
changes, 2019-04-24, openshift/library-go#367).

[1]: https://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94
wking added a commit to wking/cluster-dns-operator that referenced this pull request Oct 18, 2019
Using the Infof and 'old: %#v, new: %#v' precedents set by 8338eb5
(corefile: switch deprecated proxy plugin to forward plugin,
2019-07-08, openshift#123).  We don't need to log the namespace, because DNS
objects are cluster-scoped.

This will hopefully shed light on cases like [1]:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/build-log.txt | grep 'clusteroperator/dns changed Degraded'
  Oct 18 02:36:11.767 E clusteroperator/dns changed Degraded to True: NotAllDNSesAvailable: Not all desired DNS DaemonSets available
  Oct 18 02:36:17.197 W clusteroperator/dns changed Degraded to False: AsExpected: All desired DNS DaemonSets available and operand Namespace exists

Where the current logs are not very informative:

  $ curl https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocphttps://prow.svc.ci.openshift.org/vhttps://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94iew/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns-operator/pods/dns-operator-ccdb4b5f9-2qrz9/dns-operator/dns-operator/logs/current.log
  ...
  2019-10-18T02:35:25.3133104Z time="2019-10-18T02:35:25Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.641432392Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.767310473Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.108292034Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.196969585Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.018249079Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.092325372Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.377673018Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.489970054Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.32660449Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.411167811Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  ...

And while the event logs show some activity:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns/core/events.yaml |
  >   yaml2json |
  >   jq -r '
  >     [
  >       .items[] |
  >       .timePrefix = if .firstTimestamp == null or .firstTimestamp == "null"
  >         then
  >           .eventTime
  >         else
  >           .firstTimestamp + " - " + .lastTimestamp + " (" + (.count | tostring) + ")"
  >         end
  >     ] |
  >     sort_by(.timePrefix)[] |
  >     .timePrefix + " " + .metadata.namespace + " " + .message'
  ...
  2019-10-18T01:12:48Z - 2019-10-18T01:12:48Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:35:25.185779Z openshift-dns Successfully assigned openshift-dns/dns-default-bhkr7 to ip-10-0-147-35.ec2.internal
  2019-10-18T02:35:25Z - 2019-10-18T02:35:25Z (1) openshift-dns Created pod: dns-default-bhkr7
  2019-10-18T02:35:25Z - 2019-10-18T02:35:52Z (15) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:01Z - 2019-10-18T02:36:01Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Created container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Started container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Created container dns-node-resolver
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:36:11.619641Z openshift-dns Successfully assigned openshift-dns/dns-default-zlml2 to ip-10-0-132-20.ec2.internal
  2019-10-18T02:36:11Z - 2019-10-18T02:36:11Z (1) openshift-dns Created pod: dns-default-zlml2
  2019-10-18T02:36:11Z - 2019-10-18T02:36:38Z (14) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:48Z - 2019-10-18T02:36:48Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  ...

it is not obvious to me how that activity is leading to the
degradation.

We'd have a better UX if we bubbled the underlying DNS degradation
message(s) into the operator's degradation message, but that's a
bigger refactor than I have time for now.  When we get that, we can
roll this commit back, and get the details from the
Degraded-status-change events.  Once we start firing events; the
current "clusteroperator/dns changed Degraded" are from the test
suite's openshift/origin@9bc285f7f7 (Display status about cluster
operator in the monitor, 2019-02-15, openshift/origin#22062), and the
DNS operator does not use library-go's status controller and its
openshift/library-go@41805e145b (emit specific events for version
changes, 2019-04-24, openshift/library-go#367).

[1]: https://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94
wking added a commit to wking/cluster-dns-operator that referenced this pull request Oct 18, 2019
Using the Infof and 'old: %#v, new: %#v' precedents set by 8338eb5
(corefile: switch deprecated proxy plugin to forward plugin,
2019-07-08, openshift#123).  We don't need to log the namespace, because DNS
objects are cluster-scoped.

This will hopefully shed light on cases like [1]:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/build-log.txt | grep 'clusteroperator/dns changed Degraded'
  Oct 18 02:36:11.767 E clusteroperator/dns changed Degraded to True: NotAllDNSesAvailable: Not all desired DNS DaemonSets available
  Oct 18 02:36:17.197 W clusteroperator/dns changed Degraded to False: AsExpected: All desired DNS DaemonSets available and operand Namespace exists

Where the current logs are not very informative:

  $ curl https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocphttps://prow.svc.ci.openshift.org/vhttps://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94iew/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns-operator/pods/dns-operator-ccdb4b5f9-2qrz9/dns-operator/dns-operator/logs/current.log
  ...
  2019-10-18T02:35:25.3133104Z time="2019-10-18T02:35:25Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.641432392Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:11.767310473Z time="2019-10-18T02:36:11Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.108292034Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:17.196969585Z time="2019-10-18T02:36:17Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.018249079Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:48.092325372Z time="2019-10-18T02:36:48Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.377673018Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:36:55.489970054Z time="2019-10-18T02:36:55Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.32660449Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  2019-10-18T02:37:05.411167811Z time="2019-10-18T02:37:05Z" level=info msg="reconciling request: /default"
  ...

And while the event logs show some activity:

  $ curl -s https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94/artifacts/e2e-aws-serial/must-gather/quay-io-openshift-release-dev-ocp-v4-0-art-dev-sha256-d9c0004f08d06ea4901dd6efd6bdac47e5f8f6c599b1674d0094f5d66c0bffc1/namespaces/openshift-dns/core/events.yaml |
  >   yaml2json |
  >   jq -r '
  >     [
  >       .items[] |
  >       .timePrefix = if .firstTimestamp == null or .firstTimestamp == "null"
  >         then
  >           .eventTime
  >         else
  >           .firstTimestamp + " - " + .lastTimestamp + " (" + (.count | tostring) + ")"
  >         end
  >     ] |
  >     sort_by(.timePrefix)[] |
  >     .timePrefix + " " + .metadata.namespace + " " + .message'
  ...
  2019-10-18T01:12:48Z - 2019-10-18T01:12:48Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:35:25.185779Z openshift-dns Successfully assigned openshift-dns/dns-default-bhkr7 to ip-10-0-147-35.ec2.internal
  2019-10-18T02:35:25Z - 2019-10-18T02:35:25Z (1) openshift-dns Created pod: dns-default-bhkr7
  2019-10-18T02:35:25Z - 2019-10-18T02:35:52Z (15) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:01Z - 2019-10-18T02:36:01Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Created container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Started container dns
  2019-10-18T02:36:05Z - 2019-10-18T02:36:05Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Successfully pulled image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:fb1317080c09aa30e85b70b3f5ec4b87408992b0a22137beef59276fcfeccf1f"
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Created container dns-node-resolver
  2019-10-18T02:36:09Z - 2019-10-18T02:36:09Z (1) openshift-dns Started container dns-node-resolver
  2019-10-18T02:36:11.619641Z openshift-dns Successfully assigned openshift-dns/dns-default-zlml2 to ip-10-0-132-20.ec2.internal
  2019-10-18T02:36:11Z - 2019-10-18T02:36:11Z (1) openshift-dns Created pod: dns-default-zlml2
  2019-10-18T02:36:11Z - 2019-10-18T02:36:38Z (14) openshift-dns network is not ready: runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: Missing CNI default network
  2019-10-18T02:36:48Z - 2019-10-18T02:36:48Z (1) openshift-dns Pulling image "quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:a82c1464f81a54536bfe2f48f5f4abb5a0f9734a7915ff1cc0f9abe24ace1f1b"
  ...

it is not obvious to me how that activity is leading to the
degradation.

We'd have a better UX if we bubbled the underlying DNS degradation
message(s) into the operator's degradation message, but that's a
bigger refactor than I have time for now.  When we get that, we can
roll this commit back, and get the details from the
Degraded-status-change events.  Once we start firing events; the
current "clusteroperator/dns changed Degraded" are from the test
suite's openshift/origin@9bc285f7f7 (Display status about cluster
operator in the monitor, 2019-02-15, openshift/origin#22062), and the
DNS operator does not use library-go's status controller and its
openshift/library-go@41805e145b (emit specific events for version
changes, 2019-04-24, openshift/library-go#367).

[1]: https://prow.svc.ci.openshift.org/view/gcs/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-serial-4.3/94
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. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants