{"id":8571,"date":"2025-05-15T17:58:32","date_gmt":"2025-05-15T12:28:32","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=8571"},"modified":"2025-05-15T17:58:37","modified_gmt":"2025-05-15T12:28:37","slug":"install-metric-beat-and-configure-for-cpu-disk-and-memory-monitoring-in-elk","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/install-metric-beat-and-configure-for-cpu-disk-and-memory-monitoring-in-elk\/","title":{"rendered":"Install metric beat and configure for CPU, disk  and memory monitoring in ELK."},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><strong>Introduction<\/strong>:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Metricbeat is a lightweight shipper for collecting and forwarding system and service metrics to Elasticsearch, Logstash, or another data processor. It periodically collects data from configured metric sets and sends it to a specified output.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Prerequisite<\/strong>:<br>1. Need Elastic search, Logstash and Kibana preconfigured server.<br>2. Allow the required port to receive the Metrics data in that logstash.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Configurations:<\/strong><\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Log in to the client-server on which you want to monitor the metrics.<\/li>\n\n\n\n<li>Install metric beat from the community release or use the commands below<div>to install and untar the fil<span style=\"color: initial\">e.<\/span><\/div><\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\"><code>curl -L -O https:\/\/artifacts.elastic.co\/downloads\/beats\/metricbeat\/metricbeat-8.12.1-linux-x86_64.tar.gz<br>tar xzvf metricbeat-8.12.1-linux-x86_64.tar.gz<br>cd metricbeat-8.12.1-linux-x86_64<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">3. In the metricbeat.yml config file need to add the URL of Elasticsearch, Password and protocol, as like below. mentioned text.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Configurations for Managed ELK (AWS-Marketplace, ELK cloud etc.,) metricbeat.yml<\/li>\n<\/ol>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\"># =============================== Elastic Cloud ================================\n# These settings simplify using Metricbeat with the Elastic Cloud (https:\/\/cloud.elastic.co\/).\n# The cloud.id setting overwrites the `output.elasticsearch.hosts` and\n# `setup.kibana.host` options.\n# You can find the `cloud.id` in the Elastic Cloud web UI.\n# ================================== Outputs ===================================\n# Configure what output to use when sending the data collected by the beat.\n# ---------------------------- Elasticsearch Output ----------------------------\noutput.elasticsearch:\n  cloud_id: \"Paste the URL of your Managed Elastic serch\"\n  cloud.auth: \"Enter the password to get access the above link\"\n  protocol: \"https\"\n  # Array of hosts to connect to.\n  # hosts: [\"localhost:9200\"]\n  # Performance preset - one of \"balanced\", \"throughput\", \"scale\",\n  # \"latency\", or \"custom\".\n  preset: balanced\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">2. Configurations for a standalone ELK server &#8211; metricbeat.yml<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\"># =============================== Elastic Cloud ================================\n# These settings simplify using Metricbeat with the Elastic Cloud (https:\/\/cloud.elastic.co\/).\n# The cloud.id setting overwrites the `output.elasticsearch.hosts` and\n# `setup.kibana.host` options.\n# You can find the `cloud.id` in the Elastic Cloud web UI.\n# ================================== Outputs ===================================\n# Configure what output to use when sending the data collected by the beat.\n# ---------------------------- Elasticsearch Output ----------------------------\noutput.elasticsearch:\n  protocol: \"http\"\n  # Array of hosts to connect to.\n  hosts: [\"&lt;ELK-host-ip&gt;:9200\"]\n  username: \"&lt;elasticsearch-username&gt;\"\n  password: \"&lt;elasticsearch-password&gt;\"\n  # Performance preset - one of \"balanced\", \"throughput\", \"scale\",\n  # \"latency\", or \"custom\".\n  preset: balanced\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">4. After the config file is updated use the below command to run the metricbeat<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.\/metricbeat -e -c metricbeat.yml &amp;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">5. The metric beat service is run check by using this command.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ps aux | grep metricbeat<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">6. After that, check the hosts in Elastic URL -&gt; Observability-&gt;Infrastructure-&gt;Hosts.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Meticbeat is running successfully on the remote server.<br>IP will be listed on the Hosts Tab.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e.png\"><img fetchpriority=\"high\" decoding=\"async\" width=\"1024\" height=\"454\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-1024x454.png\" alt=\"\" class=\"wp-image-8923\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-1024x454.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-300x133.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-768x340.png 768w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-1536x681.png 1536w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e-677x300.png 677w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/458a4fa0-166a-4cf8-8dd4-87ac92d4188e.png 1767w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">7. Select the IP (sample-ip-xx-xx-2-89) and choose to create a rule.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7.png\"><img decoding=\"async\" width=\"1024\" height=\"431\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-1024x431.png\" alt=\"\" class=\"wp-image-8924\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-1024x431.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-300x126.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-768x323.png 768w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-1536x646.png 1536w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7-713x300.png 713w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/41b839f8-d745-49d0-87fb-e2f8c91268a7.png 1557w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">8. Choose the Create Rule option pop-up window on the right side, will enter the Name column metric alert Name (CPU)<br> Name &#8211; xxxxxx CPU Utilisation Monitor<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371.png\"><img decoding=\"async\" width=\"1024\" height=\"426\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-1024x426.png\" alt=\"\" class=\"wp-image-8925\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-1024x426.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-300x125.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-768x320.png 768w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-1536x640.png 1536w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-720x300.png 720w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371-1200x500.png 1200w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/05\/4d8b7288-5d92-490c-9ae0-af6a8344f371.png 1794w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">9. In Conditions, choose <strong>CPU usage<\/strong> and enter the target value (eg.80) in the <strong>IS ABOVE<\/strong> column, which means CPU spikes above 80% will receive the alert notification.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/df86f5fb-d1c2-4238-ba47-a58d6870536e.png\"><img loading=\"lazy\" decoding=\"async\" width=\"765\" height=\"492\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/df86f5fb-d1c2-4238-ba47-a58d6870536e.png\" alt=\"\" class=\"wp-image-8575\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/df86f5fb-d1c2-4238-ba47-a58d6870536e.png 765w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/df86f5fb-d1c2-4238-ba47-a58d6870536e-300x193.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/df86f5fb-d1c2-4238-ba47-a58d6870536e-466x300.png 466w\" sizes=\"(max-width: 765px) 100vw, 765px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">10. Scroll down in the action Tab, choose OpsGenie, and in the Message and Description box, enter the required message.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/879b2f23-098d-4111-99fb-55640a632a17.png\"><img loading=\"lazy\" decoding=\"async\" width=\"742\" height=\"726\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/879b2f23-098d-4111-99fb-55640a632a17.png\" alt=\"\" class=\"wp-image-8576\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/879b2f23-098d-4111-99fb-55640a632a17.png 742w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/879b2f23-098d-4111-99fb-55640a632a17-300x294.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/879b2f23-098d-4111-99fb-55640a632a17-307x300.png 307w\" sizes=\"(max-width: 742px) 100vw, 742px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">11. In the action menu, choose your required service to receive the alert.<br>Create the connector if it is not configured previously.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-4.png\"><img loading=\"lazy\" decoding=\"async\" width=\"724\" height=\"527\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-4.png\" alt=\"\" class=\"wp-image-8614\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-4.png 724w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-4-300x218.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-4-412x300.png 412w\" sizes=\"(max-width: 724px) 100vw, 724px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><br><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-2.png\"><img loading=\"lazy\" decoding=\"async\" width=\"736\" height=\"715\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-2.png\" alt=\"\" class=\"wp-image-8612\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-2.png 736w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-2-300x291.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-2-309x300.png 309w\" sizes=\"(max-width: 736px) 100vw, 736px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">12. Choose save.<br>Check the rules have updated or not Observability-&gt; Alerts -&gt; Rules.<br><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"482\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-1024x482.png\" alt=\"\" class=\"wp-image-8615\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-1024x482.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-300x141.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-768x362.png 768w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-1536x723.png 1536w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5-637x300.png 637w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2025\/02\/image-5.png 1665w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction: Metricbeat is a lightweight shipper for collecting and forwarding system and service metrics to Elasticsearch, Logstash, or another data [&hellip;]<\/p>\n","protected":false},"author":509,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1022],"tags":[],"class_list":["post-8571","post","type-post","status-publish","format-standard","hentry","category-web-architecture","psol-cat-web-architecture"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-2ef","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8571","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/509"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=8571"}],"version-history":[{"count":0,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8571\/revisions"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=8571"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=8571"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=8571"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}