...

πŸš€ how to install and run netdata on almalinux vpsThis article provides a step-by-step guide detailing how to install and run Netdata on AlmaLinux VPSβ€”a powerful, real-time performance monitoring tool for systems and applications.

βœ… What is Netdata?

Netdata is an open-source monitoring agent that provides real-time performance metrics for systems, applications, containers, and moreβ€”displayed through an interactive web dashboard. It’s lightweight, highly efficient, and ideal for resource monitoring on servers like VPSes.

πŸ› οΈ Prerequisites

  • AlmaLinux 8 or AlmaLinux 9 VPS
  • Root or sudo access
  • Internet access
  • Optional: Firewall access if remote monitoring is required

Launch 100% ssd almalinux vps from $2. 49/mo!

How to Install and Run Netdata on AlmaLinux VPS

To install and run Netdata on AlmaLinux VPS, follow the steps below:

  1. Step-by-Step Installation Guide

    1. Update Your System

      sudo dnf update -y
      sudo dnf install epel-release -y
      
    2. Install Required Dependencies

      sudo dnf install git curl gcc make autoconf autogen automake pkgconfig zlib-devel libuuid-devel libmnl-devel cmake libuv-devel libyaml-devel openssl-devel -y
      
    3. Add the Netdata User (Optional but Recommended)

      sudo useradd -r -U netdata
      
    4. Clone Netdata Installer from GitHub

      curl https://get.netdata.cloud/kickstart.sh > /tmp/netdata-kickstart.sh && sh /tmp/netdata-kickstart.sh --no-updates --stable-channel --disable-telemetry
      sudo systemctl enable --now netdata
      

      This script installs Netdata and its dependencies automatically. It’s safe and the recommended method from the Netdata team.

  2. Verify Installation

    After installation, check that the Netdata service is running:

    sudo systemctl status netdata
    

    Expected output:

    Active: active (running)
    

    If not running, start and enable Netdata:

    sudo systemctl enable --now netdata
    
  3. Install SSL via Certbot and Nginx

    1. Install Nginx and Certbot

      sudo dnf install nginx -y
      sudo systemctl enable --now nginx
      

      Install Certbot and its Nginx plugin:

      sudo dnf install epel-release -y
      sudo dnf install certbot python3-certbot-nginx -y
      
    2. Configure Nginx as Reverse Proxy for Netdata

      Create Nginx site config for your domain:

      sudo nano /etc/nginx/conf.d/netdata.conf
      

      Paste this (replace monitor.yourdomain.com):

      server {
          listen 80;
          server_name monitor.yourdomain.com;
      
          location / {
              proxy_pass http://127.0.0.1:19999/;
              proxy_set_header Host $host;
              proxy_http_version 1.1;
              proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
              proxy_set_header Upgrade $http_upgrade;
              proxy_set_header Connection "upgrade";
          }
      }
      

      Then reload Nginx:

      sudo nginx -t && sudo systemctl reload nginx
      

      Verify by visiting:
      http://monitor.yourdomain.com

    3. Obtain SSL Certificate via Certbot

      Run Certbot to secure your domain:

      sudo certbot --nginx -d monitor.yourdomain.com
      
      • Follow the prompts
      • Certbot will configure SSL and reload Nginx

      Once complete, visit:
      https://monitor.yourdomain.com

    4. Auto-Renewal (Recommended)

      Certbot adds automatic renewal via cron or systemd, but you can test it:

      sudo certbot renew --dry-run
      
  4. Force HTTP to HTTPS Redirection

    1. Redirect HTTP to HTTPS

      Edit the Nginx Netdata config:

      sudo nano /etc/nginx/conf.d/netdata.conf
      

      Update it to include a redirect block:

      # Redirect all HTTP traffic to HTTPS
      server {
          listen 80;
          server_name monitor.yourdomain.com;
          return 301 https://$host$request_uri;
      }
      
      # HTTPS block (created by Certbot or manually)
      server {
          listen 443 ssl http2;
          server_name monitor.yourdomain.com;
      
          ssl_certificate /etc/letsencrypt/live/monitor.yourdomain.com/fullchain.pem;
          ssl_certificate_key /etc/letsencrypt/live/monitor.yourdomain.com/privkey.pem;
          include /etc/letsencrypt/options-ssl-nginx.conf;
          ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
      
          location / {
              proxy_pass http://127.0.0.1:19999/;
              proxy_set_header Host $host;
              proxy_http_version 1.1;
              proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
              proxy_set_header Upgrade $http_upgrade;
              proxy_set_header Connection "upgrade";
          }
      }
      

      Save and reload Nginx:

      sudo nginx -t && sudo systemctl reload nginx
      
    2. Update Firewall Rules (Firewalld)

      Allow HTTP (80) and HTTPS (443):

      sudo firewall-cmd --permanent --add-service=http
      sudo firewall-cmd --permanent --add-service=https
      sudo firewall-cmd --reload
      
  5. Access Netdata Dashboard

    By default, Netdata serves on port 19999. To access:

    http://your-server-ip:19999
    
  6. Configure Firewall (If Running Firewalld)

    If firewalld is active, allow port 19999:

    sudo firewall-cmd --permanent --add-port=19999/tcp
    sudo firewall-cmd --reload
    
  7. Configuring Netdata

    Edit Main Configuration

    sudo nano /etc/netdata/netdata.conf
    

    Change the bind to directive if you want to expose Netdata to external IPs:

    [web]
        bind to = 0.0.0.0
    

    After changes, restart Netdata:

    sudo systemctl restart netdata
    
  8. Enable Basic Authentication (Nginx Proxy)

    If exposing Netdata publicly, it’s strongly recommended to set up authentication behind a reverse proxy like Nginx or Apache.

