(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[94539],{70118:function(e,s,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/integrations/infrastructure-metrics/telegraf/telegraf-rabbitmq",function(){return n(60619)}])},60619:function(e,s,n){"use strict";n.r(s),n.d(s,{__toc:function(){return a}});var i=n(85893),t=n(31379),r=n(9575);let a=[{depth:3,value:"Install Integration",id:"install-integration"},{depth:3,value:"Install Telegraf",id:"install-telegraf"},{depth:3,value:"Configure the Telegraf input plugin",id:"configure-the-telegraf-input-plugin"},{depth:3,value:"Configure the output plugin",id:"configure-the-output-plugin"},{depth:3,value:"Start Telegraf",id:"start-telegraf"},{depth:3,value:"View your metrics",id:"view-your-metrics"},{depth:3,value:"How to diagnose no data in Stack",id:"how-to-diagnose-no-data-in-stack"},{depth:3,value:"Telegraf RabbitMQ metrics Overview",id:"telegraf-rabbitmq-metrics-overview"}];function l(e){let s=Object.assign({p:"p",h3:"h3",code:"code",pre:"pre",span:"span",a:"a"},(0,r.a)(),e.components),{Steps:n,InstallIntegration:t,InstallTelegraf:a,Callout:l,TelegrafOutputPlugin:c,StartTelegraf:h,LaunchStack:d,DiagnoseNoData:m,IntercomButton:p}=s;return l||o("Callout",!0),m||o("DiagnoseNoData",!0),t||o("InstallIntegration",!0),a||o("InstallTelegraf",!0),p||o("IntercomButton",!0),d||o("LaunchStack",!0),h||o("StartTelegraf",!0),n||o("Steps",!0),c||o("TelegrafOutputPlugin",!0),(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(s.p,{children:"Configure Telegraf to ship RabbitMQ metrics to your Logit.io stacks via Logstash."}),"\n",(0,i.jsxs)(n,{children:[(0,i.jsx)(s.h3,{id:"install-integration",children:"Install Integration"}),(0,i.jsx)(t,{}),(0,i.jsx)(s.h3,{id:"install-telegraf",children:"Install Telegraf"}),(0,i.jsx)(a,{}),(0,i.jsx)(s.h3,{id:"configure-the-telegraf-input-plugin",children:"Configure the Telegraf input plugin"}),(0,i.jsxs)(s.p,{children:["The configuration file below is pre-configured to scrape the system metrics from your hosts, add the following code to the configuration file ",(0,i.jsx)(s.code,{children:"/etc/telegraf/telegraf.conf"})," from the previous step."]}),(0,i.jsx)(s.pre,{"data-language":"yaml","data-theme":"default",hasCopyCode:!0,children:(0,i.jsxs)(s.code,{"data-language":"yaml","data-theme":"default",children:[(0,i.jsx)(s.span,{className:"line",children:(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# Reads metrics from RabbitMQ servers via the Management Plugin"})}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"[["}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-string)"},children:"inputs.rabbitmq"}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"]]"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Management Plugin url. (default: http://localhost:15672)"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# url = "http://localhost:15672"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Tag added to rabbitmq_overview series; deprecated: use tags"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# name = "rmq-server-1"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Credentials"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# username = "guest"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# password = "guest"'})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Optional TLS Config"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# tls_ca = "/etc/telegraf/ca.pem"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# tls_cert = "/etc/telegraf/cert.pem"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# tls_key = "/etc/telegraf/key.pem"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Use TLS but skip chain & host verification"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# insecure_skip_verify = false"})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Optional request timeouts"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"##"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## ResponseHeaderTimeout, if non-zero, specifies the amount of time to wait"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## for a server's response headers after fully writing the request."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# header_timeout = "3s"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"##"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## client_timeout specifies a time limit for requests made by this client."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Includes connection time, any redirects, and reading the response body."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# client_timeout = "4s"'})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## A list of nodes to gather as the rabbitmq_node measurement. If not"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## specified, metrics for all nodes are gathered."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# nodes = ["rabbit@node1", "rabbit@node2"]'})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## A list of queues to gather as the rabbitmq_queue measurement. If not"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## specified, metrics for all queues are gathered."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Deprecated in 1.6: Use queue_name_include instead."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# queues = ["telegraf"]'})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## A list of exchanges to gather as the rabbitmq_exchange measurement. If not"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## specified, metrics for all exchanges are gathered."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'# exchanges = ["telegraf"]'})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Metrics to include and exclude. Globs accepted."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Note that an empty array for both will include all metrics"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'## Currently the following metrics are supported: "exchange", "federation", "node", "overview", "queue"'})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# metric_include = []"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# metric_exclude = []"})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Queues to include and exclude. Globs accepted."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Note that an empty array for both will include all queues"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# queue_name_include = []"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# queue_name_exclude = []"})]}),"\n",(0,i.jsx)(s.span,{className:"line",children:" "}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## Federation upstreams to include and exclude specified as an array of glob"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## pattern strings.  Federation links can also be limited by the queue and"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"## exchange filters."})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# federation_upstream_include = []"})]}),"\n",(0,i.jsxs)(s.span,{className:"line",children:[(0,i.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"  "}),(0,i.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"# federation_upstream_exclude = []"})]})]})}),(0,i.jsx)(l,{type:"info",children:(0,i.jsxs)(s.p,{children:["Read more about how to configure data scraping and configuration options for ",(0,i.jsx)(s.a,{href:"https://github.com/influxdata/telegraf/tree/master/plugins/inputs/rabbitmq",children:"RabbitMQ"})]})}),(0,i.jsx)(s.h3,{id:"configure-the-output-plugin",children:"Configure the output plugin"}),(0,i.jsx)(c,{}),(0,i.jsx)(s.h3,{id:"start-telegraf",children:"Start Telegraf"}),(0,i.jsx)(h,{}),(0,i.jsx)(s.h3,{id:"view-your-metrics",children:"View your metrics"}),(0,i.jsx)(d,{source:"RabbitMQ_Metrics_via_Telegraf",utmMedium:"metrics",utmCampaign:"telegraf-RabbitMQ-metrics"}),(0,i.jsx)(s.h3,{id:"how-to-diagnose-no-data-in-stack",children:"How to diagnose no data in Stack"}),(0,i.jsx)(m,{})]}),"\n",(0,i.jsx)(s.h3,{id:"telegraf-rabbitmq-metrics-overview",children:"Telegraf RabbitMQ metrics Overview"}),"\n",(0,i.jsx)(s.p,{children:"To effectively monitor and analyze RabbitMQ metrics in a distributed environment, organizations require a\nreliable and efficient metrics management solution. Telegraf, an open-source metrics collection agent,\nis well-equipped to gather RabbitMQ metrics from various sources, including queue lengths, message rates, and node-specific statistics."}),"\n",(0,i.jsx)(s.p,{children:"With its wide range of input plugins, Telegraf enables organizations to collect diverse RabbitMQ metrics,\nsuch as message rate, message latency, node memory usage, and more. These metrics provide valuable insights\ninto the operational health and efficiency of RabbitMQ-based messaging systems, enabling organizations to\noptimize their infrastructure and application management processes."}),"\n",(0,i.jsx)(s.p,{children:"For storing and querying the collected RabbitMQ metrics, Prometheus, a powerful open-source monitoring\nand alerting tool, is the preferred choice. Prometheus supports a flexible querying language and\ngraphical visualization capabilities, allowing organizations to gain actionable insights from RabbitMQ performance metrics."}),"\n",(0,i.jsx)(s.p,{children:"By configuring Telegraf to output RabbitMQ metrics in the Prometheus format and setting up Prometheus\nto scrape the metrics from the Telegraf server, seamless integration is achieved.\nThis process involves setting up Telegraf to collect RabbitMQ metrics, formatting them in the\nPrometheus format, and configuring Prometheus to scrape the metrics from the Telegraf server.\nLeveraging Prometheus's advanced querying and visualization features, organizations can gain\ndeep insights into RabbitMQ performance, identify potential bottlenecks, and troubleshoot issues effectively."}),"\n",(0,i.jsx)(s.p,{children:"Using Telegraf to ship RabbitMQ metrics to Prometheus provides a reliable and efficient metrics management\nsolution for distributed environments. This empowers organizations to monitor RabbitMQ performance,\noptimize their messaging systems, and make data-driven decisions to ensure optimal system health and performance."}),"\n",(0,i.jsxs)(s.p,{children:["If you need any further assistance with shipping your log data to Logit.io we're here to help you get started.\nFeel free to get in contact with our support team by sending us a message via ",(0,i.jsx)(p,{text:"live chat"}),"\n& we'll be happy to assist."]})]})}function o(e,s){throw Error("Expected "+(s?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}s.default=(0,t.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:s}=Object.assign({},(0,r.a)(),e.components);return s?(0,i.jsx)(s,{...e,children:(0,i.jsx)(l,{...e})}):l(e)},pageOpts:{filePath:"src/pages/integrations/infrastructure-metrics/telegraf/telegraf-rabbitmq.mdx",route:"/integrations/infrastructure-metrics/telegraf/telegraf-rabbitmq",frontMatter:{title:"RabbitMQ Metrics",metaTitle:"Integrate and Configure Telegraf to send RabbitMQ Metrics",subTitle:"Ship your RabbitMQ Metrics via Telegraf to your Logit.io Stack",logo:"rabbitmq",color:"#4d4d4d",description:"Use our example to configure Telegraf to ship RabbitMQ metrics to your Logit.io stacks. Configure Telegraf to send RabbitMQ metrics to Logstash or Elastic.",stackTypes:"metrics",sslPortType:"beats-ssl",tags:"Telegraf, Metrics, Telemetry, OpenTelemetry, Health, Instrumentation, RabbitMQ, Message Queue, Monitoring, Messaging, Rabbitmq"},title:"RabbitMQ Metrics",headings:a},pageNextRoute:"/integrations/infrastructure-metrics/telegraf/telegraf-rabbitmq"})}},function(e){e.O(0,[31379,92888,49774,40179],function(){return e(e.s=70118)}),_N_E=e.O()}]);