Archive | python RSS feed for this section

ServerDensity: creating a new device and getting its access key via the API

31 Jan

I’ve recently been setting up devices that need to have ServerDensity monitoring automatically added to them when I start them up. Setting up the ServerDensity agent itself can be automated through shell commands, but you also need to set the API key in the config. IĀ use a Python file to create a new device in ServerDensity and output the API/agent key for the newly created device.

Continue reading

Gentle Introduction to HBase Part I – Data Structure

13 Nov

In this post (hopefully the first of more), I hope to provide a gentle introduction to HBase (since I never had one myself!) This specific post is more about the specifics of HBase’s data structure, but I hope to do more posts introducing HBase programming using a combination of HBase on Amazon’s Elastic Map Reduce (I like to call it Amazon’s HAAS or HBase-as-a-Service) and Python using the HappyBase library (this offers a really easy interface to the HBase Thrift interface.)

Continue reading

Using Amazon/AWS Glacier with Python boto

16 Oct

Amazon’s Glacier is a fairly new AWS service for low-cost storage/backups. But there is little documentation on how to actually use it.

Continue reading

GeoIP on Amazon Elastic Map Reduce (EMR) using Hadoop Streaming (Python)

23 Apr

I wanted to be able to run geo-data calculations on Amazon Elastic Map Reduce using Hadoop streaming jobs – particularly in Python. While we cannot easily install required Python dependencies, this problem can be solved by using the cacheArchive feature of Hadoop.

Continue reading

Python: Looking up country name from country code

2 Apr

A simple Python program to lookup the full country name (and other details) from country code. You can also look up timezones, capital, etc from this.

Continue reading

Getting Python GeoIP working on Amazon EC2

2 Feb

Amazon EC2 doesn’t allow easy installation of a “python-geoip” for GeoIP usage with Python, so you have to do this manually. Continue reading