operator icon indicating copy to clipboard operation
operator copied to clipboard

Operator is unable to create secret for vmagent when compressed config "vmagent.yaml.gz" is larger than 1MB

Open prasadrajesh opened this issue 7 months ago • 5 comments

I am using latest build of the operator (v0.46.4) and vmagent (v1.102.0). I have lots of various endpoints to scrape. So Operator is trying to create secret for config "vmagent.yaml.gz" but it is larger than 1MB and managed AKS Kubernetes won't allow to create secret larger than 1MB (Ref-https://kubernetes.io/docs/concepts/configuration/secret/#working-with-secrets)

Error Warning ReconcilationError <unknown> victoria-metrics-operator Secret "vmagent-vmagent-0" is invalid: data: Too long: must have at most 1048576 bytes

NAME        SHARDS COUNT   REPLICA COUNT   STATUS
vmagent-0                  1               failed
vmagent-1                  1               failed
vmagent-2                  1               failed

I also tried by enabling shards but no luck.

It is similar issue like https://github.com/prometheus-operator/prometheus-operator/issues/4702

I think fix will be like https://github.com/prometheus-operator/prometheus-operator/pull/4427 where operator creating shardSecret.

prasadrajesh avatar Jul 26 '24 11:07 prasadrajesh