kubernetes-sigs / external-dns

Configure external DNS servers (AWS Route53, Google CloudDNS and others) for Kubernetes Ingresses and Services
Apache License 2.0
7.56k stars 2.54k forks source link

AWS Provider - external_dns_controller_verified_a_records, external_dns_registry_a_records, external_dns_source_a_records and external_dns_controller_no_op_runs_total metrics showing 0 #4101

Closed sossickd closed 2 months ago

sossickd commented 9 months ago

What happened:

AWS Provider metrics showing 0 -

external_dns_controller_verified_a_records external_dns_registry_a_records external_dns_source_a_records external_dns_controller_no_op_runs_total

# TYPE external_dns_controller_no_op_runs_total counter
external_dns_controller_no_op_runs_total 0
# HELP external_dns_controller_verified_a_records Number of DNS A-records that exists both in source and registry.
# TYPE external_dns_controller_verified_a_records gauge
external_dns_controller_verified_a_records 0
# HELP external_dns_registry_a_records Number of Registry A records.
# TYPE external_dns_registry_a_records gauge
external_dns_registry_a_records 0
# HELP external_dns_registry_endpoints_total Number of Endpoints in the registry
# TYPE external_dns_registry_endpoints_total gauge
external_dns_registry_endpoints_total 50
# HELP external_dns_source_a_records Number of Source A records.
# TYPE external_dns_source_a_records gauge
external_dns_source_a_records 0
# HELP external_dns_source_endpoints_total Number of Endpoints in all sources
# TYPE external_dns_source_endpoints_total gauge
external_dns_source_endpoints_total 6

What you expected to happen: external_dns_controller_verified_a_records should equal 5 (same as external_dns_source_endpoints_total) external_dns_registry_a_records should equal 50 (same as external_dns_registry_endpoints_total) external_dns_source_a_records should equal 5 (same as external_dns_source_endpoints_total) external_dns_controller_no_op_runs_total should increment on every no-op run

All these metrics behave as expected when using the Azure Provider on AKS with the same external-dns helm chart version.

How to reproduce it (as minimally and precisely as possible):

Helm Values.yaml:

USER-SUPPLIED VALUES:
domainFilters:
- <REDACTED>
extraArgs:
- --aws-api-retries=3
- --aws-batch-change-size=1000
- --aws-zone-type=private
- --annotation-filter=lnrs.io/zone-type in (private, public-private)
logFormat: json
logLevel: info
nameOverride: external-dns-private
policy: sync
priorityClassName: ""
provider: aws
resources:
  limits:
    cpu: 1000m
    memory: 128Mi
  requests:
    cpu: 10m
    memory: 128Mi
serviceAccount:
  annotations:
    eks.amazonaws.com/role-arn: <REDACTED>
  create: true
  name: external-dns-private
serviceMonitor:
  additionalLabels:
    lnrs.io/monitoring-platform: "true"
  enabled: true
sources:
- service
- ingress
tolerations:
- key: system
  operator: Exists
txtOwnerId: iob-eks-1

Install:

helm upgrade --install --values=values.yaml external-dns-private external-dns/external-dns --namespace dns --version 1.13.1

Anything else we need to know?:

Environment:

asmi10 commented 7 months ago

I am also facing the similar issue with external-dns-1.13.1. external_dns_controller_verified_a_records, external_dns_source_a_records and external_dns_registry_a_records all a_records metrics sre showing 0, but endpoint metric is showing correctly.

asmi10 commented 7 months ago

I got the issue. Here - https://github.com/kubernetes-sigs/external-dns/blob/a86fa4173e4e206a5942fe126db6c598cf1d721a/controller/controller.go#L206 it is checking the total endpoints from registry, which is showing correctly in metrics. and then here- https://github.com/kubernetes-sigs/external-dns/blob/a86fa4173e4e206a5942fe126db6c598cf1d721a/controller/controller.go#L214 it is calculating the A records which only list the record type A - pointing to IP, not other records.

k8s-triage-robot commented 4 months ago

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot commented 3 months ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot commented 2 months ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

k8s-ci-robot commented 2 months ago

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to [this](https://github.com/kubernetes-sigs/external-dns/issues/4101#issuecomment-2184764968): >The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. > >This bot triages issues according to the following rules: >- After 90d of inactivity, `lifecycle/stale` is applied >- After 30d of inactivity since `lifecycle/stale` was applied, `lifecycle/rotten` is applied >- After 30d of inactivity since `lifecycle/rotten` was applied, the issue is closed > >You can: >- Reopen this issue with `/reopen` >- Mark this issue as fresh with `/remove-lifecycle rotten` >- Offer to help out with [Issue Triage][1] > >Please send feedback to sig-contributor-experience at [kubernetes/community](https://github.com/kubernetes/community). > >/close not-planned > >[1]: https://www.kubernetes.dev/docs/guide/issue-triage/ Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.