Kube-state-metrics: Failed to list validatingwebhookconfiguration ... log message

Created on 10 Mar 2020  路  5Comments  路  Source: kubernetes/kube-state-metrics

Is this a BUG REPORT or FEATURE REQUEST?:

/kind bug

What happened:
Running kube-state-metrics in the kube-system namespace of my gke cluster, getting this error every 1 second in the logs:

E0309 23:03:53.536354       1 reflector.go:156] pkg/mod/k8s.io/[email protected]/tools/cache/reflector.go:108: Failed to list *v1.ValidatingWebhookConfiguration: the server could not find the requested resource

What you expected to happen:
Expected not to see the error.
How to reproduce it (as minimally and precisely as possible):
When I run make container I create the following tags:

```docker tag quay.io/coreos/kube-state-metrics-amd64:v1.9.5 quay.io/coreos/kube-state-metrics:v1.9.5


**Anything else we need to know?**:

**Environment**:
- Kubernetes version (use `kubectl version`):

Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.3", GitCommit:"b3cbbae08ec52a7fc73d334838e18d17e8512749", GitTreeState:"clean", BuildDate:"2019-11-14T04:24:29Z", GoVersion:"go1.12.13", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"15+", GitVersion:"v1.15.8-gke.3", GitCommit:"2ccf2c797713077f4a3d0f87c4b4bae725362326", GitTreeState:"clean", BuildDate:"2020-01-29T19:27:22Z", GoVersion:"go1.12.12b4", Compiler:"gc", Platform:"linux/amd64"}
```

  • Kube-state-metrics image version
    Based on the docker build output, I believe the image is 1.9.5.

I don't necessarily think this is a bug. Likely something wrong in my configuration, but I'm not sure how to fix.

kinbug

Most helpful comment

Hi @dopey, it seems to be the same issue as #1090.
kube-state-metrics 1.9.5 fully supports Kubernetes 1.16 only (the compatibility matrix will be updated with PR #1092).

Using 1.8.x version of kube-state-metrics would probably works for you (K8s 1.15), right?

All 5 comments

Hi @dopey, it seems to be the same issue as #1090.
kube-state-metrics 1.9.5 fully supports Kubernetes 1.16 only (the compatibility matrix will be updated with PR #1092).

Using 1.8.x version of kube-state-metrics would probably works for you (K8s 1.15), right?

Hey @olivierlemasle , thanks for the quick reply. Looks like switching to 1.8.0 gets rid of the errors. Thanks!

Thanks @olivierlemasle!

I'm getting this error:
pkg/mod/k8s.io/[email protected]/tools/cache/reflector.go:108: expected type *v1.MutatingWebhookConfiguration, but watch event object had type *v1beta1.MutatingWebhookConfiguration

And my Kubernetes version:

Client Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.4", GitCommit:"c96aede7b5205121079932896c4ad89bb93260af", GitTreeState:"clean", BuildDate:"2020-06-18T02:59:13Z", GoVersion:"go1.14.3", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.3", GitCommit:"2e7996e3e2712684bc73f0dec0200d64eec7fe40", GitTreeState:"clean", BuildDate:"2020-05-20T12:43:34Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"linux/amd64"}

And running latest stable kube-state-metrics version (1.9.7)

Just ran into this same issue. My Kube version (EKS) is 1.16.0 and tried 1.9.5 - 1.9.7 images of Kube state metrics. Kept running into the same issue until l switched to 1.9.4 image which worked as expected. I guess the compatibility matrix still needs to be updated?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lilic picture lilic  路  3Comments

stevebail picture stevebail  路  8Comments

roobre picture roobre  路  7Comments

mrueg picture mrueg  路  3Comments

jackzampolin picture jackzampolin  路  8Comments