PageSourceSearch

https://netdata-docusaurus.netlify.app/assets/js/4e5f4df0.de0b42ec.js

js netdata-docusaurus.netlify.app collected 2026-10-03 11:13:54 UTC 30,799 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunklearn_v_2=self.webpackChunklearn_v_2||[]).push([["13670"],{70029(e,t,l){l.r(t),l.d(t,{metadata:()=>s,default:()=>h,frontMatter:()=>r,contentTitle:()=>d,toc:()=>a,assets:()=>c});var s=JSON.parse('{"id":"Collecting Metrics/Collectors/Databases/MaxScale","title":"MaxScale","description":"This collector monitors the activity and performance of MaxScale servers.","source":"@site/docs/Collecting Metrics/Collectors/Databases/MaxScale.mdx","sourceDirName":"Collecting Metrics/Collectors/Databases","slug":"/collecting-metrics/collectors/databases/maxscale","permalink":"/docs/collecting-metrics/collectors/databases/maxscale","draft":false,"unlisted":false,"editUrl":"https://github.com/netdata/netdata/edit/master/src/go/plugin/go.d/collector/maxscale/metadata.yaml","tags":[],"version":"current","lastUpdatedAt":1788688992000,"sidebarPosition":210,"frontMatter":{"custom_edit_url":"https://github.com/netdata/netdata/edit/master/src/go/plugin/go.d/collector/maxscale/metadata.yaml","sidebar_label":"MaxScale","learn_status":"Published","toc_max_heading_level":6,"toc_collapsible":"true","learn_rel_path":"Collecting Metrics/Collectors/Databases","keywords":["maria","mariadb","maxscale","database","db"],"description":"This collector monitors the activity and performance of MaxScale servers.","message":"DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR\'S metadata.yaml FILE","sidebar_position":210,"learn_link":"https://learn.netdata.cloud/docs/collecting-metrics/collectors/databases/maxscale","slug":"/collecting-metrics/collectors/databases/maxscale"},"sidebar":"sidebar","previous":{"title":"MariaDB","permalink":"/docs/collecting-metrics/collectors/databases/mariadb"},"next":{"title":"Meilisearch","permalink":"/docs/collecting-metrics/collectors/databases/meilisearch"}}'),n=l(74848),i=l(28453);let r={custom_edit_url:"https://github.com/netdata/netdata/edit/master/src/go/plugin/go.d/collector/maxscale/metadata.yaml",sidebar_label:"MaxScale",learn_status:"Published",toc_max_heading_level:"6",toc_collapsible:"true",learn_rel_path:"Collecting Metrics/Collectors/Databases",keywords:["maria","mariadb","maxscale","database","db"],description:"This collector monitors the activity and performance of MaxScale servers.",message:"DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE",sidebar_position:"210",learn_link:"https://learn.netdata.cloud/docs/collecting-metrics/collectors/databases/maxscale",slug:"/collecting-metrics/collectors/databases/maxscale"},d="MaxScale",c={},a=[{value:"Overview",id:"overview",level:2},{value:"Default Behavior",id:"default-behavior",level:3},{value:"Auto-Detection",id:"auto-detection",level:4},{value:"Limits",id:"limits",level:4},{value:"Performance Impact",id:"performance-impact",level:4},{value:"Setup",id:"setup",level:2},{value:"Prerequisites",id:"prerequisites",level:3},{value:"Configuration",id:"configuration",level:3},{value:"Options",id:"options",level:4},{value:"via UI",id:"via-ui",level:4},{value:"via File",id:"via-file",level:4},{value:"Examples",id:"examples",level:5},{value:"Basic",id:"basic",level:6},{value:"HTTPS with self-signed certificate",id:"https-with-self-signed-certificate",level:6},{value:"Multi-instance",id:"multi-instance",level:6},{value:"Alerts",id:"alerts",level:2},{value:"Metrics",id:"metrics",level:2},{value:"Per MaxScale instance",id:"per-maxscale-instance",level:3},{value:"Per server",id:"per-server",level:3},{value:"Troubleshooting",id:"troubleshooting",level:2},{value:"Diagnostics",id:"diagnostics",level:3},{value:"Debug Mode",id:"debug-mode",level:4},{value:"Getting Logs",id:"getting-logs",level:4},{value:"System with systemd",id:"system-with-systemd",level:5},{value:"System without systemd",id:"system-without-systemd",level:5},{value:"Docker Container",id:"docker-container",level:5}];function o(e){let t={a:"a",admonition:"admonition",blockquote:"blockquote",code:"code",em:"em",h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",header:"header",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,i.R)(),...e.components},{Details:l}=t;return l||function(e,t){throw Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}("Details",!0),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(t.header,{children:(0,n.jsx)(t.h1,{id:"maxscale",children:"MaxScale"})}),"\n",(0,n.jsx)("img",{src:"https://netdata.cloud/img/maxscale.svg",width:"150",alt:"MaxScale","data-integration-logo":"true","data-logo-contrast-light":"unknown","data-logo-contrast-dark":"unknown","data-logo-contrast-confidence":"low"}),"\n",(0,n.jsx)(t.p,{children:"Plugin: go.d.plugin\nModule: maxscale"}),"\n",(0,n.jsx)("img",{src:"https://img.shields.io/badge/maintained%20by-Netdata-%2300ab44",alt:"Maintained by Netdata"}),"\n",(0,n.jsx)(t.h2,{id:"overview",children:"Overview"}),"\n",(0,n.jsx)(t.p,{children:"This collector monitors the activity and performance of MaxScale servers."}),"\n",(0,n.jsxs)(t.p,{children:["It sends HTTP requests to the MaxScale ",(0,n.jsx)(t.a,{href:"https://mariadb.com/kb/en/maxscale-24-02rest-api/",children:"REST API"}),"."]}),"\n",(0,n.jsx)(t.p,{children:"This collector is supported on all platforms."}),"\n",(0,n.jsx)(t.p,{children:"This collector supports collecting metrics from multiple instances of this integration, including remote instances."}),"\n",(0,n.jsx)(t.h3,{id:"default-behavior",children:"Default Behavior"}),"\n",(0,n.jsx)(t.h4,{id:"auto-detection",children:"Auto-Detection"}),"\n",(0,n.jsx)(t.p,{children:"The collector can automatically detect MaxScale instances running on:"}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsx)(t.li,{children:"localhost that are listening on port 8989"}),"\n",(0,n.jsx)(t.li,{children:"within Docker containers"}),"\n"]}),"\n",(0,n.jsxs)(t.blockquote,{children:["\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.strong,{children:"Note that the MaxScale REST API requires a username and password"}),".\nWhile Netdata can automatically detect MaxScale instances and create data collection jobs, these jobs will fail unless you provide the necessary credentials."]}),"\n"]}),"\n",(0,n.jsx)(t.h4,{id:"limits",children:"Limits"}),"\n",(0,n.jsx)(t.p,{children:"The default configuration for this integration does not impose any limits on data collection."}),"\n",(0,n.jsx)(t.h4,{id:"performance-impact",children:"Performance Impact"}),"\n",(0,n.jsx)(t.p,{children:"The default configuration for this integration is not expected to impose a significant performance impact on the system."}),"\n",(0,n.jsx)(t.h2,{id:"setup",children:"Setup"}),"\n",(0,n.jsxs)(t.p,{children:["You can configure the ",(0,n.jsx)(t.strong,{children:"maxscale"})," collector in two ways:"]}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{children:"Method"}),(0,n.jsx)(t.th,{children:"Best for"}),(0,n.jsx)(t.th,{children:"How to"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{children:(0,n.jsx)(t.a,{href:"#via-ui",children:(0,n.jsx)(t.strong,{children:"UI"})})}),(0,n.jsx)(t.td,{children:"Fast setup without editing files"}),(0,n.jsxs)(t.td,{children:["Go to ",(0,n.jsx)(t.strong,{children:"Nodes \u2192 Configure this node \u2192 Collectors \u2192 Jobs"}),", search for ",(0,n.jsx)(t.strong,{children:"maxscale"}),", then click ",(0,n.jsx)(t.strong,{children:"+"})," to add a job."]})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{children:(0,n.jsx)(t.a,{href:"#via-file",children:(0,n.jsx)(t.strong,{children:"File"})})}),(0,n.jsx)(t.td,{children:"If you prefer configuring via file, or need to automate deployments (e.g., with Ansible)"}),(0,n.jsxs)(t.td,{children:["Edit ",(0,n.jsx)(t.code,{children:"go.d/maxscale.conf"})," and add a job."]})]})]})]}),"\n",(0,n.jsx)(t.admonition,{type:"important",children:(0,n.jsx)(t.p,{children:"UI configuration requires paid Netdata Cloud plan."})}),"\n",(0,n.jsx)(t.h3,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,n.jsx)(t.p,{children:"No action required."}),"\n",(0,n.jsx)(t.h3,{id:"configuration",children:"Configuration"}),"\n",(0,n.jsx)(t.h4,{id:"options",children:"Options"}),"\n",(0,n.jsx)(t.p,{children:"The following options can be defined globally: update_every, autodetection_retry."}),"\n",(0,n.jsxs)(l,{open:!0,children:[(0,n.jsx)("summary",{children:"Config options"}),(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Group"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Option"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Description"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Default"}),(0,n.jsx)(t.th,{style:{textAlign:"center"},children:"Required"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"Collection"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"update_every"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Data collection interval (seconds)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"1"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"autodetection_retry"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Autodetection retry interval (seconds). Set 0 to disable."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"Target"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"url"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Target endpoint URL."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.a,{href:"http://127.0.0.1:8989",children:"http://127.0.0.1:8989"})}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"yes"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"timeout"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"HTTP request timeout (seconds)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"1"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"HTTP Auth"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"username"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Username for Basic HTTP authentication."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"admin"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"password"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Password for Basic HTTP authentication."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"mariadb"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"bearer_token_file"}),(0,n.jsxs)(t.td,{style:{textAlign:"left"},children:["Path to a file containing a bearer token (used for ",(0,n.jsx)(t.code,{children:"Authorization: Bearer"}),")."]}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"TLS"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"}
1,children:"tls_skip_verify"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Skip TLS certificate and hostname verification (insecure)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"no"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"tls_ca"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Path to CA bundle used to validate the server certificate."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"tls_cert"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Path to client TLS certificate (for mTLS)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"tls_key"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Path to client TLS private key (for mTLS)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"Proxy"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"proxy_url"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"HTTP proxy URL."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"proxy_username"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Username for proxy Basic HTTP authentication."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"proxy_password"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Password for proxy Basic HTTP authentication."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"Request"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"method"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"HTTP method to use."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"GET"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"body"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Request body (e.g., for POST/PUT)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"headers"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Additional HTTP headers (one per line as key: value)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"not_follow_redirects"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Do not follow HTTP redirects."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"no"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"force_http2"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Force HTTP/2 (including h2c over TCP)."}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"no"}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:(0,n.jsx)(t.strong,{children:"Virtual Node"})}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"vnode"}),(0,n.jsxs)(t.td,{style:{textAlign:"left"},children:["Associates this data collection job with a ",(0,n.jsx)(t.a,{href:"https://learn.netdata.cloud/docs/netdata-agent/configuration/organize-systems-metrics-and-alerts#virtual-nodes",children:"Virtual Node"}),"."]}),(0,n.jsx)(t.td,{style:{textAlign:"left"}}),(0,n.jsx)(t.td,{style:{textAlign:"center"},children:"no"})]})]})]})]}),"\n",(0,n.jsx)(t.h4,{id:"via-ui",children:"via UI"}),"\n",(0,n.jsxs)(t.p,{children:["Configure the ",(0,n.jsx)(t.strong,{children:"maxscale"})," collector from the Netdata web interface:"]}),"\n",(0,n.jsxs)(t.ol,{children:["\n",(0,n.jsxs)(t.li,{children:["Go to ",(0,n.jsx)(t.strong,{children:"Nodes"}),"."]}),"\n",(0,n.jsxs)(t.li,{children:["Select the node ",(0,n.jsx)(t.strong,{children:"where you want the maxscale data-collection job to run"})," and click the ","\u2699"," (",(0,n.jsx)(t.strong,{children:"Configure this node"}),"). That node will run the data collection."]}),"\n",(0,n.jsxs)(t.li,{children:["The ",(0,n.jsx)(t.strong,{children:"Collectors \u2192 Jobs"})," view opens by default."]}),"\n",(0,n.jsxs)(t.li,{children:["In the Search box, type ",(0,n.jsx)(t.em,{children:"maxscale"})," (or scroll the list) to locate the ",(0,n.jsx)(t.strong,{children:"maxscale"})," collector."]}),"\n",(0,n.jsxs)(t.li,{children:["Click the ",(0,n.jsx)(t.strong,{children:"+"})," next to the ",(0,n.jsx)(t.strong,{children:"maxscale"})," collector to add a new job."]}),"\n",(0,n.jsxs)(t.li,{children:["Fill in the job fields, then click ",(0,n.jsx)(t.strong,{children:"Test"})," to verify the configuration and ",(0,n.jsx)(t.strong,{children:"Submit"})," to save.","\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsxs)(t.li,{children:[(0,n.jsx)(t.strong,{children:"Test"})," runs the job with the provided settings and shows whether data can be collected."]}),"\n",(0,n.jsx)(t.li,{children:"If it fails, an error message appears with details (for example, connection refused, timeout, or command execution errors), so you can adjust and retest."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(t.h4,{id:"via-file",children:"via File"}),"\n",(0,n.jsxs)(t.p,{children:["The configuration file name for this integration is ",(0,n.jsx)(t.code,{children:"go.d/maxscale.conf"}),"."]}),"\n",(0,n.jsx)(t.p,{children:"The file format is YAML. Generally, the structure is:"}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-yaml",children:"update_every: 1\nautodetection_retry: 0\njobs:\n  - name: some_name1\n  - name: some_name2\n"})}),"\n",(0,n.jsxs)(t.p,{children:["You can edit the configuration file using the ",(0,n.jsx)(t.a,{href:"/docs/netdata-agent/configuration#edit-configuration-files",children:(0,n.jsx)(t.code,{children:"edit-config"})})," script from the\nNetdata ",(0,n.jsx)(t.a,{href:"/docs/netdata-agent/configuration#locate-your-config-directory",children:"config directory"}),"."]}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata\nsudo ./edit-config go.d/maxscale.conf\n"})}),"\n",(0,n.jsx)(t.h5,{id:"examples",children:"Examples"}),"\n",(0,n.jsx)(t.h6,{id:"basic",children:"Basic"}),"\n",(0,n.jsx)(t.p,{children:"A basic example configuration."}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-yaml",children:"jobs:\n  - name: local\n    url: http://127.0.0.1:8989\n    username: admin\n    password: mariadb\n\n"})}),"\n",(0,n.jsx)(t.h6,{id:"https-with-self-signed-certificate",children:"HTTPS with self-signed certificate"}),"\n",(0,n.jsx)(t.p,{children:"MaxScale with enabled HTTPS and self-signed certificate."}),"\n",(0,n.jsxs)(l,{open:!0,children:[(0,n.jsx)("summary",{children:"Config"}),(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-yaml",children:"jobs:\n  - name: local\n    url: http://127.0.0.1:8989\n    username: admin\n    password: mariadb\n    tls_ski
1p_verify: yes\n\n"})})]}),"\n",(0,n.jsx)(t.h6,{id:"multi-instance",children:"Multi-instance"}),"\n",(0,n.jsxs)(t.blockquote,{children:["\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.strong,{children:"Note"}),": When you define multiple jobs, their names must be unique."]}),"\n"]}),"\n",(0,n.jsx)(t.p,{children:"Collecting metrics from local and remote instances."}),"\n",(0,n.jsxs)(l,{open:!0,children:[(0,n.jsx)("summary",{children:"Config"}),(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-yaml",children:"jobs:\n  - name: local\n    url: http://127.0.0.1:8989\n    username: admin\n    password: mariadb\n\n  - name: remote\n    url: http://192.0.2.1:8989\n    username: admin\n    password: mariadb\n\n"})})]}),"\n",(0,n.jsx)(t.h2,{id:"alerts",children:"Alerts"}),"\n",(0,n.jsx)(t.p,{children:"There are no alerts configured by default for this integration."}),"\n",(0,n.jsx)(t.h2,{id:"metrics",children:"Metrics"}),"\n",(0,n.jsxs)(t.p,{children:["Metrics grouped by ",(0,n.jsx)(t.em,{children:"scope"}),"."]}),"\n",(0,n.jsx)(t.p,{children:"The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels."}),"\n",(0,n.jsx)(t.h3,{id:"per-maxscale-instance",children:"Per MaxScale instance"}),"\n",(0,n.jsx)(t.p,{children:"These metrics refer to the monitored MaxScale instance."}),"\n",(0,n.jsx)(t.p,{children:"This scope has no labels."}),"\n",(0,n.jsx)(t.p,{children:"Metrics:"}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Metric"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Description"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Dimensions"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Unit"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.poll_events"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Poll Events"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"reads, writes, accepts, errors, hangups"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"events/s"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.current_sessions"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Current Sessions"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"sessions"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"sessions"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.current_zombie_connections"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Current Zombie Connections"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"zombie"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"connections"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.threads_by_state"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Threads Count by State"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"active, draining, dormant"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"threads"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.current_fds"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Current Managed File Descriptors"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"managed"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"fds"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.qc_cache_efficiency"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"QC Cache Efficiency"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"hits, misses"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"requests/s"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.qc_cache_operations"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"QC Cache Operations"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"inserts, evictions"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"operations/s"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.uptime"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Uptime"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"uptime"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"seconds"})]})]})]}),"\n",(0,n.jsx)(t.h3,{id:"per-server",children:"Per server"}),"\n",(0,n.jsx)(t.p,{children:"These metrics refer to the MariaDB server."}),"\n",(0,n.jsx)(t.p,{children:"Labels:"}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Label"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"server"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Server ID."})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"address"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Server address."})]})]})]}),"\n",(0,n.jsx)(t.p,{children:"Metrics:"}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Metric"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Description"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Dimensions"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Unit"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.server_state"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Server State"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"master, slave, running, down, maintenance, draining, drained, relay_master, binlog_relay, synced"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"state"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"maxscale.server_current_connections"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Server Current connections"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"connections"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"connections"})]})]})]}),"\n",(0,n.jsx)(t.h2,{id:"troubleshooting",children:"Troubleshooting"}),"\n",(0,n.jsx)(t.h3,{id:"diagnostics",children:"Diagnostics"}),"\n",(0,n.jsx)(t.h4,{id:"debug-mode",children:"Debug Mode"}),"\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.strong,{children:"Important"}),": Debug mode is not supported for data collection jobs created via the UI using the Dyncfg feature."]}),"\n",(0,n.jsxs)(t.p,{children:["To troubleshoot issues with the ",(0,n.jsx)(t.code,{children:"maxscale"})," collector, run the ",(0,n.jsx)(t.code,{children:"go.d.plugin"})," with the debug option enabled. The output\nshould give you clues as to why the collector isn't working."]}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsxs)(t.li,{children:["\n",(0,n.jsxs)(t.p,{children:["Navigate to the ",(0,n.jsx)(t.code,{children:"plugins.d"}
1)," directory, usually at ",(0,n.jsx)(t.code,{children:"/usr/libexec/netdata/plugins.d/"}),". If that's not the case on\nyour system, open ",(0,n.jsx)(t.code,{children:"netdata.conf"})," and look for the ",(0,n.jsx)(t.code,{children:"plugins"})," setting under ",(0,n.jsx)(t.code,{children:"[directories]"}),"."]}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"cd /usr/libexec/netdata/plugins.d/\n"})}),"\n"]}),"\n",(0,n.jsxs)(t.li,{children:["\n",(0,n.jsxs)(t.p,{children:["Switch to the ",(0,n.jsx)(t.code,{children:"netdata"})," user."]}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"sudo -u netdata -s\n"})}),"\n"]}),"\n",(0,n.jsxs)(t.li,{children:["\n",(0,n.jsxs)(t.p,{children:["Run the ",(0,n.jsx)(t.code,{children:"go.d.plugin"})," to debug the collector:"]}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"./go.d.plugin -d -m maxscale\n"})}),"\n",(0,n.jsx)(t.p,{children:"To debug a specific job:"}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"./go.d.plugin -d -m maxscale -j jobName\n"})}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(t.h4,{id:"getting-logs",children:"Getting Logs"}),"\n",(0,n.jsxs)(t.p,{children:["If you're encountering problems with the ",(0,n.jsx)(t.code,{children:"maxscale"})," collector, follow these steps to retrieve logs and identify potential issues:"]}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsxs)(t.li,{children:[(0,n.jsx)(t.strong,{children:"Run the command"})," specific to your system (systemd, non-systemd, or Docker container)."]}),"\n",(0,n.jsxs)(t.li,{children:[(0,n.jsx)(t.strong,{children:"Examine the output"})," for any warnings or error messages that might indicate issues.  These messages should provide clues about the root cause of the problem."]}),"\n"]}),"\n",(0,n.jsx)(t.h5,{id:"system-with-systemd",children:"System with systemd"}),"\n",(0,n.jsx)(t.p,{children:"Use the following command to view logs generated since the last Netdata service restart:"}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:'journalctl _SYSTEMD_INVOCATION_ID="$(systemctl show --value --property=InvocationID netdata)" --namespace=netdata --grep maxscale\n'})}),"\n",(0,n.jsx)(t.h5,{id:"system-without-systemd",children:"System without systemd"}),"\n",(0,n.jsxs)(t.p,{children:["Locate the collector log file, typically at ",(0,n.jsx)(t.code,{children:"/var/log/netdata/collector.log"}),", and use ",(0,n.jsx)(t.code,{children:"grep"})," to filter for collector's name:"]}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"grep maxscale /var/log/netdata/collector.log\n"})}),"\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.strong,{children:"Note"}),": This method shows logs from all restarts. Focus on the ",(0,n.jsx)(t.strong,{children:"latest entries"})," for troubleshooting current issues."]}),"\n",(0,n.jsx)(t.h5,{id:"docker-container",children:"Docker Container"}),"\n",(0,n.jsx)(t.p,{children:'If your Netdata runs in a Docker container named "netdata" (replace if different), use this command:'}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{className:"language-bash",children:"docker logs netdata 2>&1 | grep maxscale\n"})})]})}function h(e={}){let{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,n.jsx)(t,{...e,children:(0,n.jsx)(o,{...e})}):o(e)}},28453(e,t,l){l.d(t,{R:()=>r,x:()=>d});var s=l(96540);let n={},i=s.createContext(n);function r(e){let t=s.useContext(i);return s.useMemo(function(){return"function"==typeof e?e(t):{...t,...e}},[t,e])}function d(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(n):e.components||n:r(e.components),s.createElement(i.Provider,{value:t},e.children)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.