Halloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanHalloween DealsAmazon USOctober picks are moving - compare before checkoutAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk12 min

How to Install Prometheus on a Linux VPS

A practical, security-conscious guide to installing Prometheus and Node Exporter on a Linux VPS, configuring scrape targets, running both services under systemd, verifying UP endpoints, and scaling to multiple servers.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Install Prometheus on a Linux VPS by downloading the release archive that matches the server architecture, placing the Prometheus and promtool binaries on the host, creating a YAML configuration, and running the server process. A practical single-VPS setup runs Prometheus on port 9090 and Node Exporter on port 9100, then verifies both endpoints from the Prometheus web interface.

The commands below use an upstream tarball installation, which gives you the release published by the Prometheus Authors rather than whatever version a Linux distribution repository happens to package. You can begin with a manually started process for a quick test, then create a restricted systemd service for reliable operation.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

What Prometheus does on a VPS

Prometheus is a monitoring server. It periodically scrapes HTTP endpoints that expose metrics, stores the resulting time series in its local time-series database, and lets you query those series in its expression browser. It is not an agent that passively receives every log line, and it does not automatically discover every process on a server. You define the endpoints to scrape in prometheus.yml.

For a single Linux VPS, the useful first target is the Prometheus process itself. The second is Node Exporter, a separate static binary that exposes operating-system metrics such as CPU time and available filesystem space. The Prometheus Authors describe Node Exporter as “a single static binary that you can install via tarball.”

