Amazon EC2 tools for Debian?

Posted on

Amazon EC2 tools for Debian? – Managing your servers can streamline the performance of your team by allowing them to complete complex tasks faster. Plus, it can enable them to detect problems early on before they get out of hand and compromise your business. As a result, the risk of experiencing operational setbacks is drastically lower.

But the only way to make the most of your server management is to perform it correctly. And to help you do so, this article will share nine tips on improving your server management and fix some problem about linux, debian, amazon-ec2, amazon-web-services, .

What is the recommended way of getting command-line Amazon EC2 tools on Debian? So, basically the same as this question, but for EC2 instead of S3.

Ubuntu has ec2-ami-tools and ec2-api-tools, but I couldn’t find equivalent packages for Debian. A blog post titled “Install EC2 AMI & API tools in Debian” talks about installing Amazon’s packages outside package management, but that seems a little clumsy.

Solution :

Ah, seems that you can use the Ubuntu .deb packages on Debian without problems! At least for the Debian stable (5.0.4) system that I’m working on, ec2-api-tools from Ubuntu Jaunty apparently works fine…

What I did:

  1. Download the .deb package (for amd64 in my case) of ec2-api-tools
  2. sudo dpkg -i ec2-api-tools_1.3.34128-0ubuntu2_amd64.deb

Edit: As pointed out in comments, you might want the package from latest Ubuntu version instead. (I can’t say anything about compatibility with specific Debian versions though.)

As for ec2-ami-tools, I got that also installed quite smoothly, but only after fulfilling some missing dependencies: sudo apt-get install ruby libopenssl-ruby curl. (I had to dpkg -r ec2-ami-tools before that worked.)

Now, the obvious question of course is: why no official Debian packages? It turns out that Amazon’s EC2 tools are not available for Debian because of some DFSG compliance reasons. 🙁

Here is a ‘free’ implementation
euca2ools in Debian stable

Tools list for the package

Adding ‘use limitation’ clause 3.3 to EC2 tools (like Amazon did) was I think a misguided measure

A little script to download ubuntu packages:

( Assuming you have ubuntu sources list file in /etc/apt/sources.list.d/ubuntu.list, and you had sudo apt-get update previously, so the list had been cached.


cd /etc/apt/sources.list.d
sudo mv .ubuntu.list.bak ubuntu.list
aptitude download "$@"
sudo mv ubuntu.list .ubuntu.list.bak

Then, run ./ ec2-ami-tools ec2-api-tools to download the ec2 tools from the ubuntu repositories. And later, run sudo aptitude install ec2-api-tools-x.x.x.deb etc., to install the deb packages with all required dependencies. (sudo dpkg -i ... won’t install dependencies for you)

The packages from apt-get are out of date.

There is no way (I can find) to bundle, upload, and register an AMI in the us-west-1 region.

I wasted about 10 hours trying to get them to work. Do not recommend 🙁

Leave a Reply

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