Otel collector deployment with multiple pods result in duplicate metrics #9998
              
                Unanswered
              
          
                  
                    
                      mircea-lemnaru-aera
                    
                  
                
                  asked this question in
                Q&A
              
            Replies: 1 comment 1 reply
-
| Hey @mircea-lemnaru-aera , Did you solved the issue, I am also facing the same issue, | 
Beta Was this translation helpful? Give feedback.
                  
                    1 reply
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
Hi All,
I have this current setup:
Otel operator which deploys the Otel Collector as a K8s Deployment with 2 pods in my case.
In the same namespace I have a bunch of services configured with auto-instrumentation which push telemetry data to the
otel collectorservice.In the same namespace I have a PodMonitor which is used by Prometheus to discover the Otel Pods and scrape from them.
Both pods appear in Prometheus as targets , all seems to be good.
The problem that I am facing is that the metrics are duplicated. For the same service I have the same metric , each one comming from one otel-collector instance.
For example:
And the duplicate one , if you look closely you can see that the only difference is the collector that provided this metric
In the first one the collector is:
otel-collector-5dccb6749f-x6xkjand in the second oneotel-collector-5dccb6749f-7jhfg. And the metric value is exactly the same. It seems like this metric is pushed to both collectors for some reson and then prometheus collects them both.Am I doing something wrong with deploying 2 collector instances ? And is there a way to remove this duplication ?
What do you suggest I do ?
PS: I can remove this at prometheus or grafana level , but I fear that I am doing something wrong.
Thanks
Beta Was this translation helpful? Give feedback.
All reactions