top of page

Install Grafana on AWS at Low Cost

  • Writer: Aslam Latheef
    Aslam Latheef
  • May 5, 2025
  • 2 min read

Installing Grafana on AWS at minimal cost (i.e., "rent-to-cost" or budget-conscious deployment) can be done using a lightweight EC2 instance and leveraging free or open-source configurations. Here's a step-by-step guide:


Grafana dashboard with colorful data graphs and charts. Bright text reads "Install and manage integrations" on dark background.


How to Install Grafana on AWS at Low Cost

Requirements

  • AWS Account

  • Basic knowledge of EC2 and Linux commands

  • SSH client or AWS Cloud Shell



Step 1: Launch a Low-Cost EC2 Instance


  • Log in to the AWS Management Console.

  • Go to EC2 → Launch Instance.

  • Choose the Amazon Linux 2 AMI or Ubuntu Server (20.04 or later).

  • Select an Instance Type:

    • Use t2.micro or t3.micro (eligible for Free Tier) or spot instances for extra savings.

  • Configure storage (8–10 GB is usually enough).

  • Add a security group with inbound rules:

    • SSH (port 22) — your IP

    • HTTP (port 80)

    • Grafana (port 3000)

  • Launch the instance and download the key pair.


    AWS EC2 console screen showing "Launch an instance" with "myec2" entered in the Name field. Browser tabs and address bar visible.



Step 2: Connect and Install Grafana


  1. SSH into your instance:

    bash

    CopyEdit

    ssh -i your-key.pem ec2-user@your-ec2-public-ip

  2. Update packages:

    bash

    CopyEdit

    sudo yum update -y # For Amazon Linux

  3. Install Grafana:

    bash

    CopyEdit

    sudo tee /etc/yum.repos.d/grafana.repo<<EOF [grafana] name=grafana baseurl=https://packages.grafana.com/oss/rpm repo_gpgcheck=1 enabled=1 gpgcheck=1 gpgkey=https://packages.grafana.com/gpg.key EOF sudo yum install grafana -y

    For Ubuntu:

    bash

    CopyEdit

    sudo apt-get install -y software-properties-common sudo add-apt-repository "deb https://packages.grafana.com/oss/deb stable main" wget -q -O - https://packages.grafana.com/gpg.key | sudo apt-key add - sudo apt-get update sudo apt-get install grafana -y


    Dashboard displaying website performance data, including memory, CPU, server requests, logins, Google hits, and support calls. Graphs in various colors.



Step 3: Start and Enable Grafana

bash

CopyEdit

sudo systemctl daemon-reexec sudo systemctl start grafana-server sudo systemctl enable grafana-server



Step 4: Access Grafana Web UI


  1. Open a browser and go to:

    cpp

    CopyEdit

    http://<EC2-Public-IP>:3000

  2. Login with default credentials:

    • Username: admin

    • Password: admin (you’ll be prompted to change it)



Tips to Keep Costs Low


  • Free Tier: Use t2.micro if eligible.

  • Spot Instances: For non-critical use, they’re up to 90% cheaper.

  • Stop Instance when not in use.

  • Use Grafana OSS (Open Source Edition): No license cost.

  • Monitor usage via AWS Budgets.



Optional: Add Prometheus or CloudWatch as Data Source


  • Prometheus can be installed similarly and used to monitor local services.

  • AWS CloudWatch can be added directly via the CloudWatch data source plugin.

 
 
 

Comments

Rated 0 out of 5 stars.
No ratings yet

Add a rating
bottom of page