DDSCAT on amazon EC2

Posted on Thu 03 September 2015 in Plasmonics

Amazon provides high performance computing capabilities through their EC2 service. You can find more information here

They provide a 750 hr free instance with their a free-tier program. If you want more resources, you can pay for it. See the pricing, pricing seem very reasonable.

I wanted to see how easy it was to install ddscat and run some examples files.

Amazon allows to create an instance through their very easy-to-use web interface. I chose to install ubuntu amazon machine image on the instance.  While you are creating an instance you are allowed to create a key pair file and download it.  You will need that to connect to amazon instance through ssh client with this key

Fire up  terminal on a linux box and browse to the folder you have the key pair and issue these commands

chmod 400 your-key-pair.pem

Make ssh connection with a command like this

ssh -i your-key-pair.pem

here "" is your public dns address

You should be able to log into the instance. If you get stuck, see detailed info at how to connect to the instance

Update the package list from different repos with

sudo apt-get update

install these packages

sudo apt-get install gfortran gcc wget make

Make a directory for ddscat

mkdir ddscat\_install  
cd ddscat\_install

Download the source files and examples


Unzip them

tar -xzvf ddscat7.3.1\_150420.tgz

tar -xzvf ddscat7.3.1\_examples\_150519.tgz

rm \*.tgz

Go to the examples_exp folder

cd /examples\_exp

To compile ddscat executable and run the examples:


ddscat executabe file should be created in the src folder, which you can use for your own ddscat test cases.

To quit the ssh session, type
exit in the command prompt

So as you see, the process is very simple.