Skip to content
This repository has been archived by the owner on Aug 3, 2021. It is now read-only.
/ graphite_fabric Public archive

automatically install graphite and statsd on an Amazon EC2 linux instance using python-fabric

Notifications You must be signed in to change notification settings

captnswing/graphite_fabric

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

78 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

Inspired by Etsy's seminal blogpost Measure anything, measure everything, w It turned out to be quite a bit more involved than

sudo yum -y install graphite statsd     # yeah I wish...

This fabric script is the result of my effort to trace my steps while trying to get everything work together and up and running (I took some clues from Grig Gheorghiu).

I use the script to automatically install statsd and Graphite (and its dependencies) from trunk on any standard Amazon EC2 linux instance.

On an m1.large EC2 instance, this script is finished within 8minutes.

Works on my machines, YMMV!

Prerequisits

Amazon EC2

Suitable Amazon EC2 linux instance (I often use Basic 64-bit Amazon Linux AMI 2011.02.1 Beta on an m1.large machine)

image

The instance need to be configured with a security group that has the necessary UDP / TCP ports opened.

image

Local machine

On your local machine, you need mercurial, python2 >= 2.6 and python-fabric

pip install fabric

Installing graphite with this fabfile

Once fabric is installed, and the EC2 instance is running, test that you are able to ssh into your EC2 instance, using something like

ssh -i ~/.ssh/myec2key.pem [email protected]

Then just invoke

curl -O https://bitbucket.org/captnswing/graphite_fabfile/raw/default/fabfile.py
fab -i <path to EC2 .pem> -H <EC2 hostname> setup

Starting & stopping graphite

On the EC2 host, supervisord takes care of running apache httpd, graphite carbon and node.js statsd services.

You can check the status of these services by invoking

fab -i <path to EC2 .pem> -H <EC2 hostname> graphite:status

Also

fab -i <path to EC2 .pem> -H <EC2 hostname> graphite:stop
fab -i <path to EC2 .pem> -H <EC2 hostname> graphite:start

does what you think it does.

Getting data into your graphite

Check out the graphite / statsd clients here

About

automatically install graphite and statsd on an Amazon EC2 linux instance using python-fabric

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published