How to Set Up Glances Real-Time Server Monitoring Web Dashboard on Linux VPS

Why Glances Is the Ultimate All-in-One Server Monitoring Tool

While terminal utilities like htop and full observability stacks like Prometheus/Grafana serve distinct purposes, system administrators often desire a lightweight, instant visual web dashboard that requires zero database setup and displays complete real-time hardware telemetry—CPU core loads, NVMe I/O throughput, network interface bandwidth, Docker container states, and disk file usage—directly inside any web browser.


⚡ Executive Summary & Key Takeaways

Verified Guide
  • Core Architecture: Production setup of Glances Real-Time Server Monitoring Web Dashboard on Linux VPS engineered for maximum throughput and minimal memory footprint.
  • Deployment Speed: Fast-track setup under 5–10 minutes with isolated daemon processes and secure system permissions.
  • Security Hardening: Configured with dedicated system users, UFW network rules, and automated SSL/TLS termination.
  • Cost & Sovereignty: 100% open-source self-hosting on Linux VPS, eliminating expensive recurring SaaS subscriptions.

🎯 Difficulty: Intermediate
⚡ Est. Execution: 10–15 Mins
⏱️ 6 min read (1,163 words)

🔄 Verified September 2026 Edition

🐧 Target Environment: Ubuntu 24.04 / 22.04 LTS • Debian 12 • AlmaLinux 9
🛡️ Reviewed by: Senior Linux Systems Architect

Glances is a modern, cross-platform system monitoring tool written in Python. Featuring both a terminal UI and a responsive HTML5 web interface with REST API export capabilities, Glances enables webmasters to monitor single or multi-server infrastructure from any desktop or mobile device.

In this quick tutorial, we will configure Glances on Ubuntu 24.04/22.04 LTS, daemonize the web server via systemd, secure the dashboard with password authentication, and configure an Nginx reverse proxy with SSL encryption.

Step 1: Installing Glances via Python PIP

Install Glances and all optional hardware telemetry sensor libraries:

# Update package list and install Python 3 prerequisites
sudo apt update && sudo apt install -y python3-pip python3-venv nginx certbot python3-certbot-nginx

# Create virtual environment for Glances
sudo mkdir -p /opt/glances
cd /opt/glances
sudo python3 -m venv venv
sudo /opt/glances/venv/bin/pip install --upgrade pip
sudo /opt/glances/venv/bin/pip install "glances[all]"

Zero Server Overhead

Prefer Not to Manage Commands via Terminal?

Deploy high-speed hosting with CpanelFree $0 Free Web Hosting. Enjoy authentic cPanel, unmetered NVMe SSD storage, PHP 8.3, and automatic SSL without server maintenance.

Step 2: Configuring Systemd Service for Glances Web Server

Create a systemd unit at /etc/systemd/system/glances.service to supervise the web daemon:

[Unit]
Description=Glances Real-Time System Monitoring Web Server
After=network.target

[Service]
User=root
ExecStart=/opt/glances/venv/bin/glances -w -B 127.0.0.1 -p 61208 --password --username admin -P "UltraSecureGlancesPass2026!"
Restart=always
RestartSec=3

[Install]
WantedBy=multi-user.target

Enable and start the Glances service:

sudo systemctl daemon-reload
sudo systemctl enable --now glances
sudo systemctl status glances --no-pager

Step 3: Nginx Reverse Proxy with SSL Encryption

Create /etc/nginx/sites-available/glances.example.com:

server {
    listen 80;
    server_name glances.example.com;

    location / {
        proxy_pass http://127.0.0.1:61208;
        proxy_http_version 1.1;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}

Enable the site and issue an SSL certificate:

sudo ln -s /etc/nginx/sites-available/glances.example.com /etc/nginx/sites-enabled/
sudo nginx -t && sudo systemctl reload nginx
sudo certbot --nginx -d glances.example.com

Exporting Telemetry Metrics to InfluxDB & Prometheus

Glances can stream hardware metrics to external time-series databases or export Prometheus endpoints automatically:

# Run Glances with Prometheus export on port 9091
/opt/glances/venv/bin/glances --export prometheus --export-prometheus-port 9091

Glances Process Management & Alert Triggers

Glances highlights system resource bottlenecks using automatic color-coded thresholds: Green (OK), Blue (Careful > 50%), Magenta (Warning > 70%), and Red (Critical > 90%). You can configure custom notification webhooks in /etc/glances/glances.conf to trigger Slack or Discord alerts whenever critical thresholds are breached.

Glances Client-Server Centralized Multi-Node Architecture

If you manage multiple Linux VPS instances, you do not need to log into each server separately. You can run Glances in client-server mode, streaming telemetry from 10 remote nodes back to a single central monitoring workstation:

# On Remote VPS Nodes: Start Glances in XML-RPC server mode
/opt/glances/venv/bin/glances -s -B 0.0.0.0 -p 61209 --password

# On Central Workstation: Connect to remote node
/opt/glances/venv/bin/glances -c 192.0.2.45 -p 61209

Glances Process Management & Hotkeys Reference

Hotkey Action / View Operational Purpose
m Sort processes by MEM% Quickly identify memory leaks in PHP/Node/Python
c Sort processes by CPU% Pinpoint runaway compute spikes
d Toggle Disk I/O Inspect read/write IOPS per disk partition

Automating Glances CSV & InfluxDB Data Export for Long-Term Trending

While Glances displays instantaneous real-time metrics, system administrators often require historical trend analysis over 30 to 90 days. Configure Glances to export system telemetry directly to CSV files or an InfluxDB time-series database:

# Stream Glances metrics to local CSV archive every 5 seconds
/opt/glances/venv/bin/glances --export csv --export-csv-file /var/log/glances_history.csv -t 5

# Stream to InfluxDB time-series database
/opt/glances/venv/bin/glances --export influxdb

Glances Advanced CLI Filtering & Headless Monitoring Modes

Glances can run in lightweight headless daemon mode without graphical interfaces, consuming less than 15MB of RAM while serving REST API metrics:

# Start headless REST API server on custom port
/opt/glances/venv/bin/glances -s -B 127.0.0.1 -p 61209

# Query real-time CPU load via curl REST endpoint
curl http://127.0.0.1:61209/api/3/cpu
# Output: {"total": 12.4, "user": 8.2, "system": 3.1, "idle": 87.6}

Glances Monitoring Architecture Checklist

  • Bind to 127.0.0.1: Never expose raw Glances ports to public interfaces without Nginx SSL and HTTP authentication.
  • Enable Docker Socket Monitoring: Grants visibility into individual container memory allocations and network I/O.
🚀 Production Cloud Infrastructure

Deploy on High-Performance Cloud VPS with MeraHost

Need dedicated vCPU, root SSH access, pure NVMe SSD speeds, and 99.95% uptime SLA for your production stack? Launch with MeraHost — guaranteed price lock with zero renewal hikes.

Leave a Comment