πŸ“¦ Uninstall Netdata

sudo /usr/libexec/netdata/netdata-uninstaller.sh --yes

πŸ“ˆ What You Can Monitor with Netdata

  • CPU, memory, disk I/O
  • Network traffic and errors
  • Running processes and resource usage
  • MySQL, Nginx, Apache, Docker, and more via plugins

🧠 Troubleshooting

  • Logs are located at /var/log/netdata/
  • Configs: /etc/netdata/
  • Web files: /usr/share/netdata/web/

Launch 100% ssd almalinux vps from $2. 49/mo!

Now that you know how to install and run Netdata on AlmaLinux VPS, let’s learn how to integrate Netdata with Prometheus and Grafana on your AlmaLinux VPS:

πŸ”— Overview of the Integration

  • Netdata β†’ collects real-time metrics
  • Prometheus β†’ scrapes metrics from Netdata for storage and querying
  • Grafana β†’ visualizes those metrics using queries from Prometheus

SEE ALSO:Β Top 10 Best Grafana Dashboards for Service Monitoring

  1. Enable Netdata’s Prometheus Exporter

    1. Open Netdata’s stream.conf and health.d/prometheus.conf:
      sudo nano /etc/netdata/netdata.conf
      
    2. Find or add the following in the [web] section:
      [web]
          enable_prometheus = yes
          prometheus_port = 19999
      

      Prometheus can scrape metrics from:
      http://<your-server-ip>:19999/api/v1/allmetrics?format=prometheus

    3. Restart Netdata:
      sudo systemctl restart netdata
      
  2. Install Prometheus on AlmaLinux

    1. Create Prometheus User & Directories

      sudo useradd --no-create-home --shell /bin/false prometheus
      sudo mkdir /etc/prometheus /var/lib/prometheus
      
    2. Download and Install Prometheus

      curl -LO https://github.com/prometheus/prometheus/releases/download/v2.52.0/prometheus-2.52.0.linux-amd64.tar.gz
      tar xvf prometheus-2.52.0.linux-amd64.tar.gz
      cd prometheus-2.52.0.linux-amd64
      
      sudo cp prometheus promtool /usr/local/bin/
      sudo cp -r consoles console_libraries /etc/prometheus/
      
    3. Configure Prometheus

      Create or edit /etc/prometheus/prometheus.yml:

      global:
        scrape_interval: 15s
      
      scrape_configs:
        - job_name: 'netdata'
          static_configs:
            - targets: ['localhost:19999']
      
    4. Create Systemd Service File

      sudo nano /etc/systemd/system/prometheus.service
      

      Paste:

      [Unit]
      Description=Prometheus
      Wants=network-online.target
      After=network-online.target
      
      [Service]
      User=prometheus
      ExecStart=/usr/local/bin/prometheus \
        --config.file=/etc/prometheus/prometheus.yml \
        --storage.tsdb.path=/var/lib/prometheus/ \
        --web.console.templates=/etc/prometheus/consoles \
        --web.console.libraries=/etc/prometheus/console_libraries
      
      [Install]
      WantedBy=default.target
      
    5. Start Prometheus

      sudo systemctl daemon-reexec
      sudo systemctl daemon-reload
      sudo systemctl enable --now prometheus
      

      Test it:

      http://<your-server-ip>:9090
      
  3. Install Grafana on AlmaLinux

    1. Add Grafana Repo

      sudo tee /etc/yum.repos.d/grafana.repo<
      
    2. Install Grafana

      sudo dnf install grafana -y
      sudo systemctl enable --now grafana-server
      

      Access Grafana at:

      http://<your-server-ip>:3000
      

      Default login:
      Username: admin
      Password: admin

  4. Connect Grafana to Prometheus

    1. Log into Grafana
    2. Go to Settings > Data Sources > Add data source
    3. Choose Prometheus
    4. Set URL: http://localhost:9090
    5. Click Save & Test
  5. Import Netdata Dashboard

    1. Go to Dashboards > Import
    2. Use dashboard ID: 1860 (Community Netdata Dashboard)
    3. Select Prometheus as data source

βœ… Done!

You’ve now:

  • Installed and configured Netdata
  • Set up Prometheus to scrape Netdata
  • Connected Grafana to Prometheus
  • Imported Netdata dashboards

Launch 100% ssd almalinux vps from $2. 49/mo!

Conclusion

You now know how to install and run Netdata on AlmaLinux VPS. You also know how to integrate Netdata with Prometheus and Grafana.

Avatar of editorial staff

Editorial Staff

Rad Web Hosting is a leading provider of web hosting, Cloud VPS, and Dedicated Servers in Dallas, TX.

One thought on β€œπŸš€ How to Install and Run Netdata on AlmaLinux VPS (5 Minute Quick-Start Guide)”

Comments are closed.

lg