#1 Best Overall
Sale
TOZO A1 Wireless Earbuds Bluetooth 5.3 Light Weight in Ear Headphones | IPX5 Waterproof,2 Mics for AI Calls,Immersive Premium Sound Bass Headset with Charging Case,32 EQ via App Black
  • [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
  • [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
  • [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
  • [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
  • [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.

The default/example scrape interval used in the official getting-started and Node Exporter guides is 15 seconds. That is frequent enough for normal host visibility without creating unnecessary scrape traffic on a small server. You can change it later after considering CPU, storage, and the number of targets.

Check the VPS before installing

Confirm architecture and operating system

Download an archive built for the VPS architecture. Run:

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
uname -m
cat /etc/os-release

Common results include x86_64 for 64-bit Intel/AMD machines and aarch64 for 64-bit ARM machines. Select the corresponding Linux build on the official Prometheus downloads page. Do the same for Node Exporter; using a binary for the wrong architecture produces an “exec format error” or a process that cannot start.

Plan users, directories, and access

Use a dedicated unprivileged account for each service. Prometheus needs to write its time-series database, while Node Exporter normally only reads kernel and system information. Create persistent directories before starting a service so a restart does not place data in an unexpected working directory:

sudo useradd --system --no-create-home --shell /usr/sbin/nologin prometheus
sudo useradd --system --no-create-home --shell /usr/sbin/nologin node_exporter
sudo mkdir -p /etc/prometheus /var/lib/prometheus
sudo chown -R prometheus:prometheus /etc/prometheus /var/lib/prometheus

If an account already exists, the useradd commands will report that fact; do not create a second account with a different name unless you also update the service files and ownership.

Decide how the web interfaces will be reached

Do not expose monitoring and configuration interfaces broadly on a public VPS. The Prometheus security guidance assumes that only trusted users can change command-line arguments, configuration files, and rule files. Decide whether you will:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • bind Prometheus to the loopback address and reach it through an authenticated reverse proxy or an SSH tunnel;
  • allow the web port only from a private network or your administration IP range; or
  • place the VPS behind a network firewall that blocks unsolicited Internet access.

Node Exporter should likewise be reachable by Prometheus, not by every Internet host. A firewall rule that permits the exporter only from the Prometheus machine is usually the narrowest choice.

Download and install Prometheus from the upstream archive

1. Obtain and extract the release

Open the official Prometheus downloads page, choose the current Linux archive for the architecture reported by uname -m, and download it to a temporary directory. The exact filename changes with each release, so do not hard-code an old version in a permanent script. Then extract and enter the directory:

Rank #2
Sale
Smart Watch for Men Women Compatible with iPhone Samsung Android Phone 1.69 inch Full Touch Screen IP68 Waterproof Bluetooh Fitness Tracker Heart Rate/Sleep Monitor (Black)
  • 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
  • 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
  • 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
  • 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
  • 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.
tar -xzf prometheus-*.tar.gz
cd prometheus-*

The extracted directory contains the Prometheus server binary, promtool, a sample prometheus.yml, and console assets. Install the two executables in a directory on the system path:

sudo install -m 0755 prometheus /usr/local/bin/prometheus
sudo install -m 0755 promtool /usr/local/bin/promtool

Keep the extracted archive until you have confirmed the new binaries work. It is also useful as a rollback copy, but do not run two Prometheus versions against the same data directory at the same time.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

2. Create the initial YAML configuration

Write /etc/prometheus/prometheus.yml with a global interval and a self-scrape job:

global:
  scrape_interval: 15s

scrape_configs:
  - job_name: prometheus
    static_configs:
      - targets: ['localhost:9090']

YAML indentation is significant. scrape_configs must be at the same indentation level as global, and each list item begins with a hyphen. A tab character can make the file invalid; use spaces.

Validate the file before starting the server:

promtool check config /etc/prometheus/prometheus.yml

A successful check reports that the configuration is valid. If it fails, fix the line and indentation identified in the error rather than starting Prometheus with a partially understood configuration.

3. Start Prometheus manually for the first test

Run the server from a shell to see startup messages directly:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
prometheus 
  --config.file=/etc/prometheus/prometheus.yml 
  --storage.tsdb.path=/var/lib/prometheus

The --storage.tsdb.path flag makes the data location explicit. Prometheus stores its time-series database there unless another startup flag changes it. Keep this process in the foreground while testing. Stop it with Ctrl+C after you have confirmed that the configuration and web interface work.

Run Prometheus as a systemd service

A systemd unit starts Prometheus after boot, restarts it if it exits unexpectedly, and gives you a consistent place to inspect logs. Create /etc/systemd/system/prometheus.service:

Rank #3
New Bee Guitar Cable 10ft Electric Instrument Bass AMP Cord
  • [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
  • [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
  • [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
  • [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
  • [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
[Unit]
Description=Prometheus monitoring server
Wants=network-online.target
After=network-online.target

[Service]
User=prometheus
Group=prometheus
Type=simple
ExecStart=/usr/local/bin/prometheus 
  --config.file=/etc/prometheus/prometheus.yml 
  --storage.tsdb.path=/var/lib/prometheus
Restart=on-failure

[Install]
WantedBy=multi-user.target

Apply the unit and start it:

sudo systemctl daemon-reload
sudo systemctl enable --now prometheus
sudo systemctl status prometheus
sudo journalctl -u prometheus -e

If the service cannot read the configuration or data directory, inspect ownership and permissions. The service account must be able to read the YAML file and write the database directory. If the port is already occupied, identify the conflicting process before changing Prometheus settings.

Install Node Exporter for Linux host metrics

1. Download the matching Node Exporter archive

Choose the Node Exporter release for the same Linux architecture on the official downloads page. Extract it and install the binary:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
tar -xzf node_exporter-*.tar.gz
cd node_exporter-*
sudo install -m 0755 node_exporter /usr/local/bin/node_exporter

Node Exporter is intentionally separate from Prometheus. Updating or restarting the exporter does not replace the Prometheus server, and the exporter does not need a YAML scrape configuration of its own for the basic host-metrics use case.

2. Start and test the exporter

Create /etc/systemd/system/node_exporter.service:

[Unit]
Description=Prometheus Node Exporter
Wants=network-online.target
After=network-online.target

[Service]
User=node_exporter
Group=node_exporter
Type=simple
ExecStart=/usr/local/bin/node_exporter
Restart=on-failure

[Install]
WantedBy=multi-user.target

Enable it and check the metrics endpoint locally:

sudo systemctl daemon-reload
sudo systemctl enable --now node_exporter
sudo systemctl status node_exporter
curl http://localhost:9100/metrics

A working response is plain-text metric exposition data. The Node Exporter guide uses examples such as node_cpu_seconds_total and node_filesystem_avail_bytes. If curl cannot connect, inspect the service journal before editing Prometheus; the exporter must be listening before Prometheus can scrape it.

3. Add the exporter to Prometheus

Edit /etc/prometheus/prometheus.yml and add a second item under scrape_configs:

global:
  scrape_interval: 15s

scrape_configs:
  - job_name: prometheus
    static_configs:
      - targets: ['localhost:9090']

  - job_name: node
    static_configs:
      - targets: ['localhost:9100']

The job_name becomes part of the labels attached to the scraped series. Keep it stable; dashboards and alerts commonly select series by job. For another VPS, replace localhost with a reachable address and ensure the exporter firewall policy permits the Prometheus server.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Validate and apply the change:

sudo promtool check config /etc/prometheus/prometheus.yml
sudo systemctl restart prometheus
sudo systemctl status prometheus

Restarting is the simplest documented workflow for a small installation. Prometheus also supports configuration reload mechanisms when you have deliberately enabled and secured one; never expose an unauthenticated reload endpoint on a public interface.

Verify every layer of the deployment

Check Prometheus itself

From the VPS, request the Prometheus metrics endpoint:

Rank #4
BSIMB 15.6" Digital Family Calendar & Chore Chart, No Subscription Fees
  • Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
  • Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
  • All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
  • Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
  • Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.
curl http://localhost:9090/metrics

You should receive Prometheus’s own process and scrape metrics. A connection failure points to a stopped service, a bind-address mismatch, or a local firewall rule. An HTTP error usually means the process started with a problem that is visible in journalctl.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use the web interface and Targets page

Open the interface through your trusted network path and visit /targets, also available as Status → Target health in the UI. The Prometheus and Node Exporter endpoints should both show UP. The page displays the last scrape, scrape duration, and any error returned by a target.

In the expression browser, run these queries individually:

  • up to see whether each configured target is currently reachable; a value of 1 means the scrape succeeded and 0 means it failed.
  • node_cpu_seconds_total to confirm that Node Exporter is exposing CPU counters.
  • node_filesystem_avail_bytes to confirm that filesystem-availability metrics are being collected.

Use the labels shown with each result to distinguish the Prometheus job from the node job and to verify that the expected instance address is being scraped.

Troubleshoot a target marked DOWN

Work from the target outward rather than changing several settings at once:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Check the process. Run sudo systemctl status node_exporter and inspect sudo journalctl -u node_exporter -e. A crash, permission error, or invalid executable must be fixed at the exporter.
  2. Test the endpoint locally. Run curl http://localhost:9100/metrics. If this fails on the same VPS, Prometheus cannot succeed either.
  3. Confirm the listening address and port. Use the service logs and the host’s socket tools to verify that the exporter is listening where the target address expects it. A process bound only to loopback cannot be reached through a private network address.
  4. Check firewall policy. Permit the Prometheus host to reach the exporter while keeping the exporter closed to untrusted sources. Also check any cloud security group in front of the VPS.
  5. Inspect the target text in YAML. A typo in the hostname, port, indentation, or job block can produce a scrape error. Run promtool check config after every edit.
  6. Read the error shown on the Targets page. “Connection refused” generally means no listener or a rejected port; a timeout commonly indicates routing or firewall filtering; an HTTP parsing or status error points to the wrong path or a non-metrics service.

When Prometheus itself is DOWN, first test its own /metrics endpoint and then inspect its journal. If the service starts and exits immediately, a configuration parse failure, unavailable data directory, or occupied listening port is more likely than a Node Exporter problem.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Choose an operating model

Decision Option When it fits Trade-off
Binary source Distribution package You want integration with the operating system’s package manager and update policy. The packaged release may lag behind the current upstream release.
Binary source Upstream tarball You need the release selected on the official Prometheus downloads page and a predictable standalone layout. You own download verification, replacement, permissions, and update scheduling.
Process management Manual foreground process Initial testing, troubleshooting, or a temporary lab VPS. The process stops when the shell ends unless you add a supervisor, and boot recovery is manual.
Process management systemd service Any persistent production or personal monitoring host. You must maintain a unit file, service account, and data-directory ownership.
Target definition Static targets A small, stable set of VPS instances. Every address change requires a configuration edit and reload or restart.
Target definition File-based discovery A changing fleet whose target list is maintained separately from the main YAML. You must operate and protect the discovery file and keep its labels valid.
Web access Local-only binding You administer the VPS through SSH or a private network. Remote users need a tunnel or private route.
Web access Protected reverse proxy You need browser access from elsewhere and can enforce authentication and TLS. The proxy becomes another security-sensitive component to configure and update.
Topology One Prometheus per VPS Small deployments where each server can retain its own history. Dashboards and retention are fragmented across machines.
Topology Central Prometheus A fleet that needs one query surface and centralized alerting. Network reachability, firewall rules, and the central server become critical dependencies.

Monitor multiple VPS instances with file-based discovery

Static configuration is clear for one or two machines. For a changing fleet, use file_sd_configs and keep the target list in a separate targets.json file. The official file-SD guidance says Prometheus watches that file and automatically updates the scrape target list when it changes, avoiding an edit to the main configuration for every target change.

A minimal discovery block looks like this:

scrape_configs:
  - job_name: node
    file_sd_configs:
      - files:
          - /etc/prometheus/targets.json

The discovery file contains an array of target groups. For example:

[
  {
    'targets': ['vps-a.example.internal:9100'],
    'labels': {'environment': 'production', 'region': 'east'}
  },
  {
    'targets': ['vps-b.example.internal:9100'],
    'labels': {'environment': 'production', 'region': 'west'}
  }
]

JSON requires double quotes in an actual file; the single quotes above are shown only to keep this HTML example readable inside the publication format. Before deploying, replace them with valid JSON double quotes and validate the resulting configuration. Store the file with ownership and permissions that let the Prometheus service read it but prevent untrusted users from changing scrape destinations. A target-file edit can redirect monitoring traffic, so treat it as configuration, not as harmless data.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Secure and maintain the VPS

Restrict interfaces and configuration

Prometheus command-line flags can change storage, listening behavior, and other security-relevant properties. Protect the service unit, YAML file, rule files, discovery files, and the data directory from untrusted write access. If a reverse proxy is used, require authentication and encrypted transport, and avoid forwarding administrative endpoints unnecessarily.

Do not publish Node Exporter’s metrics endpoint to the entire Internet. Metrics can reveal hostnames, mount points, interfaces, kernel details, and workload patterns even when they do not contain application secrets.

Update on a defined schedule

Prometheus and exporters are ordinary software components, not fire-and-forget appliances. Track upstream releases, test replacement binaries, preserve the data directory, and restart one service at a time. The Prometheus security guidance sets a seven-day target for applying security fixes to Prometheus and listed exporters. Treat that as an operational goal: review advisories promptly, schedule the update inside seven days when a security fix applies, and verify the Targets page afterward.

Protect storage and retention

The local time-series database grows with scrape frequency, number of targets, and number of distinct labels. Monitor free space on the filesystem containing /var/lib/prometheus. A full disk can stop new samples and may prevent clean shutdown. Keep a backup or snapshot strategy appropriate to the value of the history, and document the storage path in the systemd unit so a future administrator does not mistake it for disposable temporary data.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Common installation mistakes

  • Wrong archive architecture: choose the Linux build that matches uname -m; an ARM VPS cannot run an x86-64 executable.
  • Running from the extracted directory: a shell test may work while a boot-time service fails because its working directory or relative paths are different. Use absolute paths in the unit and configuration.
  • Data directory owned by root: a service running as prometheus must be able to write its configured storage path.
  • Malformed YAML: tabs, incorrect list indentation, and placing targets outside static_configs are frequent causes. Validate with promtool check config.
  • Exporter installed but not scraped: installing Node Exporter does not add it to Prometheus. The node job must appear under scrape_configs, followed by a restart or secured reload.
  • Firewall opened too widely: allow only the administration path to Prometheus and only the Prometheus host to Node Exporter.
  • Editing the wrong configuration: inspect the service’s --config.file argument. A valid edit to another copy has no effect.
  • Changing target addresses without checking routes: a hostname that resolves on the shell may still be unreachable from the Prometheus service namespace or network policy.

What a successful installation looks like

At the end of the basic setup, Prometheus is running under a dedicated account, its YAML file defines a 15-second scrape interval and two jobs, and its database resides in the explicit storage directory. Node Exporter is running separately and serves host metrics locally. The Prometheus Targets page reports both jobs as UP, the expression browser returns up values of 1 for those endpoints, and queries for CPU and filesystem metrics return current series.

From there, keep the deployment deliberately small until you know which metrics, retention period, access paths, and alert rules you actually need. Add file-based discovery when the fleet changes often, move to a centralized server when one query surface is more valuable than local independence, and keep every monitoring interface behind a narrowly controlled network boundary.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.