<p>I'm trying to set some alarms based on replica set metrics but Prometheus cannot find <a href="https://github.com/kubernetes/kube-state-metrics/blob/master/docs/replicaset-metrics.md" rel="nofollow noreferrer">replicaset kube state metrics</a> while browsing expressions. What would be the problem with that? On Prometheus dashboard, I can see lots of metrics, which is in kube state metrics repo, but replica sets. Any ideas?</p>
<p>Kube state metrics  version: v1.9.7</p>
<p>Update:</p>
<p>For example, I can see most of <a href="https://github.com/kubernetes/kube-state-metrics/blob/master/docs/deployment-metrics.md" rel="nofollow noreferrer">deployment metrics</a> on the dashboard, but no metrics for replica sets.</p>
<p><a href="https://i.stack.imgur.com/W2GXB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/W2GXB.png" alt="enter image description here" /></a></p>

<p>This is a community wiki answer posted for better clarity. Feel free to expand it.</p>
<p>As @ cosmos-1905-14 described, he checked the kube-state-metric logs and found that the ServiceAccount did not have sufficient rights to access the ReplicaSets. After he added the necessary rights, the issue was resolved.</p>
